On May 26, 2005, at 3:30 PM, Mike Davies wrote:
Hi all,
I would like to know if it is possible to set the base font size using
css so that the text is rendered the same size by all browsers and is
still resizeable, ie not defined in pixels.
<snip>
I don't want to set the size in pixels, so it is resizeable. How can I
ensure the same size in various browsers? Appreciate any comments.

Mike,
This is what I do and it seems to work for me. Keep in mind this topic is one of the topics that may get a few responses to "just check the wiki" [1][2], which you should do.

html, body {
font: 91% "Lucida Grande", "Lucida Sans Unicode", geneva, verdana, sans-serif; /* For IE/Win 1.1em is approx. 12px */
    line-height: 1.2em;
}

html>body {
    font-size: 12px;    /* For modern browsers 1em = 12px */
}

This will allow you to set a percentage font size for IE and older browsers (which is resizable) at the same time set a base pixel size for the modern browsers (which allow font sizing with pixel defined fonts). That is, of course, unless I've done this backwards then I'm sure someone will mention it on the list.

[1] http://css-discuss.incutio.com/?page=UsingFontSize
[2] http://css-discuss.incutio.com/?page=UsingPercentages

Mike Stickel
Screenflicker Developments
www.screenflicker.com

p: 403-923-7667
e: [EMAIL PROTECTED]


______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to