FontForge Proportional vs Monospaced Metrics
FontForge handles proportional and monospaced font metrics by altering how advance widths, side bearings, kerning, and metadata flags are assigned across a typeface. While proportional fonts rely on individual, visually balanced character widths and dynamic pair adjustments, monospaced fonts require strict, uniform horizontal spacing enforced by specific font tables. Understanding how FontForge manages these distinct paradigms is essential for producing correctly spaced typography.
Managing Proportional Font Metrics
In a proportional font, every glyph has a unique advance width determined by its visual weight and contour design. FontForge provides dynamic tools to manage these variable distances:
- Advance Widths and Side Bearings: You can adjust
the Left Side Bearing (LSB) and Right Side Bearing (RSB) for each glyph
individually in the Glyph Window or interactively in the Metrics Window
(
Metrics > Open Metrics Window). The total advance width is the sum of the LSB, the glyph outline width, and the RSB. - Auto-Spacing: FontForge includes an automated
spacing algorithm (
Metrics > Auto Width) that analyzes glyph contours and calculates optical side bearings to balance whitespace across the character set. - Kerning Pairs and Features: Proportional fonts rely
heavily on kerning to resolve awkward collisions (such as "AV" or "To").
FontForge handles this via OpenType features configured in
Element > Font Info > Lookups. You can create GPOS lookup tables for pair-to-pair kerning or class-based kerning, allowing specific glyph combinations to override default advance widths.
Managing Monospaced Font Metrics
Monospaced fonts demand that every single glyph shares the exact same advance width. FontForge controls this through uniform numerical assignments and dedicated structural flags.
- Setting a Global Advance Width: To establish
monospaced spacing, select all glyphs in the Font View
(
Ctrl+A) and chooseMetrics > Set Width.... Entering a fixed value (such as 500 or 600 units, depending on your Em size) assigns an identical horizontal advance across all selected glyphs. - Centering Glyphs: Because the advance width is
fixed, characters with narrow outlines (such as "i" or ".") must be
centered within the slot. FontForge allows you to center glyphs within
their new widths using
Metrics > Center in Width. This automatically distributes the remaining space equally between the LSB and RSB. - Eliminating Kerning: Monospaced typefaces generally
do not use kerning. Any existing horizontal kerning lookups in
Element > Font Info > Lookupsmust be removed to prevent software from altering character cell widths.
Monospaced Flags and Font Tables
Setting identical advance widths is not enough for an operating system to classify a font as monospaced. FontForge requires specific metadata to be toggled:
- PostScript Properties: In
Element > Font Info > PostScript, check the isFixedPitch box. This sets the Boolean flag that tells rendering engines the font has uniform metrics. - PANOSE Classification: In
Element > Font Info > OS/2 > PANOSE, set the Proportion dropdown menu to Monospaced. - TrueType/OpenType Tables: When generating the font,
FontForge sets the
hhea(Horizontal Header) andOS/2table values—such asxAvgCharWidthandmaxAdvanceWidth—to match the uniform width, ensuring terminal emulators and code editors render the font correctly on a strict grid.
Validating Metrics
FontForge includes a verification tool to ensure consistency. By
opening Element > Find Problems and navigating to the
Spacing / Kerning tab, you can test whether any glyphs
deviate from the required advance width. This helps catch unassigned
widths, accents, or hidden non-spacing characters before generating the
final font binary.