Re: [css3-selectors] minor question about :not()

At 8:40 PM +0300 3/12/09, Andrey Mikhalev wrote:
>in 6.6.7:
>"The negation pseudo-class, :not(X), is a functional notation taking 
>a simple selector (excluding the negation pseudo-class itself and 
>pseudo-elements) as an argument."
>
>so, :not(:pseudo-element) - allowed by formal grammar -
>is invalid selector or "useless" selector, as foo:not(bar) ?

    Yes.  The limited scope of ':not()' has long bugged me.  It would 
be really useful to be able to say something along the lines of 
':not(input, textarea, select, option) {margin: 0; padding: 0;}' -- 
thus allowing us to style all elements that are not form controls. 
Yes, this most often comes up in resets, which some people don't 
like, but there are other use cases besides just resets.
    I sort of get excluding pseudo-elements, but being limited to a 
simple selector is annoying and I don't quite see the point.

-- 
Eric A. Meyer (eric@meyerweb.com)     http://meyerweb.com/

Received on Thursday, 12 March 2009 19:25:47 UTC