Skip to content

M9: place Japanese vertical punctuation using font metrics - #298

Merged
h-a-n-a-s-h-i merged 1 commit into
storytold:mainfrom
midasdf:fix/vertical-japanese-punctuation
Oct 9, 2026
Merged

h-a-n-a-s-h-i merged 1 commit into
storytold:mainfrom
midasdf:fix/vertical-japanese-punctuation

Conversation

@midasdf

@midasdf midasdf commented Oct 8, 2026

Copy link
Copy Markdown
Contributor

Vertical Source Text shapes Japanese punctuation using horizontal glyphs, then keeps them upright around a horizontal-font centre. Enable vert/vrt2 only for CJK runs and position their outlines from the font's VORG/vmtx vertical origin and horizontal advance. Update outline_xf with the same placement so animated/variable-outline redraws agree. Half-width Roman text stays sideways and tate-chu-yoko stays horizontally shaped.

The regression fails on unchanged main and verifies vertical glyph IDs, upper-right comma/full-stop ink, unchanged horizontal cache entries and tracking-independent cross-column placement. Text-package debug/release tests pass (43 unit + 2 integration), including the new punctuation regression in its own process so native font probing does not affect fallback tests. Package Clippy (with the existing collapsible_match exception) and wasm check pass; Shippori Mincho output was also rasterized and inspected using locally loaded OFL font data. No font assets, project-schema fields, UI controls or ROADMAP log are added. This is independent of the open toolbar PR #213.

Stock cargo xtask ci stops at existing clippy::collapsible_match warnings in unchanged path_text/audio_fx/generate code. Asset/layer checks and the full lower-crate wasm gate passed. This fixes vertical forms/origins, not complete Japanese paragraph composition.

Reference: OpenType vertical forms, JLReq punctuation placement.

Co-Authored-By: Codex <noreply@openai.com>
@h-a-n-a-s-h-i
h-a-n-a-s-h-i merged commit 1f52183 into storytold:main Oct 9, 2026
@echelon

echelon commented Oct 9, 2026

Copy link
Copy Markdown
Member

Merged. Thanks! Vertical Japanese punctuation from VORG/vmtx is a real fidelity win. One heads-up: the test skips when no Japanese font is installed, so CI may not exercise it.

If you haven't joined yet, come hang out with us on Discord: https://discord.gg/artcraft

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.

3 participants