type RVG · Core

MeasureTextFunction

type MeasureTextFunction = (text: string, font: string) => { ascent: number; descent: number; width: number }

Measures a text in a font (a CSS font shorthand): its advance width and the font box above and below the alphabetic baseline. The type of VisQuillOptions.measureText.