@@ -5721,51 +5721,37 @@ Bidirectionality and Line Boxes</h3>
57215721
57225722
57235723 <div class="example">
5724- <p> In the following example:
5724+ <p> Because neutral characters (such as punctuation)
5725+ and isolated runs are skipped
5726+ when <a href="http://unicode.org/reports/tr9/#P2">finding the inline base direction of a plaintext bidi paragraph</a> ,
5727+ the line box in the following example will be left-to-right
5728+ (and thus left-aligned given ''text-align: start'' ),
5729+ as dictated by the first strong character, ‘h’:
57255730 <pre>
57265731 <para style="display: block; direction: rtl; unicode-bidi:plaintext">
5727- <quote style="unicode-bidi:plaintext">שלום!</quote>" , he said.
5732+ “ <quote style="unicode-bidi:plaintext">שלום!</quote>” , he said.
57285733 </para></pre>
5729-
5730- <p> The result should be a left-aligned line looking like this:
5731- <pre> "!שלום", he said.</pre>
5732-
5733- <p> The line is left-aligned
5734- (despite the containing block having ''direction: rtl'' )
5735- because the containing block (the <code> <para></code> ) has ''unicode-bidi:plaintext'' ,
5736- and the line box belongs to a bidi paragraph that is LTR.
5737- This is because that paragraph's first character with a strong direction
5738- is the LTR "h" from "he". The RTL "שלום!" does precede the "he",
5739- but it sits in its own bidi-isolated paragraph that is <em> not</em>
5740- immediately contained by the <code> <para></code> ,
5741- and is thus irrelevant to the line box's alignment.
5742- From from the standpoint of the bidi paragraph immediately contained
5743- by the <code> <para></code> containing block,
5744- the <code> <quote></code> ’s bidi-isolated paragraph inside it is,
5745- by definition, just a neutral U+FFFC character,
5746- so the immediately-contained paragraph becomes LTR by virtue
5747- of the "he" following it.
57485734 </div>
57495735
57505736 <div class="example">
57515737 <pre>
5752- <fieldset style="direction: rtl">
5753- <textarea style="unicode-bidi:plaintext">
5738+ <textarea style="direction: rtl; unicode-bidi:plaintext">
57545739
57555740 Hello!
57565741
57575742 </textarea>
5758- </fieldset></pre>
5759-
5760- <p> As expected, the "Hello!" should be displayed LTR
5761- (i.e. with the exclamation mark on the right end,
5762- despite the <code> <textarea></code> ’s ''direction:rtl'' )
5763- and left-aligned.
5764- This makes the empty line following it left-aligned as well,
5765- which means that the caret on that line should appear at its
5766- left edge. The first empty line, on the other hand, should
5767- be right-aligned, due to the RTL direction of its containing
5768- paragraph, the <code> <textarea></code> .
5743+ </pre>
5744+
5745+ <p> Because of ''unicode-bidi: plaintext'' ,
5746+ the “Hello!” is typeset LTR
5747+ (i.e. with the exclamation mark on the right side)
5748+ and left-aligned,
5749+ ignoring the containing block’s RTL 'direction' .
5750+ This makes the empty line following it LTR as well,
5751+ which means that a caret on that line should appear at its left edge.
5752+ The empty first line, however, is right-aligned:
5753+ having no preceding line,
5754+ it assumes the RTL direction of its containing block.
57695755 </div>
57705756
57715757<h2 class="no-num" id="order">Appendix A:
0 commit comments