A radius written with tool.setOption during a press changed the circle
only when Shift was released and pressed again before the drag started.
The press now keeps the radius from its button press for every Shift
change until the release.
The Ellipse tool previewed the circle through two Shift-clicked points
and the pointer as a dashed outline at any size. The canvas dashes an
outline along its whole length, so points nearly on one line (a radius
of about 1,250,000 pt) gave about a million dashes every frame.
The preview now uses the Circle tool's limit: a circle more than 50,000
screen points around is drawn solid. Both tools call one helper,
`circle::preview_dashed`.
When the paths together are over the segment limit, the search maps the
paths near the point and leaves out the ones with the most segments. A
path left out made the search give up on an area when it came within the
gap plus 1 pt of the area's outline, so with Gap Detection off a long line
0.75 pt outside a square stopped a click inside the square from filling
it. A gap bridge reaches at most the gap, so the check now uses the gap
plus the map's 0.05 pt contact tolerance. The 1 pt padding still decides
which paths the search picks.
Most of this pull request reached main with #4221 (the smooth join and the
redraw preview). What is left:
- A redraw stroke's end bends onto the path over Edit selected paths' distance.
When the stroke's points are far apart (a fast stroke), the bend used to run
on to the next point; a point is now added where the bend stops, and only one
where both ends' bends stop at the same place.
- The preview of a redraw stroke is drawn on top, as with Draw Normal, in Draw
Behind and Draw Inside too; before, it went behind the path or into its clip
group. path.freehand's `leaveSelection` becomes `preview`, which does both.
Fill Area used the full outline of art inside a clipping group, so a
click in the part a mask hides still found an area, and the new path
above the clipping group showed art the mask hid. Now each clipped
path is cut to every mask around it before it bounds areas, nested
clipping groups and clipped layers included: a filled path keeps its
overlap with the mask, and the outline of an unfilled path and open
paths keep only their pieces inside it. A mask that clips to nothing
hides what it clips. The new path still goes above the clipping group.
Follows #8001.
A selected ruler guide was left out of every transform but a move: the
Rotate tool did nothing with only guides selected, and Object › Transform
› Rotate… refused with "nothing selected".
Each selected ruler guide now transforms as the line Release Guides makes
of it (across its artboard, or across the artboards' bounds for a canvas
guide), about the center of the selected objects' box and those lines
together. A guide that ends up vertical or horizontal stays a ruler guide:
a half turn keeps it and a quarter turn makes a horizontal guide vertical.
At any other angle it becomes a guide path along its line, on the guide's
layer, so it snaps, releases, locks and saves as other guide paths do.
- Object › Transform › Rotate… (Copy included), Transform Again and the
Rotate tool's drag and Alt-click work with only guides selected, in one
undo step. A turn that leaves the guides where they were records none.
- Scale, Reflect, Shear and the bounding box now transform selected guides
along with the selected objects and direct-selected anchors, where
before the guides stayed put.
- Locked and hidden guides, guides with ids given and guides with
Transform Objects off do not transform. `absolute` with only guides
selected is an error.
Part of #2418.
VectorCraft's UI moves onto the shared craft UI framework in storytold/craft-libs (`next`; the framework side is storytold/craft-libs#2809), as PhotoCraft's did. The app keeps its engine, document model, file formats, commands and automation; its windows, panels, bars, dialogs and canvas are now built and driven by the framework: shell, docking and panels, hosted dialogs, keyboard, focus, IME and pointer routing, and theme tokens.
About 264,000 lines of VectorCraft's own egui UI code are removed and about 154,000 added. craft-libs is pinned at bf62d509f (in `next`), the egui fork at f5025284.
Tests that drove the old UI were rewritten against the port where only their premise changed, with their assertions kept. The UI tests still failing at merge, and their follow-ups, are listed in the pull request.
A press on a length handle kept the Smart Guides of the hover before
it, so a guide or label at the handle stayed on screen for the whole
drag. The press now clears them, as a press away from a handle does
when it places a point.
The Smart Pen Tool joins the Pen group in both shipped toolbars, after
the Quick Pen, and stays in Object › Plug-ins › Smart Pen. The All Tools
drawer lists it once, under Draw, and Edit › Keyboard Shortcuts › Tools
lists it once. It has no default shortcut, and the Pen keeps P. A
toolbar the user already edited keeps its saved layout; Reset Toolbar
adds the tool.
A group torn off the Tools panel's toolbar now shows the tools of the
current layout's group that starts with the same tool, after toolbar
edits, Reset Toolbar, a switch between Basic and Advanced, loading the
preferences and switching workspaces, as groups torn off a toolbar made
with New Toolbar already did. A strip with no such group keeps its
tools.
Part of #8326
Choosing a fill while the Shape Builder was active (a swatch, the Color
panel, the Fill box or a paint command) ran paint.setFill on every
selected path, so all of them took the color. With Pick Color From set
to Color Swatches the tool merges with the current fill, so the pick is
the color for the next merge.
While the Shape Builder is active, a fill chosen without ids, id or item
now changes only the current fill, with either Pick Color From: with
Color Swatches the next merge fills with it, and with Artwork merges
still take their look from the art. A stroke chosen then still goes to
the selection. Swap Fill and Stroke and Default Fill and Stroke change
only the paint for new art, and Swap gives the current fill the stroke
the Stroke proxy shows. This is VectorCraft's own rule; no default
setting changes.
- painting_tool_of says which tool paints with the chosen fill or
stroke: the Live Paint Bucket with both, the Shape Builder with the
fill. Session::tool_paints(stroke) replaces bucket_paints, so the
paint and gradient commands, previews, the proxies, the Stroke panel
and the Gradient panel's eyedropper follow it for each kind.
- A new selection does not replace the tool's fill for new art, with
New Art Has Basic Appearance on or off, and new art is not linked to
a graphic style whose fill it does not have.
- A cancel puts back a fill previewed for the tool, also after another
tool was chosen during the drag.
- An Eyedropper pick armed for a stop of the tool's gradient samples
only into a stop of that gradient, and ends once that stop is gone.
Choosing another tool drops the stop the pick was armed for, and a
pick armed while the Eyedropper waits for a Cmd-drag keeps its stop.
- The paint.freeform commands refuse the Shape Builder's fill as they
refuse the Live Paint Bucket's colors, which lie on no object. For
the gradient either tool paints with, the Color panel, the Gradient
panel, the stop popover and swatch drops edit its stops instead of
points, and the Gradient panel shows its Draw toggle, ramp and stop
fields in place of the point controls. paint.editGradient keeps the
given stops of a freeform gradient that has no points yet.
- A gradient command that names no kind edits the proxy in front when
the tool paints with it, else the kind the selection's active
Appearance row stands for.
- set_paint lists the commands that painted no object in unpainted.
- Params text and docs/mcp.md describe the rule.
Help (Pick Color From, Color Swatches):
https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/draw-shapes/shape-builder-tool-options.htmlhttps://help.adobe.com/archive/en_US/illustrator/cs5/illustrator_cs5_help.pdf#page=266https://help.adobe.com/archive/en_US/illustrator/cs5/illustrator_cs5_help.pdf#page=267
A length drag that changed the length and then came back to where it
started previewed the path again at its first length, so letting go
recorded an undo step for an unchanged path. A drag that ends at the
length the piece started with is now taken back as Escape takes it
back, on the path being drawn and on a selected path.