Skip to content

compiler: add LTAT/RTAT runtime font profile - #7

Draft
mustafa0x wants to merge 1 commit into
DigitalKhatt:stdlibconvfrom
mustafa0x:compiler/runtime-font-profile
Draft

mustafa0x wants to merge 1 commit into
DigitalKhatt:stdlibconvfrom
mustafa0x:compiler/runtime-font-profile

Conversation

@mustafa0x

@mustafa0x mustafa0x commented Sep 16, 2026

Copy link
Copy Markdown

Summary

Add an explicit --runtime-font mode to the Qt-free OpenType generator.

The mode:

  • implies extended variable output;
  • emits exactly LTAT at index 0 and RTAT at index 1;
  • keeps the normal project-defined axis profile, including Madina's SCLX, unchanged outside runtime mode;
  • serializes normalized tatweel values for single, expansion, and alternate extended substitutions;
  • validates signed axis ranges, tatweel bounds, and variation delta dimensions;
  • produces deterministic output under SOURCE_DATE_EPOCH.

It does not add platform adapters, page APIs, or runtime integration.

Validation

Using madinafont/stdlibconv and the native plugin-loading fix in #6:

  • Release Qt-free compiler and Madina plugin builds passed in two independent build directories.
  • Standard, extended, and runtime output was byte-identical across the independent builds under SOURCE_DATE_EPOCH=1700000000.
  • Standard output SHA-256: 843af0296afd86accdbb7191254689ebf3d1ff489a3012f5d484eb94b71cb318.
  • Extended output SHA-256: f5d3ea264ec9c10008875fd94e4859578ee1d84e9ad2e235301e4d69c70c23b9.
  • Runtime output SHA-256: 2d05d40f2c23057e148c42efe8cb21e1f92c22d29cc8476f7857dbfc5273c082.
  • Standard output retained SCLX [50, 100, 200] and omitted JTST. Its content tables remained byte-compatible with the clean loader-only baseline; head reflects deterministic checksum/timestamps and hhea now uses initialized aggregate metrics.
  • --runtime-font produced a 3,256,512-byte font with CFF2, GSUB, GPOS, GDEF, JTST, fvar, and HVAR.
  • The only runtime variation axes were LTAT [-20, 0, 20] and RTAT [-20, 0, 20], in that order.
  • The runtime GDEF variation store parsed completely with 208 rows and no all-zero rows.
  • The generated runtime font passed the standalone C runtime's direct-HarfBuzz conformance suite, including shaping, target-width justification, and base/dynamic CFF2 outlines.

Dependency

@mustafa0x
mustafa0x force-pushed the compiler/runtime-font-profile branch 2 times, most recently from 1e3b531 to f2b0638 Compare September 17, 2026 13:15
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