[WEB4LIB] CSS font sizes

Bob Duncan duncanr at mail.lafayette.edu
Thu Feb 17 11:27:50 EST 2000


At 05:09 AM 02/17/00 -0800, Andrew Mutch wrote:
>I've been incorporating CSS into my personal and library web pages and
have run into a
>"problem" that you who use CSS extensively will hopefully assist me in
solving.  I use
>the following declaration to set the general font size for text on a page:
>
>BODY, P, TD {font-family:verdana,helvetica,sans-serif;font-size: x-small;}
>
>In IE, the font size is acceptable for viewing.  However, in Netscape
[4.x], the font
>size falls into the "squinting" range.  Is there a way to ensure that the
two browsers
>generally display the font with relatively the same size?

According to the CSS2 specs:
"An <absolute-size> keyword refers to an entry in a table of font sizes
computed and kept by the user agent. Possible values are: 
     [ xx-small | x-small | small | medium | large | x-large | xx-large ] 
On a computer screen a scaling factor of 1.2 is suggested between adjacent
indexes; if the 'medium' font is 12pt, the 'large' font could be 14.4pt.
Different media may need different scaling factors. Also, the user agent
should take the quality and availability of fonts into account when
computing the table. The table may be different from one font family to
another.
Note. In CSS1, the suggested scaling factor between adjacent indexes was
1.5 which user experience proved to be too large."
<http://www.w3.org/TR/CSS2/fonts.html#font-size-props>

This is a guess, but perhaps Andrew's version of Netscape is using the CSS1
recommendation and attempting to scale down two indexes (from medium to
x-small) using the 1.5 factor, while IE is going the CSS2 route and scaling
down twice with the 1.2 factor?  On my machine this would mean IE is
scaling down my default 12pt to ~8pt Verdana (12/1.2/1.2=8.3), which is
readable on my screen (barely), but Netscape is attemping ~5pt Verdana
(12/1.5/1.5=5.3), which is not.

If I scale the text size in IE5 from the default "medium" down two levels
to "smallest", the text on Andrew's page appears as unreadable as it does
in NN4.08.  (Since in this case, by my possibly-whacked theory, IE is
attemping 12 divided by 1.2 four times, which would equal 5.7.)

Regardless of whether my theory is correct, I have to take the opportunity
to rant (briefly) about the soundness of setting the font size for a page's
main content two sizes smaller than the default.  Why force users to read
text two sizes smaller than the size they have determined (in their
browser's preferences) is most comfortable for reading?

Bob Duncan (who is going blind from squinting and developing carpal tunnel
syndrome from adjusting his prefs so often)

~`~`~`~`~`~`~`~`~`~`~`~`~`~`~`~`~`~`
  Robert E. Duncan
  Systems Librarian
  David Bishop Skillman Library
  Lafayette College
  Easton, PA 18042
  610-330-5156
  duncanr at lafayette.edu
  http://www.library.lafayette.edu/


More information about the Web4lib mailing list