Skip to content

fix(matrix): wrapped runs enter the font subset - #6

Merged
eli64s merged 2 commits into
mainfrom
fix/matrix-font-surface
Sep 15, 2026
Merged

eli64s merged 2 commits into
mainfrom
fix/matrix-font-surface

Conversation

@eli64s

@eli64s eli64s commented Sep 15, 2026

Copy link
Copy Markdown
Contributor

Summary

Wrapped matrix text shipped without its glyphs. The matrix repair on main wraps cell text, notes, and headers into runs, but the font-surface collector only read the single-line fields. In the default embed mode Ω b d g i s rendered as tofu or fell back to a host font.

Separately, main is red. Four assertions searched the whole SVG for the digits 1200, which timestamps, digests, and font bytes all match. One run spelled them by chance.

Changes

  • Font surface: _text_surface collects text_lines, sub_lines, and header lines. Every painted run reaches the subsetter.
  • Tofu gate: A wrapped matrix with Ω, ß, Ü, Ø, and μ joins the per-frame cases. A corpus check asserts every rendered codepoint is in the embedded cmap.
  • Text-layer assertions: rendered_text joins the painted <text> and <tspan> nodes. The stats-card and chart-frame checks read it instead of the raw SVG, which is the red CI fix.

Validation

Gate Result
Tofu gate on old collector 2 failed: wrapped case and corpus case
Tofu gate on this branch 22 passed
Matrix frame · font subsetting · stats card · chart frame · chart engine 140 passed
ruff check · ruff format --check · ty check clean
Full just qa not run locally; CI runs it here

@eli64s
eli64s merged commit 1d0ec14 into main Sep 15, 2026
6 checks passed
@eli64s
eli64s deleted the fix/matrix-font-surface branch September 15, 2026 12:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant