{"course":{"slug":"vector-and-print","title":"Vectors, Logos and Things That Get Printed","url":"https://addaly.com/learn/vector-and-print","level":"beginner","track":"create"},"lesson":{"slug":"what-is-inside-a-font-file","title":"What is actually inside a font file","url":"https://addaly.com/learn/vector-and-print/what-is-inside-a-font-file","position":19,"of":73,"minutes":9,"answer":"A font is a set of tables (outlines, a character map, widths, kerning, substitutions and a permission bit) and pdffonts plus fonttools will tell you in seconds what a font menu never will.","keyIdea":"A font is a set of tables (outlines, a character map, widths, kerning, substitutions and a permission bit) and `pdffonts` plus `fonttools` will tell you in seconds what a font menu never will."},"body":{"format":"markdown","text":"## A font is a database with drawings in it\n\nA `.ttf` or `.otf` file is a container of tables. Five of them decide everything you experience.\n\n- **`glyf` or `CFF `**: the outlines. TrueType (`glyf`) stores **quadratic** Béziers: one handle per segment. PostScript/OpenType-CFF stores **cubic** Béziers: two handles, the same curves your drawing program uses.\n- **`cmap`**: the map from character codes to glyphs. `U+0041` → glyph 36. Without this, the font has shapes but nobody can type them.\n- **`hmtx`**: advance widths. How far the pen moves after each glyph.\n- **`kern` or `GPOS`**: the adjustments between specific pairs.\n- **`GSUB`**: substitutions: ligatures, small caps, alternates, and all the conjunct machinery that complex scripts depend on.\n\nPlus `OS/2`, which carries the licensing flags, and `name`, which carries the family and style names the print shop will see in a font list.\n\n> Figure: The tables inside a font file. Layers, top to bottom: glyf or CFF (The outlines. TrueType quadratic, CFF cubic); cmap (Character code to glyph. Without it nobody can type it); hmtx (Advance widths: how far the pen moves each time); kern or GPOS (Adjustment between one specific pair and the next); GSUB (Ligatures, small caps, and every conjunct); OS/2 (fsType, the bit deciding whether it may embed at all); name (The family name the print shop's font list will show). A font is a database with drawings in one of its tables. Two command lines read all of this: ttx lists the tables and prints the name and OS/2 entries, and pdffonts tells you which of them made it into a PDF you have already exported.\n\n## Cubic versus quadratic, and why it matters once\n\nConvert a TrueType glyph to outlines and you get quadratic curves expressed as cubics: more nodes than the designer drew, with handles at positions nobody chose. Convert a CFF glyph and the nodes come across as they were drawn.\n\nFor body text this is invisible. For a wordmark you are about to edit by hand, it is the difference between eight nodes on an **o** and fourteen. If you have the choice, take the OTF.\n\n## Hinting, and why outlining changes the shape slightly\n\nA TrueType font carries **hints**: small programs that nudge outlines onto the pixel grid at small sizes so stems stay the same width and baselines stay flat. Hinting is why body text is legible at 11 px on a screen.\n\nHints are a *rendering* instruction. Convert text to outlines and they are discarded, because there is no longer any text to hint. On paper this does not matter; a press has no pixel grid. On screen it does, which is why an outlined SVG logo can look subtly muddier at 16 px than live text would.\n\n## Formats you will meet\n\n- **TTF**: TrueType. Quadratic. Universal.\n- **OTF**: OpenType, usually with CFF cubic outlines. Preferred for print.\n- **TTC**: a collection, several fonts in one file. Some applications import only the first.\n- **WOFF / WOFF2**: compressed wrappers for the web. Not installable on most systems as-is; convert with `fonttools` if you own the licence to do so.\n- **Type 1 (.pfb)**: the old PostScript format. **Adobe ended support in January 2023**, and current Illustrator and InDesign no longer render them. If you inherit a 2005 archive, this is why the text is missing.\n- **Variable fonts**: one file with continuous axes, covered later in this module.\n\n## Read a font from the command line, free\n\n`fonttools` is a Python package and the fastest way to answer questions the font menu will not.\n\n```bash\npip install fonttools\nttx -l Poppins-SemiBold.ttf          # list the tables\nttx -t name -o - Poppins-SemiBold.ttf | head -40   # family, style, licence URL\nttx -t OS/2 -o - Poppins-SemiBold.ttf | grep fsType\n```\n\n`fsType` is the embedding permission bit, and it is worth understanding because your PDF export obeys it:\n\n- `0`: installable, no restriction\n- `2`: restricted: embedding not permitted\n- `4`: preview and print embedding allowed\n- `8`: editable embedding allowed\n\nA font with `fsType 2` will refuse to embed and your export dialog will complain. Nearly everything commercial and everything under the SIL Open Font Licence is `0` or `4`.\n\nAnd to see what is inside a PDF you have already made:\n\n```bash\npdffonts job.pdf\n```\n\nEvery font, whether it is embedded, and whether it is subset. A line with an empty \"emb\" column is the failure this whole area exists to prevent.\n\n## The practical consequence\n\nWhen a shop says \"we do not have that font\", the honest answers are: send a PDF with it embedded, send outlines, or send them the font file, and the third is a licensing act, not a technical one. Which of those you may do is the next lesson.\n\nOne more thing worth knowing about embedding: what goes into a PDF is normally a **subset**, containing only the glyphs you actually used, renamed with a six-letter prefix like `ABCDEF+Mukta-Regular`. That prefix in a `pdffonts` listing is how you tell a subset from a full embed at a glance. Subsetting keeps files small and is why a 40-page document in a 400-glyph face adds a few tens of kilobytes rather than a megabyte. It also means nobody can extract a usable font from your PDF, which is part of why foundries permit it."},"check":{"question":"A designer converts a headline set in a TrueType font to outlines and notices the letterforms look very slightly different at small sizes on screen, though the printed result is fine. What changed?","options":[{"text":"The quadratic curves were converted to cubic, which introduces a small approximation error in every segment.","correct":false,"tempting":"Quadratic curves convert to cubic exactly: every quadratic has an exact cubic equivalent. The node count rises but the shape does not move."},{"text":"Hinting instructions were discarded, so the outlines are no longer snapped to the screen's pixel grid.","correct":true},{"text":"The `cmap` table was dropped, so the renderer fell back to a substituted glyph for some characters.","correct":false,"tempting":"Losing the character map would produce missing or wrong glyphs, not subtly different rendering of the correct ones."},{"text":"Outlining applies the font's default tracking as real spacing, which shifts each glyph by a fraction of an em unit.","correct":false,"tempting":"Outlining preserves the positions the text engine already computed; it does not apply any additional spacing."}]},"prev":{"slug":"outline-the-fonts","title":"Why the printer asked you to outline the fonts","url":"https://addaly.com/learn/vector-and-print/outline-the-fonts"},"next":{"slug":"licensing-a-typeface","title":"The licence, which is the part that bites","url":"https://addaly.com/learn/vector-and-print/licensing-a-typeface"},"authorship":"Founder and series editor: Dr Mustafa Mun. Written by AI models to a written standard. Exam keys checked blind by a second model: 3,665 of 3,666 agreed. Academic review invited.","review":{"status":"Draft, open for academic review"},"cite":"Addaly (2026) 'What is actually inside a font file', in Vectors, Logos and Things That Get Printed. Edited by M. Mun. Addaly. Available at: https://addaly.com/learn/vector-and-print/what-is-inside-a-font-file (Accessed: 13 October 2026).","licence":{"name":"CC BY-NC-SA 4.0","url":"https://creativecommons.org/licenses/by-nc-sa/4.0/"},"reader":{"schema":1,"title":"What is actually inside a font file","courseTitle":"Vectors, Logos and Things That Get Printed","module":{"index":3,"slug":"type-as-shape","title":"Type, which is also vector"},"answer":null,"keyIdea":"A font is a set of tables (outlines, a character map, widths, kerning, substitutions and a permission bit) and `pdffonts` plus `fonttools` will tell you in seconds what a font menu never will.","hero":{"kind":"figure","figure":{"t":"figure","label":"Figure","figure":{"type":"stack","title":"The tables inside a font file","layers":[{"label":"glyf or CFF","detail":"The outlines. TrueType quadratic, CFF cubic"},{"label":"cmap","detail":"Character code to glyph. Without it nobody can type it"},{"label":"hmtx","detail":"Advance widths: how far the pen moves each time"},{"label":"kern or GPOS","detail":"Adjustment between one specific pair and the next"},{"label":"GSUB","detail":"Ligatures, small caps, and every conjunct"},{"label":"OS/2","detail":"fsType, the bit deciding whether it may embed at all"},{"label":"name","detail":"The family name the print shop’s font list will show"}],"caption":"A font is a database with drawings in one of its tables. Two command lines read all of this: ttx lists the tables and prints the name and OS/2 entries, and pdffonts tells you which of them made it into a PDF you have already exported."},"alt":"Figure: The tables inside a font file. Layers, top to bottom: glyf or CFF (The outlines. TrueType quadratic, CFF cubic); cmap (Character code to glyph. Without it nobody can type it); hmtx (Advance widths: how far the pen moves each time); kern or GPOS (Adjustment between one specific pair and the next); GSUB (Ligatures, small caps, and every conjunct); OS/2 (fsType, the bit deciding whether it may embed at all); name (The family name the print shop’s font list will show). A font is a database with drawings in one of its tables. Two command lines read all of this: ttx lists the tables and prints the name and OS/2 entries, and pdffonts tells you which of them made it into a PDF you have already exported."}},"blocks":[{"t":"h2","id":"a-font-is-a-database-with-drawings-in-it","runs":[{"text":"A font is a database with drawings in it"}]},{"t":"p","runs":[{"text":"A "},{"text":".ttf","code":true},{"text":" or "},{"text":".otf","code":true},{"text":" file is a container of tables. Five of them decide everything you experience."}]},{"t":"ul","items":[[{"text":"glyf","b":true,"code":true},{"text":" or ","b":true},{"text":"CFF ","b":true,"code":true},{"text":": the outlines. TrueType ("},{"text":"glyf","code":true},{"text":") stores "},{"text":"quadratic","b":true},{"text":" Béziers: one handle per segment. PostScript/OpenType-CFF stores "},{"text":"cubic","b":true},{"text":" Béziers: two handles, the same curves your drawing program uses."}],[{"text":"cmap","b":true,"code":true},{"text":": the map from character codes to glyphs. "},{"text":"U+0041","code":true},{"text":" → glyph 36. Without this, the font has shapes but nobody can type them."}],[{"text":"hmtx","b":true,"code":true},{"text":": advance widths. How far the pen moves after each glyph."}],[{"text":"kern","b":true,"code":true},{"text":" or ","b":true},{"text":"GPOS","b":true,"code":true},{"text":": the adjustments between specific pairs."}],[{"text":"GSUB","b":true,"code":true},{"text":": substitutions: ligatures, small caps, alternates, and all the conjunct machinery that complex scripts depend on."}]]},{"t":"p","runs":[{"text":"Plus "},{"text":"OS/2","code":true},{"text":", which carries the licensing flags, and "},{"text":"name","code":true},{"text":", which carries the family and style names the print shop will see in a font list."}]},{"t":"h2","id":"cubic-versus-quadratic-and-why-it-matters-once","runs":[{"text":"Cubic versus quadratic, and why it matters once"}]},{"t":"p","runs":[{"text":"Convert a TrueType glyph to outlines and you get quadratic curves expressed as cubics: more nodes than the designer drew, with handles at positions nobody chose. Convert a CFF glyph and the nodes come across as they were drawn."}]},{"t":"p","runs":[{"text":"For body text this is invisible. For a wordmark you are about to edit by hand, it is the difference between eight nodes on an "},{"text":"o","b":true},{"text":" and fourteen. If you have the choice, take the OTF."}]},{"t":"h2","id":"hinting-and-why-outlining-changes-the-shape-slightly","runs":[{"text":"Hinting, and why outlining changes the shape slightly"}]},{"t":"p","runs":[{"text":"A TrueType font carries "},{"text":"hints","b":true},{"text":": small programs that nudge outlines onto the pixel grid at small sizes so stems stay the same width and baselines stay flat. Hinting is why body text is legible at 11 px on a screen."}]},{"t":"p","runs":[{"text":"Hints are a "},{"text":"rendering","i":true},{"text":" instruction. Convert text to outlines and they are discarded, because there is no longer any text to hint. On paper this does not matter; a press has no pixel grid. On screen it does, which is why an outlined SVG logo can look subtly muddier at 16 px than live text would."}]},{"t":"h2","id":"formats-you-will-meet","runs":[{"text":"Formats you will meet"}]},{"t":"ul","items":[[{"text":"TTF","b":true},{"text":": TrueType. Quadratic. Universal."}],[{"text":"OTF","b":true},{"text":": OpenType, usually with CFF cubic outlines. Preferred for print."}],[{"text":"TTC","b":true},{"text":": a collection, several fonts in one file. Some applications import only the first."}],[{"text":"WOFF / WOFF2","b":true},{"text":": compressed wrappers for the web. Not installable on most systems as-is; convert with "},{"text":"fonttools","code":true},{"text":" if you own the licence to do so."}],[{"text":"Type 1 (.pfb)","b":true},{"text":": the old PostScript format. "},{"text":"Adobe ended support in January 2023","b":true},{"text":", and current Illustrator and InDesign no longer render them. If you inherit a 2005 archive, this is why the text is missing."}],[{"text":"Variable fonts","b":true},{"text":": one file with continuous axes, covered later in this module."}]]},{"t":"h2","id":"read-a-font-from-the-command-line-free","runs":[{"text":"Read a font from the command line, free"}]},{"t":"p","runs":[{"text":"fonttools","code":true},{"text":" is a Python package and the fastest way to answer questions the font menu will not."}]},{"t":"code","lang":"bash","label":"Bash","text":"pip install fonttools\nttx -l Poppins-SemiBold.ttf          # list the tables\nttx -t name -o - Poppins-SemiBold.ttf | head -40   # family, style, licence URL\nttx -t OS/2 -o - Poppins-SemiBold.ttf | grep fsType"},{"t":"p","runs":[{"text":"fsType","code":true},{"text":" is the embedding permission bit, and it is worth understanding because your PDF export obeys it:"}]},{"t":"ul","items":[[{"text":"0","code":true},{"text":": installable, no restriction"}],[{"text":"2","code":true},{"text":": restricted: embedding not permitted"}],[{"text":"4","code":true},{"text":": preview and print embedding allowed"}],[{"text":"8","code":true},{"text":": editable embedding allowed"}]]},{"t":"p","runs":[{"text":"A font with "},{"text":"fsType 2","code":true},{"text":" will refuse to embed and your export dialog will complain. Nearly everything commercial and everything under the SIL Open Font Licence is "},{"text":"0","code":true},{"text":" or "},{"text":"4","code":true},{"text":"."}]},{"t":"p","runs":[{"text":"And to see what is inside a PDF you have already made:"}]},{"t":"code","lang":"bash","label":"Bash","text":"pdffonts job.pdf"},{"t":"p","runs":[{"text":"Every font, whether it is embedded, and whether it is subset. A line with an empty “emb” column is the failure this whole area exists to prevent."}]},{"t":"h2","id":"the-practical-consequence","runs":[{"text":"The practical consequence"}]},{"t":"p","runs":[{"text":"When a shop says “we do not have that font”, the honest answers are: send a PDF with it embedded, send outlines, or send them the font file, and the third is a licensing act, not a technical one. Which of those you may do is the next lesson."}]},{"t":"p","runs":[{"text":"One more thing worth knowing about embedding: what goes into a PDF is normally a "},{"text":"subset","b":true},{"text":", containing only the glyphs you actually used, renamed with a six-letter prefix like "},{"text":"ABCDEF+Mukta-Regular","code":true},{"text":". That prefix in a "},{"text":"pdffonts","code":true},{"text":" listing is how you tell a subset from a full embed at a glance. Subsetting keeps files small and is why a 40-page document in a 400-glyph face adds a few tens of kilobytes rather than a megabyte. It also means nobody can extract a usable font from your PDF, which is part of why foundries permit it."}]}],"check":{"question":[{"text":"A designer converts a headline set in a TrueType font to outlines and notices the letterforms look very slightly different at small sizes on screen, though the printed result is fine. What changed?"}],"options":[{"text":[{"text":"The quadratic curves were converted to cubic, which introduces a small approximation error in every segment."}],"correct":false,"tempting":[{"text":"Quadratic curves convert to cubic exactly: every quadratic has an exact cubic equivalent. The node count rises but the shape does not move."}]},{"text":[{"text":"Hinting instructions were discarded, so the outlines are no longer snapped to the screen’s pixel grid."}],"correct":true,"tempting":null},{"text":[{"text":"The "},{"text":"cmap","code":true},{"text":" table was dropped, so the renderer fell back to a substituted glyph for some characters."}],"correct":false,"tempting":[{"text":"Losing the character map would produce missing or wrong glyphs, not subtly different rendering of the correct ones."}]},{"text":[{"text":"Outlining applies the font’s default tracking as real spacing, which shifts each glyph by a fraction of an em unit."}],"correct":false,"tempting":[{"text":"Outlining preserves the positions the text engine already computed; it does not apply any additional spacing."}]}],"order":[3,0,1,2],"why":null},"prev":{"slug":"outline-the-fonts","title":"Why the printer asked you to outline the fonts","minutes":9},"next":{"slug":"licensing-a-typeface","title":"The licence, which is the part that bites","minutes":9}}}