Re: [CSS21] response to issue 82

Bert Bos wrote:
> fantasai writes:
> 
>>Bert Bos wrote:
>>
>>>Your e-mail:
>>>    http://www.w3.org/mid/3F875337.6080406@escape.com
>>>    Default Attributes
>>>    S5.8.2 <http://www.w3.org/TR/2003/WD-CSS21-20030915/selector.html#q11>
>>>    #    EXAMPLE { /*... default property settings ...*/ }
>>>    # Because this selector is less specific than an attribute selector,
>>>    # it will only be used for the default case.
>>>    This is false. The selector will be used for all cases, not just the
>>>    default case. If a declaration from this rule conflicts with one from
>>>    a more specific rule, then it will be overridden--but the declaration
>>>    still applies.
>>>
>>>CSS WG response:
>>>    It's only an example and is accurate enough, we think.
>>
>>It's not accurate at all ...
<snipped response and rewrite>
> 
> I think I'm starting to see what you mean. It's not about whether the
> selector matches. It's about the word "default." You interpret the
> comment "default property settings" different from how we intended it:
> 
>   - Your meaning is that these are the *default properties* that apply
>     to all EXAMPLE elements, independent of what attribute the element
>     has.
> 
>   - Our meaning is that those are the properties that apply to the
>     EXAMPLE element when its attribute has the value that is declared
>     as the *default value* in the DTD.

Not at all. I interpreted the comment just as you meant it. The sentence
below it states your intent very clearly. My problem is that the comment
as you meant it (and thus that sentence) is /wrong/ because the selector
matches all EXAMPLE elements, not just ones with the default attribute
setting.

Here's the spec:

     #    EXAMPLE { /*... default property settings ...*/ }
     # Because this selector is less specific than an attribute selector,
     # it will only be used for the default case.
       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

> When you said: "If a declaration from this rule conflicts with one
> from a more specific rule, then it will be overridden," we thought
> that was a rather subtle way of saying it. *Of course* the
> declarations will be overridden: the rule that overrides them is right
> there in the example. Why use the word "if"?

Because the second rule may contain only declarations for properties
not declared in the first?

EXAMPLE { border: solid }
EXAMPLE[notation=octal] { background: silver }

Note that, contrary to the sentence I quoted, <example notation=octal>
will have a solid border.

~fantasai

Received on Friday, 20 February 2004 23:23:40 UTC