RE: [css3-text-layout] New editor's draft - margin-before/after/start/end etc.

From: Håkon Wium Lie [mailto:howcome@opera.com] 


> Only for Japanese text. For other languages, top/bottom margins are 10px and left/right margins are 20px.

OK.

 >> So if you rotate made top/right/bottom/left for the margin  > shorthand based on writing-mode, what happens to the longhands e.g.
 >> margin-left ?

> I  don't understand your question. There is no rotation in my examples.

Implicitly given your example, there is. What would have been the left margin in English now applies to the physical right of the block, right ? You've 
simply rotated top/right/bottom/left clockwise.

> All properties and values stay physical. The example simply set different values for Japanese and other languages. Written in longhand, the examples are:

>  p { 
>     margin-top: 10px;
>     margin-right: 20px 
>     margin-bottom: 10px;
>     margin-left: 20px
>  }

 > p:lang(ja) {
 >    writing-mode: tb-rl;
 >    margin-top: 20px;
 >    margin-right: 10px 
 >    margin-bottom: 20px;
 >    margin-left: 10px
 > }

OK. So my question was: assuming Japanese text, do the following remain equivalent or do the longhands remain physical while the shorthand goes logical ?

p:lang(ja) {
    writing-mode: tb-rl;
    margin-top: 20px;
    margin-right: 10px 
    margin-bottom: 20px;
    margin-left: 10px
 }

p:lang(ja) {
    writing-mode: tb-rl;
    margin: 20px 10px 20px 10px;
 }

It sounds like margin-top will always be margin-top, but the top component of the shorthand may end up in another place depending on the writing-mode.
I think such a discontinuity would be confusing in practice. We do it for both shorthands and longhands. 

Received on Friday, 28 May 2010 18:09:38 UTC