W3C home > Mailing lists > Public > www-style@w3.org > August 1999

Re: When font-size and font size collide

From: Steve Mulder <smulder@tsdesign.com>
Date: Tue, 17 Aug 1999 17:23:18 -0400
Message-Id: <v04011708b3df8162011d@[209.21.248.19]>
To: "L. David Baron" <dbaron@fas.harvard.edu>, www-style@w3.org
David, nice piece [1] on font size. You're absolutely right about what the
spec says.

After thinking about it, I'm not sure I agree that's how it should work. It
forces authors to apply CSS to "style-based" HTML tags (like FONT SIZE)
instead of to "structure-based" tags (like P), if they want the CSS
font-size to override the HTML <FONT SIZE>.

As an author, I'd want the browser to use the HTML *only* if no other CSS
rule was relevant. The HTML is my "backup formatting" for older browsers,
and nothing more. Thus, *this* author would rather it worked differently
than it does. (But given current browser support, I know there's really no
point arguing for it now...)

steve



At 4:20 PM -0400 8/17/99, L. David Baron wrote:
>On Tue, 17 Aug 1999 16:04:29 -0400, Steve Mulder (smulder@tsdesign.com)
>wrote:
>> Yup, that would be a lovely little browser bug.
>>
>> According to the spec, HTML stylings (like FONT SIZE) should be treated
>> with less specificity than all CSS rules. Thus, the CSS *should* override
>> the HTML.
>
>Not when the HTML is:
>
><p><font>...</font></p>
>
>and the relevant CSS rule matches the p element.
>
>The rule to which you refer (CSS2 section 6.4.4, also in CSS1) only has
>an effect when the presentational hint and the CSS rule are on the same
>element.  Otherwise whichever is deeper in the document tree prevents
>inheritance from the one that is higher.  See [1], where I explained
>this fully.
>
>However, I *think* <font size="+2"> is often treated as relative to the
>base font size of the document, not the font size of the parent
>element.  That might explain the problem.
>
>David
>
>[1] http://www.deja.com/[ST_rn=ps]/getdoc.xp?AN=443308087 , also at
>    http://css.nu/faq/david-on-font.html
>
>L. David Baron     Rising Sophomore, Harvard     dbaron@fas.harvard.edu
>Links, SatPix, CSS, etc.        < http://www.fas.harvard.edu/~dbaron/ >
>Summer Intern, Netscape - however, opinions are entirely my own, etc.
Received on Tuesday, 17 August 1999 17:20:10 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:54:00 GMT