Re: [css3-writing-modes] a third option for implementing logical properties

?

--------------------------------------------------
From: "HåkonWium Lie" <howcome@opera.com>
Sent: Sunday, October 24, 2010 3:32 PM
To: "David Hyatt" <hyatt@apple.com>
Cc: "HåkonWium Lie" <howcome@opera.com>; "John Daggett" 
<jdaggett@mozilla.com>; "L. David Baron" <dbaron@dbaron.org>; 
<www-style@w3.org>
Subject: Re: [css3-writing-modes] a third option for implementing logical 
properties

> I'm not sure we need per-element switches, though. I think the use
> case is more for different document modes. For example, a button on a
> Japanese tablet that toggles between vertical and horizontal layout.
> Or for a default style sheet that works both for a latin and
> arabic/hebrew. As such, using a media query makes sense -- it would
> query which mode the document is in:
>
> @media (dir: ltr) {
>  body { margin: 10px 20px 30px 40px }
> }
>
> @media (dir: rtl) {
>  body { margin: 10px 40px 30px 20px }
> }

How about this case:

[view dir="ttb-rtl"]
<html>
  <body>
     ... some Japanese text here ...
     <blockquote dir="ltr">
         ... some e.g. English text ...
         <p> ...and markup...</p>
     </blockquote>
    ... some Japanese text here again ...
  </body>
</html>
[/view]

@media will not help you in this case.

CSS shall be able to distinguish :

p:in-ltr-environment  { ... } and
p:in-ttb-rtl-environment { ... }.


-- 
Andrew Fedoniouk

http://terrainformatica.com




 

Received on Sunday, 24 October 2010 23:51:11 UTC