You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 355a469
Browse filesBrowse the repository at this point in the historyBrowse files
fix(engine): let an author say where Arabic must not join
The zero-width non-joiner and joiner are how Unicode lets an author
override contextual joining — U+200C forbids a join the letters would
otherwise make, U+200D forces one — and both were deleted before the
shaper, the only thing that reads them, ever ran. They are category C
like any other control, so the sanitizer that runs first removed them
along with the rest, and a document could not express the distinction
at all.
The shaper needed almost nothing for the non-joiner: it is an opaque
non-joining character, so the lookups that walk letters already came to
the right answer once it survived. The joiner is the one that had to be
taught, since it stands in for a letter that is not there. Both are
consumed during shaping, because past that point they are code points no
font can encode — measured as one thing and drawn as a substitution
mark. Text with no Arabic in it never reaches the shaper, so the glyph
seam drops them there instead.
The joining controls get their own predicate rather than joining the
bidirectional ones: these say nothing about direction, only about
whether two letters connect.
Also:
- Auto-size measured a highlight run unshaped while the token it builds
from that run is shaped, so a chip was sized against a string the
layout never uses. Both paths shape now. This is not currently visible
end to end, because auto-size does not shrink a paragraph holding a
chip at all for any script, which is its own defect.
- The degraded-shaping warning is keyed on the font rather than on
(font, code point). A font that carries no presentation forms carries
none of them, so the second letter said nothing the first had not, and
a document turned one fact about the font into a warning per letter.
- The changelog claimed mirroring per UAX #9 L4 without the scope the
implementation has always documented: the punctuation that occurs in
documents, not the whole mirroring table.
0 commit comments