Re: [CSS21] response to issue 82

fantasai writes:

> EXAMPLE { border: solid }
> EXAMPLE[notation=octal] { background: silver }
> 
> Note that, contrary to the sentence I quoted, <example notation=octal>
> will have a solid border.

The example is a simplification. It hints at a solution, it doesn't
give an algorithm that works in all cases. It assumes, indeed, that
the two original rule sets contain declarations for the same
properties, but with different values. Or that the rule for the other
attribute is modified as the new rule is added.

But it assumes more: that there is no other, equally specific rule
that sets the same properties. Because if there is, then the simple
element selector may not get used at all.

To make a truly equivalent rule, with the right specificity and that
matches only elements without an attribute, you would need the :not()
from CSS3, but we can't use that here.

I don't think we need to explain all the assumptions. The example is a
hint, people can fill in the details themselves. But as I said, if
there is something we can do to explain the somewhat vague word
"might" in the example, without introducing more confusion than it
solves, we can do so later. I'd rather point to CSS3, though, that has
the same example, but shorter and better.



Bert
-- 
  Bert Bos                                ( W 3 C ) http://www.w3.org/
  http://www.w3.org/people/bos/                              W3C/ERCIM
  bert@w3.org                             2004 Rt des Lucioles / BP 93
  +33 (0)4 92 38 76 92            06902 Sophia Antipolis Cedex, France

Received on Sunday, 22 February 2004 20:15:47 UTC