rasterVisualHeightScaleForFontFamily function
Scale that makes the letters of the font file look as large as the reference font's at the same font size. 1.0 when unknown.
Implementation
double rasterVisualHeightScaleForFontFamily(String? fontFamily) {
final visualHeightEm = rasterVisualHeightEmForFontFamily(fontFamily);
if (visualHeightEm == null || visualHeightEm <= 0) return 1.0;
return kReferenceRasterVisualHeightEm / visualHeightEm;
}