Re: [csswg-drafts] [css-text] letter-spacing should not apply to the end edge of a line/span? (#1518)

Started thinking about the "switch" in level 4, but then I found this is more complicated than I originally thought, because we don't know which character comes to the edge until we run the bidi algorithm, but that is after line break.

One possible idea is to compute line breaking by adding to the right of every character/atomic inline. Then after lines are broken and applied the bidi algorithm, but before computing alignment/justification, remove the spacing from the right end of each `letter-spacing` run. This can make the line overflow the available width if large negative `letter-spacing` is used, but probably acceptable because glyphs look overflowing anyway in such case.

Maybe there could be other ideas, I'll think about it a little more.

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

Received on Sunday, 19 July 2020 18:08:46 UTC