TX Sheet Control

FontManager Class

Class

Loads document fonts and exposes font choices, layout metrics and deterministic document rendering assets.

Package: @txtextcontrol/tx-sheet-control. Version: 2.0.0.

ES module import: import { FontManager } from '@txtextcontrol/tx-sheet-control';.

Constructor

new FontManager(options?: FontManagerOptions): FontManagerInstance
ParameterTypeOptionalDescription
optionsFontManagerOptions | undefinedYesSupported settings for this operation; omitted settings retain documented defaults.

Returns: FontManagerInstance.

Members

Properties

PropertyDescription
readyResolves after runtime catalog discovery. Rejects on missing or malformed catalogs.

Methods

MethodDescription
choicesThe choices operation of FontManager.
ensureStyleThe ensureStyle operation of FontManager.
ensureWorkbookThe ensureWorkbook operation of FontManager.
onChangeThe onChange operation of FontManager.
stateThe state operation of FontManager.

Examples

Pass the FontManager value obtained from its owning control, collection, callback or operation. The function reads that value without constructing a replacement document object.

import type { FontManager } from '@txtextcontrol/tx-sheet-control';

async function inspectFontManagerReady(fontManager: FontManager) {
    const value = await fontManager['ready'];
    console.log('FontManager.ready', value);
}

See Also