mirror of
https://github.com/storytold/figcraft.git
synced 2026-10-24 10:27:00 -06:00
Merge pull request #821 from attisvalentin/fix/rescan-and-load-fonts
M4: fonts installed while the app runs: text.rescanFonts, text.loadFont, text.refit
This commit is contained in:
+6
-1
@@ -234,7 +234,12 @@ Or in a project's `.mcp.json`:
|
||||
`text.setVariations {variations, replace?}` merges instead. `text.fonts {family, style?, axes: true}`
|
||||
lists a font's axes and named instances (named instances are also valid `fontStyle` values).
|
||||
`text.missingFonts` lists the families the document names that aren't installed
|
||||
(`{families: [{family, layers}]}`); their text draws in a fallback font.
|
||||
(`{families: [{family, layers}]}`); their text draws in a fallback font. Fonts are indexed once
|
||||
per process: after installing one, `text.rescanFonts` picks it up (`{added: [families]}`), and
|
||||
`text.loadFont {path | data (base64)}` adds a font file without installing it (`{families}`).
|
||||
Text boxes keep the size they were measured at: both refit the open document's auto-sizing text
|
||||
in the new families (`refitted: [ids]`), and `text.refit {ids?}` does it for any text, e.g. a
|
||||
file saved while its fonts were missing.
|
||||
OpenType features: `features {"liga": false, "tnum": true}`.
|
||||
Decorations: `textDecorationStyle` (`solid`, `dotted`, `wavy`), `textDecorationThickness` and
|
||||
`textDecorationOffset` (`auto`, px, or `"10%"` of the font size; the offset runs from the baseline
|
||||
|
||||
Reference in New Issue
Block a user