Commit Graph
1512 Commits
Author SHA1 Message Date
ncicandClaude Opus 5.5 21e9c8ff31 Pencil: Live preview option, a thin line while drawing when it is off
A Pencil stroke always previewed as the path it draws, with its full
appearance: with a fill set, the fill flipped between the shape and its
inside-out as the stroke crossed itself or curved back, and hid the line
being drawn.

Pencil Tool Options get a Live preview checkbox, above Live curve
fitting, on by default and kept with the tool's other options
(`livePreview`, settings.rs). With it off, the stroke previews nothing
while it is drawn: a thin line follows the pen (the drag overlay the
Knife and Blob Brush already show), and the release, or a switch of
tool mid-stroke, draws the path with its fill and stroke, as one undo
step, as before. Escape still cancels the stroke. With it on nothing
changes. The Paintbrush has no such option and keeps previewing.

Public reference: Draw and edit paths using the Pencil tool,
https://helpx.adobe.com/illustrator/using/tool-techniques/pencil-tool.html
(lists Live preview and Live curve fitting among the Pencil's options).

The checkbox label is translated in all 24 catalogs.

Tests: pencil_with_live_preview_off_shows_a_thin_line_until_the_release
(tools), pencil_with_live_preview_off_draws_the_filled_path_on_release
(engine), and the freehand dialog test shows the checkbox for the Pencil
only.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-26 12:52:32 +07:00
ncicandClaude Opus 5.5 20476760bc Pencil: Edit Selected Paths redraws a selected compound path's member paths
A selected compound path (a shape with a hole, such as one made with
Object › Compound Path › Make) could not be redrawn with the Pencil or
the Paintbrush: at the press, find_redraw looked only for selected
objects that are paths themselves, and a compound path's paths are its
children. The stroke then drew a new path, which Keep selected selected
in place of the compound path, so every later stroke near the shape drew
a new path too: redrawing seemed to stop working.

- find_redraw takes a selected compound path's member paths as well,
  the nearest one within Edit selected paths within of the press.
- path.freehand's redraw keeps the compound path selected (or, with Keep
  selected off, takes it out of the selection) when the redrawn path is
  one of its members, so the next stroke redraws it too.

Test: pencil_redraws_a_selected_compound_path redraws the outer path and
then the hole of a selected compound path; it fails without this change
(the first stroke draws a new path).

cargo xtask ci: every step passes except one test in `test`,
vectorcraft-pdf tests_import_fidelity::text_becomes_point_type, which
fails the same way on unmodified main on this machine; it is unrelated
to this change.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-26 11:49:03 +07:00
skylar taylor-barrick 581c79dcb1 M14: distinguish qualification from publication (#4173) 2026-10-25 23:47:58 -04:00
Taha-Mahmoodi 502b204d74 Transform panel: the menu's Transform Object Only, Pattern Only, Both and Use Registration Point for Symbol act
Squashed from #4146 onto main.
2026-10-26 10:04:25 +07:00
bflatastic a54251a18a Revert "Merge pull request #4200 from storytold/fix/sonar-s2208-engine-tests"
This reverts commit d7a2591dc0, reversing
changes made to e63c26ff15.
2026-10-26 09:56:24 +07:00
Dylan M. Taylor 2b72794251 lint(engine): explicit imports in engine modules and tests (S2208)
Replace glob `use super::*` with the names each module uses, so the
module's imports are visible at the top of the file (Sonar rust:S2208).
No code changes.
2026-10-26 09:52:47 +07:00
dotCooCoo df716c3118 Image Trace: Document Library traces with a color group from the Swatches panel
Squashed from #3975 onto main.
2026-10-26 09:25:42 +07:00
Angelo Bernardini ea36291f30 G12: General › Corner Radius is the Rounded Rectangle tool's radius (#394)
Squashed from #4074 onto main.
2026-10-26 09:09:47 +07:00
dotCooCoo ad75ea5d06 Type: Highlight Substituted Fonts moves to Preferences › Type and applies to every document
Highlight Substituted Fonts is now a preference in Preferences › Type,
next to Highlight Alternate Glyphs, on by default and saved with the
other preferences (`prefs.set highlightSubstitutedFonts`). The canvas
reads it through `RenderOptions::highlight_substituted_fonts` for every
open document; a document's own setup no longer decides it. File ›
Document Setup no longer shows the checkbox and keeps Highlight
Substituted Glyphs.

A file saved with Document Setup's Highlight Substituted Fonts off now
shows the pink highlight when it opens, while the preference is on.
The file still opens with the stored value, and saving it again keeps
that value.

`document.setup` no longer reports `highlightSubstitutedFonts`. It
ignores the key and adds a `warnings` entry that names `prefs.set` to
its reply, so an older reply passed back still applies its other keys.

The raster cache of type under a raster effect now also redraws when
Highlight Alternate Glyphs changes.
2026-10-26 09:09:47 +07:00
ncic 09b3b25004 Fix #3328: Pencil Fidelity down to 0.01 pt, with a logarithmic slider and key steps that fit the range
Squashed from #4196 onto main.
2026-10-26 09:09:47 +07:00
dotCooCoo 05e09039f5 Pencil: a stroke from an end of one selected path to an end of another connects them
Squashed from #4095 onto main.
2026-10-26 09:09:47 +07:00
dotCooCoo c9fa005a54 Pencil: the cursor shows a star before a press that draws a new path
Draw freeform paths with the Pencil tool says a small star appears on
the Pencil when it is ready to draw a freeform path, and Reshape paths
with the Pencil tool says the star disappears over a selected path the
drag reshapes. The Pencil cursor had no star.

- New Cursor::PencilNew: the Pencil's crosshair with a small star where
  the closing cursor has its ring. It becomes the crosshair with Use
  Precise Cursors and as a system cursor.
- The Pencil shows it before a press when neither find_extend nor
  find_redraw (the lookups the press uses, within Edit Selected Paths)
  finds a selected path under the pointer. Over such a path and while a
  stroke is drawn, the cursor has no star.

Docs: docs/target-app-parity.md.
2026-10-26 09:09:46 +07:00
dotCooCoo 3d8c40f500 Eraser: Angle and Roundness in Eraser Tool Options shape the tip
Squashed from #4180 onto main.
2026-10-26 09:09:46 +07:00
dotCooCoo 7117c82cab Brushes: Art Brush Options' Width can follow the pen pressure
Art Brush Options' Width had no pen tablet option, so an art brush
drew at one width whatever the pressure. The Width row now has a
Fixed or Pressure menu and a second width. With Pressure the art is
Width wide at the lightest pen pressure and the second width at the
heaviest, following the pressure the Paintbrush recorded along the
stroke, and half way between the two on a stroke drawn without
pressure. brush.options takes width_mode and width_max; a brush
without them is saved as before.
2026-10-26 09:09:46 +07:00
dotCooCoo 60cb4c45ab Pencil: Live curve fitting in Pencil Tool Options
Pencil Tool Options has a Live curve fitting checkbox, on by default.
With it off, the path shown while a Pencil stroke is drawn joins the
stroke's points with straight segments, and the release fits the curve
at the Fidelity, as it does with the option on. Choosing another tool
while a stroke is drawn also keeps the stroke fitted. The option is
saved with the tool's other options.

path.freehand takes fit (true by default): with fit false, a new path,
a continued path and a redrawn section join the points with straight
segments.
2026-10-26 09:09:46 +07:00
dotCooCoo 5339fec9cd Type: typing "1. ", "A) " or "* " at the start of a paragraph starts a list
The reference app detects lists typed as 1., 1), A. or A), and makes
custom bullets from *, #, > or + followed by a space. In VectorCraft
the characters stayed as text.

When the Type tool types a space on its own after one of these at the
start of a paragraph in no list, the typing so far becomes one undo
step. The new command text.startList then removes the typed characters
and the space and makes the paragraph a numbered list in 1, 2, 3 or
A, B, C, or a bulleted list with the filled dot. A paragraph with no
indents gets the 18 pt hanging indent. One Undo puts the characters
back as text with no list, and the caret goes on after them; Redo
removes them again. The same characters later in a paragraph, list
characters pasted in one piece with the space and a paragraph already
in a list start nothing.

Docs: docs/mcp.md, docs/target-app-parity.md.
2026-10-26 09:09:46 +07:00
dotCooCoo 056274f5d6 Undo: canceling an undo group keeps a batch's steps in other documents
A command.batch that edited a document with an undo group and then a
document without one was dropped from the journal as a whole when the
group was canceled, so a replay lost the second document's edit, which
the session kept. Each batch step is now noted in the undo groups it
belongs to, by the same rule as a top-level command, and a cancel takes
only those steps out of the batch's journal entry. A step that changed
the active document becomes that change. Undo groups that stay open
follow the entry and step numbers that a cancel changes.
2026-10-26 09:09:45 +07:00
dotCooCoo 6c9ac54b22 Shape Builder: a merge across an overlap thinner than the precision gives one path
Two shapes that overlap by less than the region precision (0.01 pt) leave
their overlap out of the Shape Builder's regions as a sliver. Merging the
regions on both sides of it united only the picked faces, so the result
was a compound path with a hairline gap where the overlap had been.

A merge now takes in each dropped sliver next to a merged face when only
the merged faces' shapes fill it, both from the arrangement and from the
planar map used when open paths are selected. A thin cutout that no shape
fills stays a hole. What is left of a shape after the merge takes in a
sliver only where the shape covers it and the merged shape does not take
it in, so the two do not overlap. Pathfinder operations and Live Paint do
not use the merger and are unchanged; Live Paint's planar map does not
test which shapes cover a sliver.
2026-10-26 09:09:45 +07:00
dotCooCoo b92f394c0b Shape Builder: erasing picks a region narrower than twice the tolerance
In erase mode the tool tests each point for a line piece or an edge
within the tolerance before the region under it. Every point of a region
narrower than twice the tolerance is that close to its edges, so an
Alt-click, the Alt hover and an Alt-drag over a thin overlap touched its
edges and not the overlap, and the overlap was left behind.

A point in a region now touches the region when the region is no more
than twice the tolerance across there, measured from the nearest point
of its outline through the point to the outline on the other side. This
covers a drag at any angle, a drag that starts or ends in the region,
and a thin shape inside another or on its own. Near an edge of a wider
region, the edge is touched as before.
2026-10-26 09:09:44 +07:00
dotCooCoo c527082ff1 Shape Builder: a click merges over the map the tool built for the hover
shapeBuilder.merge built the planar map of the selection again, on the
thread that runs the command, although the Shape Builder tool had just
built the same map for its hover. The tool now returns its map from a
new Tool::shape_builder_map, and the command uses that map when its
inputs are the merge's inputs and its gap is the merge's gap; otherwise
it builds its own as before. The tool's map has the outline edges, so
erasing and splitting a stroke use it too.
2026-10-26 09:09:44 +07:00
dotCooCoo 3567e5be7d Live Paint: a plain group named "Live Paint..." is not a Live Paint group
A group counted as a Live Paint group when its name started with "Live
Paint". A plain group named, for example, "Live Painting" was then read
as one. With it and another shape selected, the Shape Builder found no
regions in it, and a merge on the other shape deleted the group and its
paths. Make Live Paint took the group as a Live Paint group to merge
into, and its paths did not become sources.

A Live Paint group now also needs its sources group, the group named
"Live Paint Sources" that Make Live Paint puts in it. A plain group with
such a name is traversed like any other group.
2026-10-26 09:09:44 +07:00
acosimati 03ab7bb805 MCP: doc_inspect reports opacityPct in the percent scale the drawing tools take
draw_path, draw_shape and object.setProps take opacity in percent (0-100),
but the document.inspect / document.node summary behind doc_inspect,
inspect_document and vectorcraft://object/{id} reported the stored 0-1
fraction under the same name. An agent that read 0.55 and wrote it back
got a nearly invisible object.

The summary now adds opacityPct (0-100, rounded to 1/100 of a percent)
beside the unchanged opacity, and the tool, resource and command
descriptions say which scale each field uses. Round-trip test in the mcp
crate: draw at 55 %, read 55 back from doc_inspect, inspect_document and
the object resource, write it back unchanged.
2026-10-26 09:09:44 +07:00
Dylan M. Taylor 46ece73197 lint: method references and elided const lifetimes (S1612, S8863) (#4204)
Use function paths where a closure only forwarded its argument
(PoisonError::into_inner, OsStr::to_str, FindRange::is_empty), and drop
redundant 'static on associated and module consts. No behaviour change.
2026-10-25 22:08:44 -04:00
NetterSilverandClaude Haiku 5.5 b089b7e948 Join the selected end points of two paths with Ctrl+J
Fixes #4163

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-26 08:18:33 +07:00
NetterSilverandClaude Haiku 5.5 6259448c39 Reset stroke weight to zero when the stroke colour is removed
Fixes #4109

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-26 08:18:32 +07:00
Dylan M. Taylor 0eebd533c5 security(pathops): signed zeros, reported budget rejections, and a fill-only fallback
Boxes that touch at -0.0/+0.0 now count as overlapping, so the pair cap cannot be skipped. try_boolean_n, try_unite_all and try_area report a refused input, and the Pathfinder shape-mode unite and the Blob Brush use them to show an error. When the planar map is over its budget, the fallback leaves out paths that fill nothing so a flood of cutting lines cannot take the filled shapes down with it.
2026-10-25 16:04:29 -04:00
Dylan M. Taylor 6e7854967d Merge pull request #4113 from storytold/codex/egui-037-vectorcraft-20261023
Migrate VectorCraft input, text and capture to egui 0.37
2026-10-25 14:09:31 -04:00
Brandon Thomas e14b2b2c79 Merge pull request #4070 from marcoarnulfo/fix/direct-select-type-on-path
Direct Selection: an anchor of type on a path's path drags and the type reflows along it
2026-10-25 10:56:10 -04:00
Brandon Thomas c5c44e0dfb Merge main into fix/h2473-safe-file-name-leaves-a-windows
Combines this branch's screens.rs test module with the one #4123 added.
2026-10-25 10:38:39 -04:00
Brandon Thomas 70a05ba09b Merge pull request #4068 from dotCooCoo/fix/eps-no-art-central-file-text
EPS: the help text says no central file is written when no art shows
2026-10-25 10:38:12 -04:00
Brandon Thomas f0e5b5e902 Merge pull request #4069 from dotCooCoo/fix/set-paint-object-count
MCP: set_paint reports how many objects it painted
2026-10-25 10:38:01 -04:00
Brandon Thomas dda90f0f4f Merge pull request #4060 from dotCooCoo/feat/unknown-command-suggestion
Commands: an unknown command id is answered with the nearest command id
2026-10-25 10:37:54 -04:00
Brandon Thomas 774314a351 Merge pull request #4050 from dotCooCoo/fix/screens-filename-is-file-name
Export for Screens: <filename> takes the saved document's file name
2026-10-25 10:37:45 -04:00
Brandon Thomas c95d1c403c Merge pull request #4053 from marcoarnulfo/fix/icc-reload-direct-cache
Color management: loading the working RGB profile again under its name takes effect at once
2026-10-25 10:37:29 -04:00
Brandon Thomas 0d50e5f6ce Merge pull request #4059 from dotCooCoo/fix/new-symbol-threaded-text-keeps-its-text
Threaded text: New Symbol on a frame no longer duplicates its text
2026-10-25 10:37:26 -04:00
Brandon Thomas a43a99f531 Merge pull request #4056 from marcoarnulfo/fix/set-bounds-compound-member
Properties and Transform: X, Y, W and H of a compound path's member set only that path
2026-10-25 10:37:22 -04:00
Brandon Thomas 1d1d0192ba Merge pull request #4072 from dotCooCoo/fix/recovery-threaded-continuation-marks
Type: a recovered document keeps continued paragraphs in threaded frames
2026-10-25 10:37:19 -04:00
Brandon Thomas d57bcc3a39 Merge pull request #4047 from dotCooCoo/fix/rasterize-threaded-text-keeps-its-text
Threaded text: Rasterize on a frame no longer duplicates its text
2026-10-25 10:37:15 -04:00
NetterSilverandClaude Haiku 5.5 80363c7e60 Protect Windows device names followed by a space in safe_file_name
Found while testing crates/engine/src/cmd/fileio/screens.rs:168-177 (safe_file_name)

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-25 11:52:29 +01:00
NetterSilverandClaude Haiku 5.5 50b067c089 Refuse signs, exponents and non-numeric text in Export for Screens sizes
Found while testing crates/engine/src/cmd/fileio/screens.rs:49 (ScreenSize::parse)

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-25 11:16:58 +01:00
skylartaylor 340e3495d8 egui037: migrate VectorCraft UI and reconcile current main 2026-10-25 03:27:29 +01:00
dotCooCoo 4210c2447f EPS: the useArtboards help text separates false from absent
useArtboards: false writes one file of the visible art even when artboards are named. With useArtboards absent, naming artboards writes the same files as useArtboards: true, including the no-art exception for the central file. The option description and the document.exportEps params text now say so, and the EPS test covers both cases.
2026-10-24 14:00:32 -07:00
Marco Arnulfo ec97ee2c80 Direct Selection: an anchor of type on a path's path drags and the type reflows along it (part of #3980) 2026-10-24 22:06:20 +02:00
dotCooCoo c65b494575 MCP: set_paint reports how many objects it painted
With nothing selected and no ids, set_paint changes only the paint for
new art, but its reply was the same as when it painted objects, so a
caller could not tell that no object changed.

paint.setFill, paint.setStroke, paint.none, paint.lastColor,
paint.lastGradient and stroke.set now reply {objects}: how many objects
took the paint, as the commands resolve their targets (a selected group
counts the objects inside it). set_paint adds the largest of those
counts to its reply as `objects`, and when it is 0 a `note` says that
only the paint for new art changed. The tool description and the
set_paint row in docs/mcp.md describe the reply.
2026-10-24 12:27:08 -07:00
aiongg 8bf090b253 Shortcuts: use the shared craft-keymap crate for the catalogue, overrides, dispatch and .kys import (#3119)
* Shortcuts: the keymap, overrides and dispatch come from craft-keymap

The editor's catalogue (commands, UI commands, panels, tools; one tool
group per tool; show/hide commands marked as toggles) builds a
craft-keymap Keymap. UiState::shortcut_overrides is a craft_keymap
Overrides stored through keymap::stored, which writes the same map of
entry key -> one string as before, with panel: keys and VectorCraft's
spellings, so earlier versions read the file; a value that is not text
drops that entry instead of every preference.

Key presses run through craft_keymap's Dispatcher with accept filters:
keys that type text go to the one-key text path, and while the Type
tool edits only command-key chords run. Held keys repeat. Conflicts
and assignment use the crate's conflicts and set_bindings. Extra Shift
no longer falls back to the chord without it.

* Shortcuts: .kys import matches and applies through craft-keymap

The review proposes targets with craft_keymap's namematch, and Apply
hands the ready rows to craft_keymap::plan as one set, each row's
target passed as the remembered answer for its entry. The later row
takes a chord, and commands outside the set lose the chords the set
gives. Rows with one name in one block keep their own targets.
The engine's own namematch module is removed.

* Shortcuts: Cmd+, beside other hits, web Mac platform, cached dialog view

- Pin craft-keymap at 362eb59f.
- Cmd+, opens Settings on a Mac after the frame's other shortcuts run, with the
  Mac read from egui's OS; drop settings_chord, which dispatch no longer used.
- The web build follows the browser's OS, so Ctrl stays Ctrl on a Mac.
- The Keyboard Shortcuts dialog keeps its keymap, row texts and conflict count
  between frames while the working set is unchanged.
- Every default shortcut text becomes its entry's binding (test).
- craft-keymap counts as a UI crate for the layer check.
- Translate "too many changed shortcuts"; the parse error reuses the existing
  "can't parse shortcut `{c}`" message.

* Shortcuts: the chords the operating system takes can't be assigned

The keymap reserves craft_keymap::reserved::system for its platform:
window switching and closing, and the virtual consoles off the Mac.
The Keyboard Shortcuts dialog and shortcuts.set refuse them with
"<chord> is reserved by the system", and a saved override on one keeps
the entry's default. No default shortcut uses a reserved chord.

* Shortcuts: craft-keymap at craft-libs 2eca9b3a

craft-keymap comes from storytold/craft-libs (craft-libs #164 and #186), at the rev craft-pdf
already uses. The web build keeps the browser's full platform, so Windows browsers get Windows'
reserved chords, and each platform caches its own default keymap.
2026-10-24 15:01:26 -04:00
dotCooCoo 6e6fbbac1d Commands: an unknown command id is answered with the nearest command id
A misspelled parameter key got a did-you-mean suggestion, but a
misspelled command id only got "unknown command `select.al`", through
the CLI, MCP and the control channel alike. Session::execute now names
the nearest command id, using the same matching as parameter keys
(ignoring case), and action.batch does the same for an unknown step. An
id with no near match keeps the plain error.

The matching skips candidates whose length differs by more than the
allowed number of edits, so a very long unknown command id or parameter
key is answered at once instead of being measured against every command
id or accepted key.

The new message has a row in every catalog, and docs/mcp.md's
Parameter keys section shows it.
2026-10-24 11:20:27 -07:00
dotCooCoo 7a4ec1e530 Threaded text: New Symbol on a frame no longer duplicates its text
New Symbol and Redefine Symbol replaced a frame of threaded text by a
symbol instance whose art holds a copy of the frame. The thread's
re-flow then added the frame's text to the story, as it does for a
frame that was deleted, so the other frames held that text a second
time while the instance drew it.

A frame that New Symbol or Redefine Symbol puts in the symbol now
leaves its thread with the text it shows, and the other frames keep
the text they hold, as with Create Outlines, Expand and Flatten
Transparency. When the thread's last frame goes into the symbol, the
text it has no room for goes after the text of the last frame that
stays, and the copy in the symbol's art holds only the text the frame
shows. When every frame of a thread goes into the symbol, the copy of
the last frame keeps all its text. Undo restores the thread.

Docs: docs/mcp.md, docs/target-app-parity.md.
2026-10-24 11:15:42 -07:00
Marco Arnulfo 7a38c39a96 Properties and Transform: X, Y, W and H of a compound path's member set only that path (fixes #4046) 2026-10-24 19:53:46 +02:00
Marco Arnulfo 83600d3335 Color management: loading the working RGB profile again under its name takes effect at once 2026-10-24 19:36:34 +02:00
dotCooCoo deba1d1f76 Type: a recovered document keeps continued paragraphs in threaded frames
File > Data Recovery read the copy without marking the threaded frames
whose first paragraph continues from the frame before, so those frames
drew the paragraph's first-line indent and list marker again until the
next edit re-flowed the thread. The restored copy now gets the same
marks as an opened file.
2026-10-24 10:18:10 -07:00