Page 1 of 1

Grouping of different styles

Posted: Thu Mar 12, 2009 11:35 am
by crazycoders
I'm developping a project where i need to group the different css properties together into categories, i'd like your input, please tell me if something is missing or misplaced in your opinion

Font-related
------------
font-family
font-size
font-style
font-variant
font-weight
color
line-height
text-align

Container Positionning
---------------------
Position
Left
Top
Width
Height
Float
Clear
margin
zorder

Content positionning
-------------------
padding
vertical-align

Background
-----------
background-color
background-image
background-position
background-repeat

Borders
-------
Border-left
border-right
border-top
border-bottom

If you see other categories and properties missing that i'd need to add to that list don't hesitate.

Thanks

Re: Grouping of different styles

Posted: Thu Mar 12, 2009 12:51 pm
by kaszu
'text-align' should be in 'Content positionning'.
There is no property zorder, but z-index.

There are a lot more properties than you listed + short/long versions of properties like font, background, border-left-style, etc. See http://www.blooberry.com/indexdot/css/propindex/all.htm, don't know if list is full.

What for you need to know all properties?

Re: Grouping of different styles

Posted: Thu Mar 12, 2009 7:19 pm
by crazycoders
Building a framework for php. Would be too long to reexplain everything but you can check in "coding critics" forum about "phpx framework"

I'm building set of classes that will control and manage the styling process of the components. I have already done the FontStyle class which manages the following properties:

Code: Select all

    protected $prvrule = '';
    protected $prvfontfamily = NULL;
    protected $prvfontsize = NULL;
    protected $prvfontstyle = NULL;
    protected $prvfontvariant = NULL;
    protected $prvfontweight = NULL;
    protected $prvlineheight = NULL;
    protected $prvtextalign = NULL;
    protected $prvcolor = NULL;
I think i will leave textalign in font or else, if i change it, i'll rename it to horizontal-position to match vertical position.

Re: Grouping of different styles

Posted: Thu Mar 12, 2009 7:28 pm
by crazycoders
Ouais, c'est vrai qu'après mure réflection, je vais bouger text-align vers "content positionning" et je vais le renommer à "horizontal-align" merci de la suggestion.

Re: Grouping of different styles

Posted: Thu Mar 12, 2009 7:39 pm
by crazycoders
Oops, this is not a french forum :P So i said:

You know what, after thinking about it, you are right, i'll move the text-align property to "content positionning styles" and i'll rename it to horizontal-align;