W3C home > Mailing lists > Public > public-css-archive@w3.org > December 2020

Re: [csswg-drafts] [css-text-3] Note unclear in bidi & line boxes (#5759)

From: r12a via GitHub <sysbot+gh@w3.org>
Date: Fri, 04 Dec 2020 14:56:13 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-738828856-1607093772-sysbot+gh@w3.org>
Here's a schematic of how i see the structure here, and an example of some text following the rules set out in this spec.

![Screenshot 2020-12-04 at 13 36 26 copy 2](https://user-images.githubusercontent.com/4839211/101176415-5cef7000-363e-11eb-9535-7d7414860f82.png)

A container (eg. a textarea) contains paragraphs, which in turn contain one or more line-boxes.

Note that the second line box from the top (the middle one) contains no directionally strong characters, but the base direction applied to the content is still RTL, because that information comes from the paragraph direction.

The bottom line box is contained within a paragraph that has content that is ordered LTR because the paragraph has no strong directional character, but the alignment is RTL because paragraphs with no strong directional character in plaintext take their alignment from the preceding paragraph (or the overall container, if there isn't one).

Current text in ED says:

> The start and end sides of a line box are determined by the inline base direction of the line box. Although they usually match, the inline base direction of a line box is distinct from the inline base direction of the containing block or the bidi paragraph. The line box’s inline base direction affects text-align-all, text-align-last, text-indent, and hanging-punctuation—i.e. the position and alignment of its contents with respect to its edges. It does not affect the formatting or ordering of inline content (which is controlled by the Unicode bidirectional algorithm as applied by [CSS-WRITING-MODES-3]). 

I would suggest:

The start and end sides of a line box are determined by the inline base direction of the **bidi paragraph**. Although they usually match, the inline base direction of a line box **can be** distinct from the inline base direction of the **bidi paragraph** or the **containing block**, **if the paragraph contains no strong directional characters**. The **paragraph**’s inline base direction affects text-align-all, text-align-last, text-indent, and hanging-punctuation—i.e. the position and alignment of its contents with respect to its edges. It **also affects** the formatting or ordering of inline content **unless the paragraph contains no strong directional characters** (**in which case, the ordering of content** is controlled by the Unicode bidirectional algorithm as applied by [CSS-WRITING-MODES-3]). 

-- 
GitHub Notification of comment by r12a
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/5759#issuecomment-738828856 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Friday, 4 December 2020 14:56:16 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:42:23 UTC