mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-10-29 20:27:05 -06:00
Print: Print and Print Preview warn about type that doesn't fit its frame
Area type and type on a path whose text doesn't fit print without the text past the end of the frame. text.create, text.createInPath, text.setText and text.setStyle report it in their replies, but file.print and print.preview gave no warning, and the Print dialog's Summary showed none. Both commands now add a warning that counts the area type and type on a path that prints and doesn't fit, and gives their ids (the first 20, then how many more). It counts the objects that the fallback font warning counts: visible objects on the layers that Print Layers picks, on the paper of the artboards or tiles that print. The walk that finds the fonts of the printed type also collects these ids. Type in the art of symbols, patterns, brushes, opacity masks and placed documents is not named. Docs: docs/mcp.md (Print, Fitting area type), docs/target-app-parity.md (Type).
This commit is contained in:
+5
-2
@@ -2682,7 +2682,9 @@ as they do for art larger than the imageable area. Type in a font family that is
|
||||
font, and the warnings of `file.print` and `print.preview` name those families. They count only type that prints:
|
||||
visible type that fits its frame or path, on the layers `printLayers` picks, on the paper of the artboards or tiles
|
||||
that print, and the type in the symbols, patterns, scatter brushes, opacity masks and placed documents of the art that
|
||||
prints.
|
||||
prints. The warnings also give the ids of the area type and type on a path that print and whose text doesn't fit
|
||||
(objects of the document only, not type in the art of symbols, patterns, brushes, opacity masks or placed documents;
|
||||
see [Fitting area type](#fitting-area-type-auto-size-shrink-text-to-fit-overflow)).
|
||||
|
||||
```json
|
||||
{"name":"run_command","arguments":{"command":"print.setup","params":{"settings":{"media":"a4","scaling":"fit","marks":{"trim":true}}}}}
|
||||
@@ -3124,7 +3126,8 @@ Text that doesn't fit is drawn up to the last line that does, so a one-line head
|
||||
draws nothing. The commands that make type or change what it holds say so in their own reply: `text.create`,
|
||||
`text.createInPath`, `text.setText` and `text.setStyle` add `overflow: [id…]` (the area type and type on a path among
|
||||
the objects they made or changed whose text doesn't fit), and the `add_text` tool adds `overflow: true`. The key is
|
||||
left out when everything fits.
|
||||
left out when everything fits. The warnings of `file.print` and `print.preview` give the ids of the objects that print
|
||||
and whose text doesn't fit: the first 20 ids, then how many more.
|
||||
|
||||
```json
|
||||
{"name":"run_command","arguments":{"command":"text.areaOptions","params":{"fit":"shrinkText","fitMinPercent":60}}}
|
||||
|
||||
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user