resolveFontFace Type
Public type for resolveFontFace.
Package: @txtextcontrol/tx-sheet-control-server. Version: 2.0.0.
Related workbook object-model type, returned through the server control. Obtain it from its owning workbook or collection; it is not a required browser-package import.
Syntax
resolveFontFace<Family extends { family: string; faces: readonly FontFaceSource[]; }>(families: readonly Family[], style: { fontFamily?: string; bold?: boolean; italic?: boolean; }, shouldFallback?: boolean): { family: Family; face: Family["faces"][number]; } | null
Parameters
| Parameter | Type | Optional | Description |
|---|---|---|---|
families | readonly Family[] | No | Runtime descriptors, including at least one available face per family. |
style | { fontFamily?: string; bold?: boolean; italic?: boolean; } | No | Workbook font metadata; an omitted family uses the default document family. |
shouldFallback | boolean | undefined | Yes | Allows temporary display substitution. PDF preflight passes false. |
Return Value
{ family: Family; face: Family["faces"][number]; } | null.
Examples
Pass the resolveFontFace value obtained from its owning control, collection, callback or operation. The function reads that value without constructing a replacement document object.
function inspectresolveFontFace(resolveFontFace: { value: unknown }) {
const value = resolveFontFace;
console.log('resolveFontFace.value', value);
}