4 replies [Last post]
Fluxcore
Offline
newbie
Mi
Last seen: 17 years 4 weeks ago
Mi
Joined: 2003-12-31
Posts: 5
Points: 0

Ok, I know when using the value em, it is based on the browsers default font size setting. So if I want to use the browsers default, would I use 1 em and that will be the browsers default font size?

Daybreak_0
Offline
Enthusiast
Sydney, Australia
Last seen: 17 years 10 weeks ago
Sydney, Australia
Timezone: GMT+10
Joined: 2003-11-15
Posts: 389
Points: 0

Font size with em

Yes

But there is a problem as not all browsers seem to have the same default font size.

On my last site I set a body font default size, and then em for headings<h*> and <p>, etc which allowed the user to resize.

Regards
Day

The only way to learn is to do it yourself

Fluxcore
Offline
newbie
Mi
Last seen: 17 years 4 weeks ago
Mi
Joined: 2003-12-31
Posts: 5
Points: 0

Font size with em

So if I understand you correctly, you are setting a default body font size, thus replacing the browsers default, and then the following em units will be sized off of the body font? So if you set the body font size at 14px, 1em would then be 14px, instead of whatever the browser default is. If I am wrong, sorry.

Daybreak_0
Offline
Enthusiast
Sydney, Australia
Last seen: 17 years 10 weeks ago
Sydney, Australia
Timezone: GMT+10
Joined: 2003-11-15
Posts: 389
Points: 0

Font size with em

That is correct, although I normally set it to the same as the default for IE as the most used browser, so many do not see any difference.

I had thought that to be 16px, but someone else thought it was 18px, although that seems too big.

Regards
Day

The only way to learn is to do it yourself

Fluxcore
Offline
newbie
Mi
Last seen: 17 years 4 weeks ago
Mi
Joined: 2003-12-31
Posts: 5
Points: 0

Font size with em

Thanks Day, I apreciate the help.