W3C home > Mailing lists > Public > www-style@w3.org > March 2008

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

From: Alan Gresley <alan@css-class.com>
Date: Mon, 17 Mar 2008 12:00:06 -0700
To: Ambrose Li <ambrose.li@gmail.com>
cc: Justin Rogers <justrog@microsoft.com>, "www-style@w3.org" <www-style@w3.org>, "robert@ocallahan.org" <robert@ocallahan.org>, Andrew Fedoniouk <news@terrainformatica.com>
Message-ID: <20080317120006.f8d1e42eb1f8db40312f41775502f7f0.e7052dd2ab.wbe@email.secureserver.net>

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 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:55:02 GMT