brew install fontforge harfbuzz
pip install .[dev]The SignWriting One-Dimensional font is a font that can be used to display SignWriting in a single line of text. Created by Stephen Slevinski, it is available for download here, and rebuilt in this repository at fonts/SuttonSignWritingOneD.ttf.
The Sutton TTFs are built by FontForge from cubic-Bezier SVG sources; the cubic
curves are approximated as quadratics during TTF generation, which introduces
shape drift. To stay closer to the source we rebuild the 1D font from
@sutton-signwriting/font-db's cubic SVGs directly.
make fonts/SuttonSignWritingOneD.ttfThe pipeline:
signwriting_fonts/font_1d/extract.pyreadsfonts/tmp/iswa2010.db(the font-db SQLite blob, fetched by the Makefile) and writes one SVG per symbol intofonts/tmp/1d/svg/. Thesym-fill(white-interior) path is dropped — 1D glyphs are monochrome.signwriting_fonts/font_1d/optimize.pydetects circular sub-paths via LSQ circle fit (robust to one outlier) and replaces them with a 4-segment cubic-Bezier ellipse (~0.027 % radius error). This both shrinks the path data and removes hand-traced wobble.signwriting_fonts/font_1d/build_font.pyis a FontForge Python script that creates one glyph per SVG, maps each to its plane-4 SWU codepoint, and emits the final TTF. No GSUB/GPOS layout step is needed — outline-level composite-glyph dedup is the entire size win.
By default the extractor pulls every symbol in iswa2010.db. Pass
--symbols S100 S200 … (or --symbols dev for the hand-picked dev subset
in extract.py) to restrict the build for fast iteration.
The SignWriting Two-Dimensional font is a font that can be used to display SignWriting in a two-dimensional grid. This is designed for use cases where TTF fonts are supported, but SVG images are not, such as video captioning.
Created by this project, it is available for download at fonts/SuttonSignWritingTwoD.ttf.
make fonts/SuttonSignWritingTwoD.ttfThe build has no Perl/CPAN dependency anymore — pip install .[dev] covers the GPOS compile step. (make itself still shells out to ttx, hb-view, and wget for the surrounding pipeline.)
SignWriting's 2D layout encodes each positioned symbol as a 3-codepoint
cluster: <symbol Sxxxxx><x-position SW{x}><y-position SW{y}>, with
x, y ∈ [250, 749] and SW750 as the M-box origin. The font's job is
to read the SW{x} SW{y} markers and shift the preceding symbol by
(x - 750, 750 - y).
-
Glyph source.
signwriting_fonts/font_2d/modify_ttx.pyround-tripsSuttonSignWritingOneD.ttfthrough TTX to fix naming, replace the M marker with a 500×500-unit box, drop the number glyphs (used here as position markers only), and scale every symbol to fit inside the M-box. -
Axis-decomposed GPOS.
signwriting_fonts/font_2d/add_gpos.pyadds the positioning table directly via fontTools. Instead of one lookup per(x, y)pair (which would be 500 × 500 = 250 000 rules and exceed every OT-table size limit), positioning is split into independent X and Y axis rules that stack via standard GPOS accumulation:- one chained-context lookup per X coordinate matching
<symbol> SW{x} <any-marker>and shifting by(x - 750, 0); - one chained-context lookup per Y coordinate matching
<symbol> <any-marker> SW{y}and shifting by(0, 750 - y).
The full symbol range (
S10000–S38b07, ~37 800 glyphs) is split into three input partitions because harfbuzz silently drops a chained-context lookup whose input coverage exceeds ~32 k glyphs. Each coordinate's three single-position subtables share one inner lookup, while all disjoint chained-context subtables for an axis share one outer lookup. The full range therefore needs 1,002 top-level lookups instead of 6,000. Every lookup is wrapped in aLookupType 9extension so its large subtables use 32-bit offsets.--coords "250-749"is the default (500 X values × 500 Y values = 250 000 addressable positions), covering the complete SignWriting coordinate range. - one chained-context lookup per X coordinate matching

