import { ParsedTtf } from './ttf-parser.js'; /** * Subset a TrueType font to the glyphs in `usedGids` (plus their composite * components and GID 0). All tables are kept intact so the CIDFontType2 * `/CIDToGIDMap /Identity` contract holds; only `glyf`/`loca` are rebuilt, with * unused glyphs zero-length. * * @param parsed The parsed source font (must have `glyf` + `loca`). * @param usedGids The glyph ids actually used. * @returns The subset font bytes. * @throws Error when the font has no `glyf`/`loca` (e.g. a CFF/OTF font). */ export declare function subsetTtf(parsed: ParsedTtf, usedGids: Iterable): Uint8Array; /** * The glyph ids actually present in a subset for `usedGids`: the seeds, their * composite components (transitively) and GID 0. With Identity CID↔GID this is * exactly the CID set of the embedded subset, used to build the PDF/A `/CIDSet` * (ISO 19005-1 §6.3.5). Mirrors {@link subsetTtf}'s own closure. * * @param parsed The parsed font. * @param usedGids The seed glyph ids. * @returns The closed set of glyph ids. */ export declare function glyphClosure(parsed: ParsedTtf, usedGids: Iterable): Set;