E-mail List Archives
Re: CSS Units of Measurement
From: Jukka K. Korpela
Date: Feb 19, 2004 2:13AM
- Next message: Tim Beadle: "Re: CSS Units of Measurement"
- Previous message: Tim Beadle: "Re: CSS Units of Measurement"
- Next message in Thread: Tim Beadle: "Re: CSS Units of Measurement"
- Previous message in Thread: Tim Beadle: "Re: CSS Units of Measurement"
- View all messages in this Thread
On Thu, 19 Feb 2004, Tim Beadle wrote:
> I may be shot down in flames,
You have your asbestos suit ready? Fine. Here we go...
> * Set sizes in pixels in a basic (i.e. NN4 only) stylesheet
Exercise in futility, since anyone who still surfs using NN4 is either
interested in content only, not visual appearance, or doesn't know what he
is doing and inevitably experiences lots of problems. In the first case he
has probably disabled JavaScript, thereby disabling the quasi-CSS support
too. If not, should we really punish him by enforcing our guesses on the
suitable font size upon him?
Besides, you never know when your "NN 4 only" stylesheet suddenly
affects rendering on other browsers.
> * Set (override) these sizes with keyword sizes in an advanced (@import)
> stylesheet, using the Tantek Box Model Hack to give IE the sizes it wants,
> as it uses sizes one-keyword out (smaller IIRC) from Mozilla.
Keyword sizes are inconsistently and vaguely defined and even wrongly
implemented on some still relevant browsers. Why would you use them then?
If you are happy with making something smaller or larger with just a vague
idea of what that might mean, use <small> and <big> in HTML. Beware though
that they should be used with caution and understanding, since their
effect will not disappear when the IE user tells the browser to ignore
font sizes set on Web pages. IE treats them as if they were really logical
rather than physical markup, which is, pragmatically, not as bad an idea
as it might sound on first sight.
If you wish to make specific suggestions on relative font sizing, use
font-size with percentage value, and avoid getting below 75% or above
150%. Watch out for the effects of nested elements with such settings.
You could even combine the two, using <small> in HTML and e.g.
small { font-size: 85%; }
in CSS.
> Beware the Rendering Mode! Different font sizes will be displayed depending
> on the Doctype you have set; i.e. Quirks Mode will look different to Standards
> Compliant Mode.
On IE 6, yes. (Thanks for pointing this out. I had forgotten this when I
recently wrote down a list of what the intentionally broken mode,
known as "quirks" mode, actually does.)
On IE 5 (on Windows), the user always gets the equivalent of "Quirks"
mode, i.e. all so-called absolute keywords as font-size values are horrendously
wrongly interpreted.
--
Jukka "Yucca" Korpela, http://www.cs.tut.fi/~jkorpela/
----
To subscribe, unsubscribe, suspend, or view list archives,
visit http://www.webaim.org/discussion/
- Next message: Tim Beadle: "Re: CSS Units of Measurement"
- Previous message: Tim Beadle: "Re: CSS Units of Measurement"
- Next message in Thread: Tim Beadle: "Re: CSS Units of Measurement"
- Previous message in Thread: Tim Beadle: "Re: CSS Units of Measurement"
- View all messages in this Thread