mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-12-05 13:32:45 -05:00
Type Tools: Create Font Sheet's artboard guard covers script slices
A script run that the frames take to its end ran each slice with no artboard deletion guard, so a vc.run of artboard.delete in a later slice could delete the artboard an open Create Font Sheet dialog uses. The script poll now sets the guard around each pump and restores the previous one after it. The new test runs such a script in the frames and checks that the deletion is refused and the document is unchanged.
This commit is contained in:
1 parent
e58c1f2a07
commit
ceae368934
4 files changed
+36
-2
No files matched your search
+2
-1
@@ -18072,7 +18072,8 @@ the fonts can be compared on the artboard or printed.
|
||||
In `addon.type.fontSheet`, a parameter given as `null` is the same as one left out and takes its default; any other
|
||||
value of the wrong type or out of range is an error. While the Create Font Sheet… dialog is open, Delete Artboard, Cut
|
||||
Artboard, Delete Empty Artboards and Artwork Cleanup's Empty Artboards return an error and change nothing when they
|
||||
would delete the artboard the dialog opened on; close the dialog first.
|
||||
would delete the artboard the dialog opened on, and so does a running script's `vc.run` of one of them (a script
|
||||
that does not catch the error ends with it); close the dialog first.
|
||||
|
||||
→ `{id, count, skipped: [family, or family and style…], artboards: [index…] (the artboards added), warning?}`. Create Font Sheet… opens a dialog
|
||||
(`ui.menuDialog {command}`) whose fields are the command's parameters except `families`, with Preview, which starts
|
||||
|
||||
@@ -3176,7 +3176,7 @@ A VectorCraft addition, not a feature of the reference app (it has no command fo
|
||||
|
||||
## Type Tools add-on: Create Font Sheet (2026-11-29)
|
||||
|
||||
A VectorCraft addition, so no area score moves. Object › Plug-ins › Type Tools › Create Font Sheet… sets a line of sample text once in each font family the font menus list, or in the families whose name contains a filter, each entry labeled with its font's name unless labels are switched off, as point type flowed down columns on the active artboard and on new artboards of the same size to its right when the artboard is full. Every Style gives each style of a family its own entry; families whose font can't be loaded, and composite fonts whose part setting the sample can't, are left out and listed. Each row is as tall as the tallest laid-out entry, so a composite font that enlarges the sample does not overlap. The sheet is one selected group made in one undo step, from a dialog whose Preview starts off (`addon.type.fontSheet`); its preview and OK set the sheet on the artboard active in the view when it opens, and while it is open, Delete Artboard, Cut Artboard, Delete Empty Artboards and Artwork Cleanup's Empty Artboards return an error when they would delete that artboard. Tests: `cmd::addons::typetools::font_sheet::tests` in `vectorcraft-engine` (labels, columns and margins, new artboards and none, the filter, every style, fonts and styles that don't load, composite fonts' row heights and missing parts, undo, a locked layer, bad params refused), `addons::typetools::font_sheet::tests` (including the artboard active when the dialog opens) and the Create Font Sheet row of `add_on_dialogs_preview_cancel_and_run_their_command` in `vectorcraft-ui-egui`. Commands: `docs/mcp.md` › Type Tools add-on › Create Font Sheet.
|
||||
A VectorCraft addition, so no area score moves. Object › Plug-ins › Type Tools › Create Font Sheet… sets a line of sample text once in each font family the font menus list, or in the families whose name contains a filter, each entry labeled with its font's name unless labels are switched off, as point type flowed down columns on the active artboard and on new artboards of the same size to its right when the artboard is full. Every Style gives each style of a family its own entry; families whose font can't be loaded, and composite fonts whose part setting the sample can't, are left out and listed. Each row is as tall as the tallest laid-out entry, so a composite font that enlarges the sample does not overlap. The sheet is one selected group made in one undo step, from a dialog whose Preview starts off (`addon.type.fontSheet`); its preview and OK set the sheet on the artboard active in the view when it opens, and while it is open, Delete Artboard, Cut Artboard, Delete Empty Artboards and Artwork Cleanup's Empty Artboards return an error when they would delete that artboard, also when a running script calls them through `vc.run`. Tests: `cmd::addons::typetools::font_sheet::tests` in `vectorcraft-engine` (labels, columns and margins, new artboards and none, the filter, every style, fonts and styles that don't load, composite fonts' row heights and missing parts, undo, a locked layer, bad params refused), `addons::typetools::font_sheet::tests` (including the artboard active when the dialog opens) and the Create Font Sheet row of `add_on_dialogs_preview_cancel_and_run_their_command` in `vectorcraft-ui-egui`. Commands: `docs/mcp.md` › Type Tools add-on › Create Font Sheet.
|
||||
|
||||
## Unit Converter add-on (2026-11-14)
|
||||
|
||||
|
||||
Reference in new issue
Block a user