Forum Moderators: not2easy
So what's the consensus? % or ems today? I have my own site using % for text size, and spacing px, but I've moving the spacing to ems tonight, but now I'm not sure. I would love it to be at a time where we can use one measurement for all elements--are we there yet?
Thanks a lot for all who reply. I really appreciate it.
I know that swa66 disapproves of the way I do it but I actually use both.
I set the body text size at 62.5% and then use EM's everywhere else. At that percentage:
1em = 10px
1.1em = 11px
1.2em = 12px
and so on...
While I understand his approach I personally like this one because I know all browsers will display the same size and will scale appropriately.
There will be a few more options and probably a lengthy discussion coming so I won't spoil it by displaying all the options in one post :-)
I prefer using the 62.5% on the body and use ems for both font size and spacing - I like the spacing to increase when font sizes are increased.
Using relative sizing in an attempt at fixing dimensions is the wrong approach! You might as well use pixels, then.
Personally, I tend to set the overall font size for the body (if at all) and then use
em from that point on. Older versions of IE had issues with em being used as the main dimension (for the document-wide font size) if the font sizing was changed. So, you should probably use a percentage or pixel size for the body. As for the rest of the document, it really doesn't matter. Personally, I prefer
em, as it makes sense for all sorts of other text related properties where % would fail. Text indent, anyone? 3em or 300%? You get the drift.