Re: [css3-mediaqueries] 'only'/'not' with omitted media type

On Friday 2009-06-12 17:33 +0200, Øyvind Stenhaug wrote:
> Some of the prose regarding 'not' and 'only' is inconsistent with the  
> current syntax, e.g. this sentence from section 2:
>
> "User agents must process media queries starting with 'only' as if the  
> 'only' keyword was not present."
>
> @media only (color) { /* media query is dropped because the syntax  
> requires a media type */ }
> @media (color) { /* match, assuming a color device */ }

I don't think which way we choose here particularly matters,
although I agree the spec should be internally consistent.  (The
reason the 'only' feature was added [1] doesn't apply to queries
with omitted media types... at least I don't think so.)

In Gecko I implemented what the grammar says (i.e., dropping the
first media query you give above).

-David

[1] http://www.w3.org/TR/css3-mediaqueries/#media0 says:
      # The keyword ‘only’ can also be used to hide style sheets
      # from older user agents.

-- 
L. David Baron                                 http://dbaron.org/
Mozilla Corporation                       http://www.mozilla.com/

Received on Tuesday, 30 June 2009 22:09:49 UTC