RE: [CSS21] [css3-writing-modes] We got the bidi box model backwards

Hi, I agree with Fantasai for this case.
 

> Date: Tue, 10 May 2011 14:55:55 -0700
> From: fantasai.lists@inkedblade.net
> To: www-style@w3.org; public-i18n-bidi@w3.org; smontagu@smontagu.org; aharon@google.com
> Subject: [CSS21] [css3-writing-modes] We got the bidi box model backwards
> 
> http://www.w3.org/TR/CSS21/box.html#bidi-box-model
> 
> # When the element's 'direction' property is 'ltr', the left-most generated box of
> # the first line box in which the element appears has the left margin, left border
> # and left padding, and the right-most generated box of the last line box in which
> # the element appears has the right padding, right border and right margin.
> #
> # When the element's 'direction' property is 'rtl', the right-most generated box
> # of the first line box in which the element appears has the right padding, right
> # border and right margin, and the left-most generated box of the last line box in
> # which the element appears has the left margin, left border and left padding.
> 
> The issue is when inlines are broken across lines. Right now we decide which side
> of the first/last box to draw the start/end decorations on based on the element's
> 'direction' property. But I believe it should be the element's /parent's/ direction
> property.
> 
> Here's why:
> 
> Consider that you are embedding some text, e.g. a quote, into a paragraph. You
> want to space it off a bit from the surrounding content, like this:
> 
> q {
> margin: 0 0.5em;
> }
> 
> |Here is some text AND HERE IS MY QUOTE|
> |THAT CONTINUES ON THE LINE and my text|
> |continues. |
> 
> If the quote happens to be of opposite-direction text, the separation doesn't
> work anymore, because we placed the box decorations based on the quote's
> directionality and not the paragraph's directionality.
> 
> |Here is some text ETOUQ YM SI EREH DNA |
> | ENIL EHT NO SEUNITNOC TAHT and my text|
> |continues. |
> 
> Now, we definitely want the left border on the left side and the right border
> on the right side, but I'm starting to think we should have chosen differently
> which side is the "broken" side when the element breaks across lines.
> 
> Here's the example again using brackets to represent borders.
> 
> |Here is some text [AND HERE IS MY QUOTE|
> |THAT CONTINUES ON THE LINE] and my text|
> |continues. |
> 
> |Here is some text ETOUQ YM SI EREH DNA] |
> | [ENIL EHT NO SEUNITNOC TAHT and my text|
> |continues. |
 
I agree the element should be broken according to the parent's element's directionality.
Thanks for thinking of this!
 
Best,
 
--C. E. Whitehead
cewcathar@hotmail.com 
> 
> Aharon, smontagu -- thoughts?
> 
> Is this something we should fix?
> 
> ~fantasai
> 
 		 	   		  

Received on Wednesday, 11 May 2011 03:25:15 UTC