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

RE: Why no Parent Selector?

From: L. David Baron <dbaron@fas.harvard.edu>
Date: Tue, 30 Nov 1999 15:47:22 -0500 (EST)
Message-Id: <199911302047.PAA32165@is03.fas.harvard.edu>
To: Daniel.Glazman@der.edf.fr, dwagner@kevric.com
Cc: www-style@w3.org
On Tue, 30 Nov 1999 14:27:48 -0600, David Wagner (dwagner@kevric.com)
wrote:
> 
> crashed on attempt to send it.  In a nutshell, there seems to be nothing to 
> prevent using more than one :subject pseudo-class in a single selector.
> 
> 	DIV.draft:subject INS:subject {}
> 
> This can be useful and help with selector brevity; it's the same as the 
> following.
> 
> 	DIV.draft:subject INS, DIV.draft INS {}
> 
>  However, what happens when you use the following?
> 	
> 	DIV.big SPAN.big {font-size:200%;}
> 
> Is the font-size of SPAN.big 200% or 400% of the parent of DIV.big?

It would be 200% (why anything else?), assuming no intermediate
elements had matching rules with the font-size property.  However, if
your proposal above were adopted, I would think the rule

DIV.big:subject SPAN.big:subject {font-size:200%;}

would make the font-size of a span with class="big" 400% the size of
the parent of the div with class="big" (assuming no intermediate
elements had matching font-size rules).  Was that what you were
asking?

-David

L. David Baron    Sophomore, Harvard (Physics)    dbaron@fas.harvard.edu
Links, SatPix, CSS, etc.     <URL: http://www.fas.harvard.edu/~dbaron/ >
WSP CSS AC                      <URL: http://www.webstandards.org/css/ >
Received on Tuesday, 30 November 1999 15:47:28 GMT

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