Files
CamWight 371d25dadd Drawings on the web: Arabic, Korean and Chinese text is set in fonts the web app fetches (#4890) (#11790)
The web covered Japanese only (F6): any other script on a drawing was
refused. Now each script the web covers has its own font, fetched once
from the web app's origin the first time a drawing's text needs it:

- kana and Japanese Han: BIZ UDPGothic, as before;
- Hangul and Korean Han: Noto Sans KR;
- simplified or traditional Chinese Han: Noto Sans SC or TC;
- Arabic: Noto Sans Arabic.

Han takes the font of whose Han the text wants (Han::of, the desktop's
rule), so a drawing in English with Han asks for the simplified Chinese
font, as a desktop does; F6 sent all Han to the Japanese font. A text in
two scripts waits for both fonts; one whose fetch failed is refused by
name, and the rest sets. Thai is still refused by name (Hebrew is in the
built-in font).

The four fonts and their licences are unmodified, in assets/fonts/<family>/
with ATTRIBUTION rows, and trunk copies each to fonts/<family>/. Four
files rather than one CJK collection: a session fetches only its own
language's font (4.6 to 8.3 MB), where the collection is one large file.

The folder the web app fetches fonts from is named once (FONTS), and a test
checks that index.html copies each font from its asset into that folder.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-04 21:20:50 -05:00
..