= Font line gap
A <font line gap> is a font-wide metric giving an additional spacing allowance to combine with <font ascent> and <font descent>. For an elementary default line-spacing calculation using signed descent $d_f$,
$$
H=a-d_f+g,
$$
where $a$ is the ascent and $g$ the <font line gap>. <OpenType>'s `sTypoLineGap` is intended to be used with the matching `sTypoAscender` and `sTypoDescender` fields.<OS 2 and Windows Metrics Table by Microsoft>[sTypoLineGap and its relationship to the other typographic metrics]{ref}
Suppose the chosen metrics are $a=760$, $d_f=-240$ and $g=100$ <font units>. The default spacing is 1100 <font units>. With 1000 <font units> per <em> at 18 <pixels per em>, that is 19.8 <pixels> between <text baselines>.
The stored <font line gap> provides an input to a spacing decision. An application can instead request a different <line height>, and <CSS leading> is then calculated from that requested height and the selected metrics. Nor does the <font line gap> measure the visible blank strip between every pair of lines: the ink <bounding boxes> vary with the particular <glyphs>. The <line height> diagram shows this distinction with schematic ink inside larger font-wide metric regions.
Back to article page