Commit Graph
23610 Commits
Author SHA1 Message Date
dotCooCoo db7fe4d38b Scripts: tracing keeps added images and direct selections; app.open logs warnings
- Expanding a tracing removes only its source image; other images a script
  moved or duplicated into the group stay.
- A TracingObject goes stale when its original source image is gone, even
  when another image now sits first in the group.
- Tracing, retracing, expanding and releasing restore the whole selection,
  anchors and segments included, with only the replaced object remapped.
- app.open writes the open's warnings to the script console, as saveAs does.
- embed() checks the image's link state after the command instead of a
  returned id rounded to a JavaScript number.
- The placed-image tests pass ordinary drive paths to File on Windows.
2026-11-29 17:02:07 -08:00
dotCooCoo 64972e8a91 Scripts: saveAs logs the save's warnings; exact grants cover linked files; a tracing's source stays first
- Document.saveAs writes each warning file.saveAs gives to the console as a
  line that starts with "saveAs: ", and still returns undefined.
- A save, export or open of a File the script names no longer reads a file
  an open document links to outside the script's grants.
- A save or export that writes several files checks that no folder is where
  one of them goes before it writes the first, so none of them is written.
- Moving the source image of a tracing within its tracing, and zOrder on it,
  leave it first; zOrder SENDTOBACK on another object in a tracing puts it
  just above the source.
- The two new script file errors are English only; their catalog rows are
  removed (translations go through storytold/craft-i18n).
2026-11-29 15:49:36 -08:00
dotCooCoo 94a6d6ccf7 Tests: the placedItems.add() revert test edits the document first, so File > Revert is available 2026-11-29 14:27:42 -08:00
dotCooCoo 68ac11f96e Merge main into feat/scripts-api-d8b-tracing
# Conflicts:
#	docs/target-app-parity.md
2026-11-29 13:43:24 -08:00
dotCooCoo e59994ead4 Scripts: placed and raster members use main's described member lists; a placedItems.add() result goes stale after File > Revert
The images, tracing and save/open members now carry the type and
argument descriptions that main's Described lists expect, and
PlacedItem.contentVariable comes from the variables members. A
placedItems.add() handle now records the document's revert count, so
reading or assigning its file after File > Revert throws Stale page
item and places nothing, as other page items do.
2026-11-29 13:42:47 -08:00
Dylan M. Taylor a3b93d585b ci(sonarcloud): give each main commit its own concurrency group (#10126) 2026-11-29 15:57:37 -05:00
.CooCoo 4e6d3d0f8e Merge pull request #10119 from dotCooCoo/fix/global-edit-preview-cache
Global Edit: the canvas shares the kept outlines instead of copying them each frame
2026-11-29 12:53:25 -08:00
.CooCoo 429d60a341 Merge pull request #10117 from dotCooCoo/fix/status-bar-wheel-rebuild
Status bar: scrolling the view no longer lays out the zoom and artboard controls again
2026-11-29 12:53:07 -08:00
.CooCoo 7d717b6318 Merge pull request #10103 from dotCooCoo/fix/tools-footer-scrolls
Tools: the controls under the tools scroll with them in a short window
2026-11-29 12:52:49 -08:00
FredApps f1335a5f19 Merge pull request #10098 from storytold/chore/free-macos-release-runner
CI: use the standard macOS runner for releases
2026-11-29 21:23:53 +01:00
FredApps 3ef21dcb09 Merge pull request #10100 from storytold/chore/release-0.25.0
Release: VectorCraft v0.25.0
2026-11-29 21:23:48 +01:00
.CooCoo d7a83d8b12 Merge pull request #10114 from dotCooCoo/fix/craft-libs-radio-rows
Tests: Save options radios start in the control column
2026-11-29 12:10:40 -08:00
.CooCoo a59ef7479a Merge pull request #10108 from dotCooCoo/fix/type-editor-single-pass
Type: an edit runs each idle and typing frame once
2026-11-29 12:10:23 -08:00
dotCooCoo 214c88d985 Tools: the controls under the tools scroll with them, as bottom_controls says
The doc comment on bottom_controls still said the tools scroll above the controls in a short rail. The Tools panel's rail now uses footer_scrolls, so the controls scroll with the tools and the rail draws the rule above them.
2026-11-29 11:45:44 -08:00
dotCooCoo 7e5d8d368c Merge main into fix/global-edit-preview-cache 2026-11-29 11:36:55 -08:00
dotCooCoo 3617039ef5 Global Edit: the canvas shares the kept outlines instead of copying them each frame
With one object selected and the Selection tool active, or while Global
Edit is on, every frame copied each highlighted outline out of the kept
list and made one overlay per object, which the canvas flattened and
stroked again. With 10,000 matching objects that was most of a 27 ms
frame.

highlights and similar now return the kept outlines as a shared
Highlights, grouped by layer color with a revision that changes only when
the outlines are found again. The session sends one Overlay::Outlines per
color, and the canvas shows it as a SelectionOutline keyed by that
revision, so the lines are stroked again only when the outlines or the
view change.
2026-11-29 11:36:48 -08:00
.CooCoo da9c3947e2 Dialogs: style options dialogs keep their tab through the framework (#10109)
craft-libs 186a229c8d holds storytold/craft-libs#4261, so a properties
dialog keeps its bound tab when a measuring frame ends before its body
runs. The style_dialog! wrapper no longer saves and restores the tab
around that frame for Character Style Options, Paragraph Style Options
and New Character Style or New Paragraph Style.

New tests open Character Style Options on Advanced Character Formats,
New Character Style on Character Color, and Document Setup on
Transparency, Type and Color, and check that each tab is still shown
after the first frames. With craft-libs before that change they fail
with the dialog back on General.
2026-11-29 14:34:41 -05:00
dotCooCoo 0a5d81ed00 Merge main into fix/tools-footer-scrolls 2026-11-29 11:28:45 -08:00
.CooCoo 1772dfcce3 Merge pull request #10107 from dotCooCoo/fix/control-bounds-flat-walk
Performance: paths keep their control-point box, so a hover reads no anchors
2026-11-29 11:26:32 -08:00
.CooCoo 02dd9f3fd0 Merge pull request #10106 from dotCooCoo/fix/stroke-host-labels
Stroke: Cap, Corner, Align Stroke and Miter Limit line up with the panel rows
2026-11-29 11:26:16 -08:00
.CooCoo ed097438f0 Merge pull request #10102 from dotCooCoo/fix/new-document-card-tiles
New Document: preset cards rest on a tile
2026-11-29 11:25:59 -08:00
.CooCoo 0a572454c9 Merge pull request #10101 from dotCooCoo/fix/doc-info-image-trace-shared-layout
Panels: Document Info rows and Image Trace Create use the shared row and check box layouts
2026-11-29 11:25:43 -08:00
.CooCoo 3b90e54a61 Merge pull request #10099 from dotCooCoo/fix/rail-footer-divider
Tools: the rail shows one rule above the controls under the tools
2026-11-29 11:25:27 -08:00
.CooCoo 0e8ae4d52b Merge pull request #10097 from dotCooCoo/fix/hit-test-one-walk
Selection: a click or hover that hits nothing walks the document once
2026-11-29 11:25:11 -08:00
.CooCoo 73d7bd813a Merge pull request #10096 from dotCooCoo/fix/drop-floated-from-icons
Docking: drop the icon-column float workaround now that craft-libs expands it
2026-11-29 11:24:53 -08:00
dotCooCoo 4b908d9416 Merge main into fix/status-bar-wheel-rebuild 2026-11-29 11:24:49 -08:00
dotCooCoo 9f7501a8f6 Status bar: scrolling the view no longer lays out the zoom and artboard controls again
The status bar's Zoom field, Zoom Presets menu, Rotation menu and artboard
navigator were one memoized view keyed on the whole canvas view, so every
frame of a wheel pan changed the key and ran all four again. The Zoom field
reads only the view's zoom, and the status bar reads only the zoom of the
view the field commits.

- The Zoom field and Zoom Presets menu are their own memoized view, keyed on
  the zoom instead of the canvas view, so a pan replays them.
- The Rotation menu and the artboard navigator are a second memoized view, so
  a zoom change runs only the zoom controls.

The new test counts the runs of each view over ten pan frames and four zoom
changes; before the change the pan ran the navigation controls ten times.
2026-11-29 11:24:48 -08:00
.CooCoo 52de8120d3 Merge pull request #10105 from dotCooCoo/fix/script-dom-path-edits
Scripts: point removals keep the selection, new-art defaults and batching right
2026-11-29 10:58:53 -08:00
.CooCoo cdafb992f3 Merge pull request #10095 from dotCooCoo/ci/warnings-G2
CI: app manifests and cdylib doc tests no longer warn
2026-11-29 10:57:43 -08:00
dotCooCoo f6435bf1f7 Merge main into fix/craft-libs-radio-rows 2026-11-29 10:55:18 -08:00
dotCooCoo 8cde91c418 Tests: Save options radios start in the control column
The craft-libs pin on main includes craft-libs#4231, which starts a
radio row's options past the form's label column. A new test checks
that in the EPS and .ai save options dialogs the All and Range radios
start where the artboard check box starts, and that Transparent and
Opaque start where the Preview menu starts. With the craft-libs rev
pinned before #4231 it fails: All starts at x 526 and the check box at
x 619.
2026-11-29 10:54:58 -08:00
.CooCoo 8b96a72de4 Merge pull request #10104 from dotCooCoo/fix/script-name-setter-stale-first
Scripts: page-item setters report a stale item before a bad value
2026-11-29 10:51:52 -08:00
dotCooCoo 92a2056a8b Scripts: page-item setters report a stale item before a bad value
The name, note, hidden, locked, opacity, blendingMode, position, left,
top, width and height setters checked the assigned value before the
item, so a bad value on a removed item reported the value error instead
of "Stale page item". Each setter now looks up its item first.
2026-11-29 10:26:04 -08:00
dotCooCoo 87b5aef639 Scripts: point removals keep the selection, defaults and batching right
Follow-up to #9288.

- Removing the last anchor of a closed path with its closing segment
  selected also deselects the first anchor, the segment's other end.
- Removing a point puts back new art's paint, so a default stroke width
  a script set still applies to the next path it draws.
- A removal that leaves the direct selection as it was waits with the
  other point changes, unless every remaining anchor is now selected,
  the selection refers to points that are gone, or the path is in an
  Objects on Path group.
- Reading the points of a path first writes the waiting point changes
  of another path in the same Objects on Path group.
- Writing a path in an Objects on Path group checks the other tracked
  paths in the outermost such group, so their PathPoint handles go stale
  when the group moves them, even after an undo.

Docs: docs/mcp.md, docs/target-app-parity.md.
2026-11-29 10:24:53 -08:00
.CooCoo 283902214f Merge pull request #10075 from dotCooCoo/feat/offset-objects-row
Arrange Tools: Offset Objects chains the selection in a row or a column with a set gap
2026-11-29 10:23:17 -08:00
.CooCoo 8aa8120586 Merge pull request #9777 from ruchirguitar/feat/spell-check
Spell-check other languages from the Craft apps' Language packs
2026-11-29 10:23:00 -08:00
dotCooCoo 37a04cb72d Merge main into fix/control-bounds-flat-walk 2026-11-29 10:19:36 -08:00
dotCooCoo c10d62d027 Performance: paths keep their control-point box, so a hover reads no anchors
Hit walks measure every path's culling box with PathData::control_bounds,
which read every anchor of the path on every call. Since anchors are kept
in shared chunks, that read follows two more pointers per path and goes
through the chunked iterator, so each node of a hover or cursor walk cost
about twice what it did before the chunks.

Each subpath's anchor list now keeps the box round its points and handles
once it is measured (Anchors::control_bounds), and every change to the
list clears it. A copy of the list keeps the box too. control_bounds
unions the subpaths' boxes, with the same result as before.

- anchors.rs: control_bounds reads the anchors once until they change,
  counted by measured_control_anchors; each change to the list clears it.
- Tests count the anchors read: a list reads them once across calls and
  copies, again after each kind of change, and a hover past 100 squares
  reads none after the first.
2026-11-29 10:19:29 -08:00
dotCooCoo c328567a9f Merge main into fix/stroke-host-labels 2026-11-29 10:17:57 -08:00
dotCooCoo ec51f3d037 Stroke: Cap, Corner, Align Stroke and Miter Limit line up with the panel rows
The Stroke panel showed the stroke editor's rows with a label column of
their own, so the Alignment, Caps and Corners buttons and the Miter
Limit and Dash offset fields started left of the Weight, Arrowheads and
Profile controls. The panel now turns on StrokeEditor::host_labels
(craft-libs#4227, in the pinned craft-libs), and the editor's rows read
the label column of the panel's Stroke Options group.

the_panel_rows_start_their_controls_at_one_x now also checks the
Alignment, Caps, Corners, Miter limit and Dash offset controls.
2026-11-29 10:17:57 -08:00
dotCooCoo 1bdaf3f849 Merge main into fix/type-editor-single-pass 2026-11-29 10:16:00 -08:00
dotCooCoo a978fd242a Type: an edit runs each idle and typing frame once
The Type tool's text part was shown in the canvas's flow, in a scope
sized to the caret. While the tool edited text, every other frame ran
its UI twice: the frame's layout check found the part changed and the
frame was run again.

The part is now shown at the caret's rect with no allocation, as the
canvas's other overlays are, and each idle and typing frame runs once.
2026-11-29 10:16:00 -08:00
dotCooCoo 599426f075 New Document: preset cards rest on a tile
The app's root look now sets PresetCardLook::PageTile in place of Page,
so each preset card in New Document draws on a light veil of the scrim
with its paper on it. A card that is not selected now stands apart from
the dialog's surface. The craft-libs pin at 186a229c8d already has the
look (storytold/craft-libs#4180).

The new test resting_preset_cards_stand_on_a_tile checks that a resting
card is covered by a veil of the scrim and holds its white paper; it
fails with the old Page look.
2026-11-29 10:14:35 -08:00
dotCooCoo 25b0c5cc93 Merge main into fix/tools-footer-scrolls 2026-11-29 10:12:28 -08:00
dotCooCoo c31cef1199 Tools: the controls under the tools scroll with them in a short window
In a window too short for every tool, the Tools panel kept its paint
chips, drawing modes and the other controls under the tools pinned at
the bottom, so fewer tools were in view. The controls now scroll with
the tools
(ToolRail::footer_scrolls): in a window 560 points tall the rail shows
14 tools instead of 10, and scrolling to the end brings the controls
into view under the last tool. Toolbars made with New Toolbar and
torn-off strips keep their footer in view.
2026-11-29 10:12:28 -08:00
dotCooCoo 19f1cf0aa0 Scripts: a File keeps its path in FsEntry under main's file_path
main reads a script's File for host class members through
file_classes::file_path and defines FILE_REF_KEY and file_ref_path in
host_classes. file_path now reads the path from the object's FsEntry slot,
so an object made with Object.create(File.prototype) still is not a File,
and the branch's own copies of FILE_REF_KEY, file_ref_path and file_ref_of
are removed. file_ref uses main's key. The host class tests set the new
HostClass::info field.
2026-11-29 10:01:51 -08:00
dotCooCoo b02c572ec4 Merge main into fix/doc-info-image-trace-shared-layout 2026-11-29 10:01:29 -08:00
dotCooCoo 6c0ce43b98 Panels: Document Info rows and Image Trace Create use the shared row and check box layouts
The craft-libs pin now includes storytold/craft-libs#4147 and #4195. A
wrapping SpaceBetween row keeps its children at both edges when they fit
on one line, and a check box in a row inside a field shows its own label.

- Document Info: a row wraps through the shared row layout instead of
  measuring its label and value first. A row that fits keeps its value at
  the end; otherwise the value moves under the label.
- Image Trace: the Fills and Strokes check boxes in the Create field show
  their own labels, without a nested field for each.

A new test checks that a Document Info value that does not fit beside
its label moves under it.
2026-11-29 10:01:22 -08:00
Fredrik Hallin a17883546e Release: VectorCraft v0.25.0
Ship the drawing, text, import/export and editing fixes merged since 0.24.1.
2026-11-29 18:58:59 +01:00
dotCooCoo 73499bb62f Merge main into feat/scripts-api-d8b-tracing 2026-11-29 09:57:07 -08:00