Skip to content

Add font comparison test stand for GF build validation#3

Draft
psd-coder wants to merge 4 commits intomainfrom
gf-fonts-test-stand
Draft

Add font comparison test stand for GF build validation#3
psd-coder wants to merge 4 commits intomainfrom
gf-fonts-test-stand

Conversation

@psd-coder
Copy link
Copy Markdown
Member

Overview

Adds a browser-based visual comparison tool for validating that the GF-compliant font rebuild didn't break any glyphs compared to the original designer fonts.

Note: This is a temporary testing artifact for the GF build branch, not intended to be merged into main.

Problem Statement

After rebuilding fonts with GF-compliant naming and tooling, there was no way to visually verify that glyph shapes remained identical across all 662 codepoints, 7 widths, and 9 weights.

Solution Approach

  • Created documentation/comparison/index.html: a self-contained HTML page that loads both old (designer) and new (GF) variable fonts side by side
  • Extracted all 63 old static TTFs from main branch into documentation/comparison/old-ttf/ with full name mapping (e.g. Cn -> Condensed, Nr -> SemiCondensed, Std -> Normal, etc.)
  • Comparison modes: side-by-side grid of all glyphs grouped by Unicode block, fullscreen single-glyph view with overlay mode (old in red, new in blue, overlap in pink)
  • Controls: variable/static font source toggle, weight/width sliders or dropdowns, glyph size, opacity for overlay layer
  • Glyph coverage analysis baked in: 522 shared codepoints, 140 new (mostly Cyrillic extended), 0 lost

Testing

Open documentation/comparison/index.html in a browser. Click any glyph to inspect it fullscreen. Use overlay mode with opacity slider to spot shape differences. Switch between variable and static font sources to verify all 63
width/weight combinations.

@psd-coder psd-coder self-assigned this Mar 24, 2026
@psd-coder psd-coder force-pushed the gf-fonts-test-stand branch 3 times, most recently from 0e292db to f0756ce Compare March 24, 2026 21:20
Add config.yaml, requirements.txt, AUTHORS.txt, CONTRIBUTORS.txt, .gitignore, and Instructions.txt for Google Fonts compliance.

Add build.py that patches glyphsLib Smart Component bugs at runtime (Group key handling + missing masters for UltraBlack) before running gftools builder. Original source is never modified.
Do a set of changes described in the Instructions.txt. Replace designer-named fonts (Cn/Nr/Std/sWd/Wd/xWd/uWd shorthand naming) with GF-spec builds: standard width/weight naming, STAT table, variable font named MartianGrotesk[wdth,wght].ttf, covering 63 statics + VF across 7 widths x 9 weights in TTF, OTF, and WOFF2 formats.
Add sources/build.sh as single-command entry point per Google Fonts upstream guide.
HTML page for visual validation of GF build against designer fonts: side-by-side and overlay glyph comparison across all Unicode blocks, with variable and static font support (7 widths x 9 weights), fullscreen single-glyph view, and controls for weight, width, opacity, and glyph size.
@psd-coder psd-coder force-pushed the gf-fonts-test-stand branch from f0756ce to 694ab6d Compare March 25, 2026 23:36
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