Skip to content

opentype__code_pages

Simon Cozens edited this page May 8, 2025 · 1 revision

Check code page character ranges

opentype/code_pages

  • Applies to: TTF
  • Fontspector can hotfix?: no
  • Fontspector can fix sources?: no

Rationale

At least some programs (such as Word and Sublime Text) under Windows 7 do not recognize fonts unless code page bits are properly set on the ulCodePageRange1 (and/or ulCodePageRange2) fields of the OS/2 table.

More specifically, the fonts are selectable in the font menu, but whichever Windows API these applications use considers them unsuitable for any character set, so anything set in these fonts is rendered with Arial as a fallback font.

This check currently does not identify which code pages should be set. Auto-detecting coverage is not trivial since the OpenType specification leaves the interpretation of whether a given code page is "functional" or not open to the font developer to decide.

So here we simply detect as a FAIL when a given font has no code page declared at all.

Proposal

Profiles

  • opentype (in section 'Opentype Specification Checks')

  • universal (in section 'Opentype Specification Checks')

  • googlefonts (in section 'Opentype Specification Checks')

Clone this wiki locally