Description
The Segment Break Transformation Rules says this:
If the character immediately before or immediately after the segment break is the zero-width space character (U+200B), then the break is removed, leaving behind the zero-width space.
It means that
aaaa​
bbbb
is rendered as if it were
aaaa​bbbb
I like it, but:
- If there is an inline box boundary between the U+200B and the segment break, does it still count as "immediately before or immediately after" or not? Since inline box boundaries are not meant to affect text layout, I'd say yes, but I don't know for sure that this is what the spec means. In other words, does
get rendered as if it were
aaaa<span>​</span> bbbb
oraaaa<span>​</span>bbbb
aaaa<span>​</span> bbbb
- Assuming inline boundaries don't make a difference (otherwise the point is moot), does the display value of the U+200B matter? Obviously, if it has a display value that makes it not inline, then it does, but what if it's display none? In other words, does
get rendered as if it were
aaaa<span style=display:none>​</span> bbbb
oraaaabbbb
aaaa bbbb
I'd propose clarifying the sentence to:
If the character immediately before or immediately after (ignoring any intervening inline box boundaries) the segment break is the zero-width space character (U+200B) and the computed value of the 'display' property on that character is not ''none'', then the break is removed, leaving behind the zero-width space.
I suppose the alternative would be to consider that this operation works on the element tree rather than the box tree, but that seems weird.