openpencil/tests
Danila Poyarkov 0d1f42f0b1
Fix CJK text garbled when font unavailable (#89)
* Fix CJK text garbled when font unavailable (#69)

Always use buildParagraph for text rendering when fonts are loaded,
even when the node's specific font isn't available. The paragraph
shaper falls back to the CJK font in fontFamilies, instead of the
previous drawText fallback which used Inter (no CJK glyphs).

* Add renderText unit tests for CJK font fallback behavior

* Add CJK visual regression test with Noto Sans SC fixture

- Download NotoSansSC-Regular.ttf as LFS-tracked test fixture
- Add setCJKFallbackFamily() export for headless/test use
- Visual test verifies CJK text renders through buildParagraph fallback
  when node font is unavailable (the exact PR #89 scenario)
- Assert dark pixel count > 500 to distinguish real glyphs from tofu
2026-03-10 16:58:57 +03:00
..
e2e Fix double-click rename in layer tree and pages panel 2026-03-08 22:58:38 +03:00
engine Fix CJK text garbled when font unavailable (#89) 2026-03-10 16:58:57 +03:00
figma Playwright visual regression testing with Figma CDP reference 2026-02-28 07:32:15 +03:00
fixtures Fix CJK text garbled when font unavailable (#89) 2026-03-10 16:58:57 +03:00
helpers Merge PR #70: E2E test coverage + mutation unit tests 2026-03-07 23:47:00 +03:00