UNPKG

autokerning

Version:

autokerning computes suggested kerning values for glyph pairs from TrueType/OpenType fonts by rendering glyph bitmaps, applying a small Gaussian blur, and measuring pixel overlap across horizontal offsets. It can be used programmatically (as an imported E

10 lines 557 B
import { Glyph } from "./glyph.js"; /** Estimate kerning between two glyphs based on overlap * @param left - Left glyph * @param right - Right glyph * @param minOverlap - Minimum overlap threshold (for calibrated mode) * @param maxOverlap - Maximum overlap threshold (for calibrated mode) * @param kernelWidth - Optional: kernel width for adaptive blur (used in calibrated mode) */ export declare function kernPair(left: Glyph, right: Glyph, minOverlap: number, maxOverlap: number, kernelWidth?: number): number; //# sourceMappingURL=kernPair.d.ts.map