Interface: TextConfig
Experimental
Global text-rendering configuration (wraps troika's configureTextBuilder).
Properties
| Property | Type | Description |
|---|---|---|
defaultFontFaces? | FontFamilyFaces | Experimental Self-hosted files for the built-in default font's faces, e.g. the OTF files shipped in @mk7s/holochart-render/fonts/ (with their license) served by the app: unregistered families then draw from these URLs instead of the bundled data: chunks (ESM) or the files next to the IIFE script, keeping bold and italic. Useful under a Content Security Policy without data: or blob: sources, or to serve the fonts from a CDN. Ignored while defaultFontURL is set. |
defaultFontURL? | string | Experimental One font file (TTF/OTF/WOFF, not WOFF2) for every family that is not registered, at every weight and style (troika never synthesizes bold or italic). Unset → the built-in default font, TeX Gyre Heros, shipped with Holochart in four faces and loaded lazily. Also registered as a CSS font face so layout measures unregistered families with this font (see measurementFace). |
sdfGlyphSize? | number | Experimental SDF glyph resolution, a power of two (default 64). |
unicodeFontsURL? | string | Experimental Location of troika's unicode fallback-font data (default: CDN), used only for characters the drawn font lacks (e.g. Cyrillic or CJK with the built-in default font). |
useWorker? | boolean | Experimental Typeset in a web worker (default true). Disable under CSPs that forbid blob workers. |