Repository navigation
Fonts: subset appfont-cjk.ttf to cmap-reachable glyphs so webOS 3/4 FreeType opens it (#628) - #709
Merged
Merged
Conversation
… 2.7.0 opens it; libass no longer copies it The CJK fallback had 65535 glyphs, so its long loca was exactly 0x40000 bytes, which FreeType 2.4.11-2.7.0 (ttpload.c: table_len >= 0x40000) rejects with error 8; several firmware inventories ship such a FreeType. Only 44,074 glyphs are reachable from the cmap (the rest were GSUB alternates, dead since the cut drops GSUB). tools/cut-noto-cjk.py now runs the fontTools subsetter keeping all 44,810 codepoints and the 12-selector cmap-14 UVS: 44,097 glyphs, 13.42 MB raw / 7.45 MB gzip-9 (was 21.19 / 11.34). Outlines and advances are identical for all 44,810 mapped codepoints and the 28 UVS glyphs. fontcov.rs gains shipped_faces_open_under_old_freetype (red on the old file). Behaviour change: ass.rs no longer adds appfont-cjk.ttf as a libass memory font per renderer (a malloc+copy, plus a transient fs::read, per windowed-sidecar slide, reachable only by the family name "Noto Sans CJK KR"). Glyph fallback goes through libass's default font path, which maps the file; Inter regular/bold stay memory fonts. A native test covers a CJK line in an unknown-family style. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
GLinnik21
enabled auto-merge (squash)
October 14, 2026 23:16
…names its own row check-package.py asserted pkg/appfont-cjk.ttf > 15 MB, a floor set for the uncut 21 MB face; the subset ships at 13.4 MB, so every ipk build failed it. fontcov.rs's cmap gate is what proves the face whole, this only catches absence. test_the_wire_log_says_how_long_a_page_was_in_flight took the first wire row for the path, which could be the previous test's row landing after DELETE /_mock/wire (start=None); it now selects the row by its own start. Co-Authored-By: Claude Opus 5.5 <[email protected]>
GLinnik21
added a commit
that referenced
this pull request
Oct 22, 2026
* Release notes and audit for v0.9.0 Action-required evaluation (README trigger list, read from the PRs, grep not run on a built tree): no hits that need a reader action. Launch links (#853) add an inbound surface (any app that can launch apps), stated in What's new; the 3.4 image cache writes to /media/developer/temp (#667); crash/error reports gain fixed-value fields with POLICY_VERSION unchanged (#632), stated under Changed; Watchlist and PMS notifications use hosts the app already reaches. Co-Authored-By: Claude Opus 5.5 <[email protected]> * Release notes v0.9.0: coverage and accuracy pass Note: correct the Collections surfaces (no TYPE menu; collection shelf headings live on Home and a library's Recommended page), the Watchlist hold-menu rows, the launch-link sign-in behaviour and platform-release numbering, the notification-feed sentence and the per-profile settings list (no stale "nine"). Add #832, #808, #750/#762, #709 (#628), #641, #647, #793, #871, #877 (#679), #876 and the key-press frame work; credit RichiL10 and Shakil Choudhury. #862 moves from Known issues to the webOS 3.x lines as fixed by #578; the 3.9.3 source-build report (#700) is kept in Compatibility. Compatibility links reports, not reporters' profiles. Audit: #862 provenance (attributed usage-report reading, no counts), contributor list wording. Action-required section: not owed. The README grep over v0.8.0..origin/main (rust-modules/src src ci) hits only CI tooling, test-only loopback listeners and fixture tokens, and the dev-only /tmp/plxnative-trackmemory trigger; the audit's PR-by-PR reading in "Deliberately not done" stands. Co-Authored-By: Claude Opus 5.5 <[email protected]> * Release audit v0.9.0: name the toolchain by its pin file, not its version Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #628
The reporter's set (55SK8500PCA, webOS 4.x) could not have drawn CJK even with correctly decoded text: the bundled
appfont-cjk.ttf(Noto Sans CJK KR) had 65,535 glyphs, so its longlocatable was exactly 0x40000 bytes, and FreeType 2.4.11–2.7.0 (webOS 3.x/4.x system FreeType, used by SDL2_ttf) rejects that face withInvalid_Table. The charset half of #628 is the companion PR forfix-628-subtitle-charset.What changes
tools/cut-noto-cjk.pysubsets the face to the 44,097 glyphs reachable from its cmap (keeping the variation-selector table) — no coverage is dropped.pkg/appfont-cjk.ttfregenerated: 21,185,868 → 13,417,156 bytes (−7.4 MiB; ipk gzip-9 ≈ 11.34 → 7.45 MB).base/src/fontcov.rs: new testshipped_faces_open_under_old_freetype— every shipped face has numGlyphs ≤ 65,534 and a longlocaunder 0x40000.media/src/player/ass.rs: libass no longer copies the CJK face into a memory font (it stays thepath_defaultfallback), avoiding a second in-process copy of the face.docs/agent-reference.md,fontcov.rs,text.rs).Verification
loca= 0x40000).make checkexit 0 (everytest result: ok, 0 failed);cargo check --lib --no-default-featuresclean.gfx/text.rsover the system SDL2_ttf/FreeType) render through the subset face.make build-bench(same sitting, M4 10 cores, 3 runs; host load was above core count throughout, so treat deltas inside the spread as noise; the base checkout had notarget-fast, so its incremental rows are skipped). The build-relevant change is Makefile comments only.Base:
font-cjk-subset (2bec93d):
🤖 Generated with Claude Code