Re: New draft: css3-selectors

Robin Berjon wrote:
> 
> At 16:32 02/02/2001 +0100, Chris Lilley wrote:
> >Robin Berjon wrote:
> >> Just a small detail. The .class notation is said to be only applicable to
> >> HTML.
> >
> >That is incorrect (and I thought we fixed that in the CSS2 eratta already).
> >There are several XML namespaces where .class is used.
> 
> That's fine, but my question was perhaps of a more generic nature. Specific
> XML vocabularies are of course entitled to decide that they have an
> attribute functionally equivalent to HTML's class 

I would prefer to phrase it that various XHM grammars, including XHTML,
SVG, SMIL, MathML and other non-W3C grammars have a class attribute. XHTML
is just one example, not the defining example. It would have been
prefereable to have an xml:class but there we are.

> so that specialized
> processors will know that they must apply .classes. However, in the case of
> a generic XML+CSS browser, would it be correct/a good idea/recommendable to
> apply a given style to an element if it had a xhtml:class='class' attribute ?

In that case, certainly; and also is it had a class in the SVG or other
namespaces.

In fact, since the notion of subclassing an element is so generally useful,
the main problem is of avoiding attributes called class which are used for
something else. However in practice, this is a non-problem; if authors are
using an attribute called class for some other purpose then they will not
be selecting on it in their stylesheets.

-- 
Chris

Received on Monday, 5 February 2001 21:40:13 UTC