Skip to content

Interface: FontMetricsOracleOptions ​

Experimental

Properties ​

PropertyTypeDescription
cacheSize?numberExperimental Maximum cached width entries (LRU). Default 20 000.
measurer?TextMeasurerExperimental Measuring backend. Default: canvas when available, else the deterministic fallback.
resolveFace?((face) => TextFace) | nullExperimental Maps a requested face to the face the measurer measures with. Default: for the canvas measurer, the face troika will actually draw (measurementFace: the registered family, the app's default font, or the built-in default font); identity for other measurers, so the deterministic fallback (node, tests) is unchanged. null forces identity.

Released under the MIT License.