RE: [CSS3] ltr and rtl pseudo-class proposal

Ambrose Li wrote:

> On 17/03/2008, Alan Gresley <alan@css-class.com> wrote:
> > Yes you are correct but I really miss the point why there is such a pseudo class as :lang in the first place since it's does nothing once the style sheet is disabled. I believe that [lang="val"] is much more suited and the semantic meaning is always in the source (accessible).
> >
> >
> >  [lang="fr"] {..}
> >
> >  <span lang="fr"> ... </span>
> >
> >  [lang|="fr"] {..}
> >
> >  <html lang="fr"> ... </html>
> 
> No, :lang and [lang="fr"] are very different things. To give you a
> more concrete example (the kind of things I run into every day),
> consider
> 
> <p lang=en> ... <cite>foo</cite> ... </p>
> 
> A [lang="en"] rule would not even match the CITE element. If such
> matching is important (e.g., for proper display of English in a
> Chinese page), the results are disastrous.
> 
> Because :lang did not work when I set up my sites, I have lots of
> rules in the form of [lang=foo] * or even [lang=foo] * * so that
> things can be more-or-less properly styled. It is a complete
> nightmare.
> -- 
> cheers,
> -ambrose


Thank you Ambrose. I now understand with your example. Can examples like this be added to the spec. The only one I can find is this one (I can never find the editor's draft).

http://www.w3.org/TR/2005/WD-css3-selectors-20051215/

There is no mention here that E:lang can inherit the style to it's children and I believe that's the point I was missing. This would also set it apart from any other pseudo selector.


Alan

http://css-class.com/test/

Received on Monday, 17 March 2008 19:00:50 UTC