...

View Full Version : font size unit and 2 column (1) liquid layout



croatiankid
05-27-2007, 04:41 PM
I'm gonig to change my layout to a liquid one, where the left will be liquid (fluid), and right will be fixed.
In the other thread I saw if I specified a container's width and its font in ems, they would resize proportionally. Do you think this is good to incorporate in a liquid layout for the "fixed" width column (right)? Also, I've seen before people doing stuff like setting the font size on the body to 100%, or 101%. Am I going to have to do something like this, or no? The rest of the text would be in ems as well.

kewlceo
05-27-2007, 05:19 PM
Fonts: Safari has a problem with 101%, but 100.01% in your html element seems to work fine with all browsers. As for me, I usually set my body font size to 62.5% to make it equal to 10px. Thereafter, when using ems, 1.2ems is roughly equal to 12 pixels, and 1.6 ems = 16px, and so on.

croatiankid
05-27-2007, 08:03 PM
So, I have to put more than 100% on html? Why? If I specified the font sizes without this, would there be differences in browsers or resolutions? And how come?

_Aerospace_Eng_
05-27-2007, 08:06 PM
Just be sure to set a default font size. With em's you can't always be certain they are rendered the same way in all of the browsers if no default font size is set.

kewlceo
05-27-2007, 10:58 PM
So, I have to put more than 100% on html? Why? If I specified the font sizes without this, would there be differences in browsers or resolutions? And how come?

From CSS: Getting Into Good Coding Habits (http://www.communitymx.com/content/article.cfm?cid=FAF76&print=true)


[...]some versions of Opera will draw a default font-size of 100% too small compared to other browsers. Safari, on the other hand, has a problem with a font-size of 101%. The current “best” suggestion is to use the 100.01% value for this property.

KevinG
05-28-2007, 02:37 PM
I just changed my div widths to ems and used auto height and then expanded my text in IE and FF to a very large size and everything stayed in place. I kept my fonts sizes in pixels.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum