-
Notifications
You must be signed in to change notification settings - Fork 734
Description
section-5 (https://drafts.csswg.org/css-text-3/#line-breaking) talks about soft and forced line break but says nothing about the effect, i.e. the rendering. Is it the same in both cases? That is, if a line is wrapped at some place, should the resulting lines appear as if it was a forced break at the same place?
As for bidi texts, if a line break occurs inside a phrase that is progressing in opposite direction, wrt the surrounding context, the break (rightfully) does not end the "embedded" base direction, unlike HTML <br>
.
As a consequence, if the next line begins with a directionally ambiguous character, the rest of the phrase takes the global opposite base direction.
Example (in RTL context):
The 1st two lines result from a text wrapped (soft-break) before the number 2. The whole Latin string flows LTR. Then the same text with forced-break at the same position. In the last line, the rest of the Latin string flows RTL.
Looks odd to me.
Source:
<div dir="rtl" style="width: 50%;">
<p>
تحدثنا وقالت في لغتها:
« I should be living at 2, Atlas street</span> »
ثم ذهبت.
</p>
<p>
تحدثنا وقالت في لغتها:
« I should be living at<br> 2, Atlas street</span> »
ثم ذهبت.
</p>
</div>
note <br>
before 2
in the second <p>
.
Can CSS line breaking spec/rules consider such case (or similar)? I didn't see that in the document.
Or simply indicate in the first para of section-5 (https://drafts.csswg.org/css-text-3/#line-breaking), that forced break and soft break occurring at the same point, may have differences in rendering for some scripts (or something like).