Type: the missing-font question takes its answer through tool.setOption

- `tool.setOption {key: "missingFontEdit", value: {token, ok}}` now passes
  the Type tool's option check, so a client can answer the question that
  a click on type in a missing font asks. Before, it failed as an unknown
  option.
- A press on such type that reaches the Type tool while another dialog is
  open (sent with `pointer_gesture`) leaves that dialog open and starts no
  edit, instead of replacing it.
- docs/mcp.md says which double-clicks ask, and that OK starts no edit
  when the document changed after the question opened.
- The doc comment of `GENERIC_FAMILIES` notes that `emoji` is kept
  although CSS Fonts Module Level 4 dropped it.
This commit is contained in:
dotCooCoo
2026-11-18 15:41:34 -08:00
parent 96a34ff3f9
commit d94d3ef097
7 changed files with 94 additions and 7 deletions
+7 -3
View File
@@ -12416,9 +12416,13 @@ folder and no folder search.
A Type tool click, or a Selection or Direct Selection double-click, that would start editing type whose story (every
frame threaded with it) is drawn in a font that isn't available as named, as `text.missingFonts` reads them, opens a
`missingFontEdit` question instead (fields `message`, `detail`, `__token`) and does not start editing. `ui.dialog.confirm`
starts the edit with the caret where the type was clicked; `ui.dialog.cancel` leaves the document, its undo history and
the selection as they were. Answering does not change the fonts the type names, install a font or open Find Font. The
`missingFontEdit` question instead (fields `message`, `detail`, `__token`) and does not start editing. The double-click
is one on the canvas or `ui.click` with `count: 2`. A `pointer_gesture` `doubleclick` event only switches to the Type
tool; send the Type tool's `down` and `up` after it to start the edit. `ui.dialog.confirm` starts the edit with the
caret where the type was clicked; `ui.dialog.cancel` leaves the document, its undo history and the selection as they
were. When the document changed after the question opened, or the type is gone, `ui.dialog.confirm` closes the question
and starts no edit; click the type again before sending text. A `pointer_gesture` press on such type while another
dialog is open leaves that dialog open and starts no edit. Answering does not change the fonts the type names, install a font or open Find Font. The
question comes again for each new edit, and not for a click within the type being edited or in another frame of its
story. The Type tool's `missingFontEdit {token, ok}` option is how the question gives its answer. Commands that change
text (`text.editRange`, `text.setRangeStyle` and the others) do not ask. This follows the help page