- From: John Daggett <jdaggett@mozilla.com>
- Date: Tue, 14 Sep 2010 09:35:08 -0700 (PDT)
- To: Rune Lillesveen <rune@opera.com>
- Cc: www-style@w3.org
Rune Lillesveen wrote: > I was trying to figure out what to do about !important and > properties of the @viewport rule. I checked how it's handled for > @font-face descriptors. > > The grammar of the CSS2 spec says the descriptors are parsed as > declarations, and hence allow !important. The prose says "If a font > descriptor is duplicated, the last occurring descriptor wins and the > rest must be ignored.", but nothing about !important. In CSS, the grammar is always a superset of the prose. The CSS2 spec includes this wording: All font descriptions are specified via a @font-face at-rule. The general form is: @font-face { <font-description> } where the <font-description> has the form: descriptor: value; descriptor: value; [...] descriptor: value; This *doesn't* allow !important (or !really-i-mean-it-i-swear). The same is true for the wording in the CSS3 Fonts spec. Including !important is a syntax error so the descriptor definitions in your example should be ignored. John Daggett
Received on Tuesday, 14 September 2010 16:35:42 UTC