Commit Graph
18604 Commits
Author SHA1 Message Date
.CooCoo 619a6e5ed1 Merge pull request #10071 from dotCooCoo/fix/symbol-options-unchanged-undo
Symbols: Symbol Options and Replace Symbol that change nothing add no undo step
2026-11-29 09:10:19 -08:00
.CooCoo c7e9e4c673 Merge pull request #10068 from dotCooCoo/fix/scale-numberfield-landed-test
Import PDF: a page number the Page field refuses goes back to the shown page
2026-11-29 09:10:03 -08:00
.CooCoo 963c6001ca Merge pull request #10064 from dotCooCoo/fix/number-text-row-commit-tests
Graph Type: test that typed numbers and text reach the draft only on commit
2026-11-29 09:09:47 -08:00
.CooCoo aaf7230372 Merge pull request #10059 from dotCooCoo/fix/refused-ok-keeps-draft
Slices: a refused OK keeps Slice Options and Divide Slices open with what was typed
2026-11-29 09:09:30 -08:00
.CooCoo b6e8af8817 Merge pull request #10058 from dotCooCoo/fix/artboards-numberfield-commit-test
New Document: a test checks that a typed Artboards count keeps the preset until committed
2026-11-29 09:09:14 -08:00
.CooCoo c6695df569 Merge pull request #10057 from dotCooCoo/fix/escape-tests-cancel-path
Tool options: tests cover a canceled field edit that keeps the dialog open
2026-11-29 09:08:58 -08:00
.CooCoo a6fdce3c51 Merge pull request #10055 from dotCooCoo/fix/bristle-direction-commit-tests
Brush Options: test that a canceled Bristle slider drag leaves the brush as it was
2026-11-29 09:08:41 -08:00
.CooCoo 45150cf4ed Merge pull request #10054 from dotCooCoo/fix/arrange-sibling-dialog-tests
Arrange: tests cover the settings chosen in Replace with Top Object and Sort Objects
2026-11-29 09:08:25 -08:00
.CooCoo 5f7add2106 Merge pull request #10053 from dotCooCoo/fix/freehand-fidelity-commit
UI: Fidelity applies only once committed in freehand Tool Options and the Contextual Task Bar
2026-11-29 09:08:08 -08:00
.CooCoo e21b9202e9 Merge pull request #10048 from dotCooCoo/fix/transparency-info-values
Transparency: transparency.info reports the selected symbol part that transparency.set edits
2026-11-29 09:07:52 -08:00
.CooCoo 3ffd486d5f Merge pull request #10063 from dotCooCoo/fix/appearance-narrow-paint-labels
Appearance: a narrow group shows the Stroke and Fill labels whole
2026-11-29 09:07:36 -08:00
.CooCoo 033a829995 Merge pull request #10062 from dotCooCoo/fix/export-screens-artboard-list
Export for Screens: the items sit in a framed view, and checked items show selected
2026-11-29 09:07:20 -08:00
.CooCoo 006efe0e91 Merge pull request #10061 from dotCooCoo/fix/panel-menu-command-names
Panels: menu rows show their names instead of command ids
2026-11-29 09:07:03 -08:00
.CooCoo 778e9cea99 Merge pull request #10051 from dotCooCoo/fix/links-panel-row-thumbnails
Links: rows of images on layers show their thumbnails
2026-11-29 09:06:47 -08:00
.CooCoo 0fe52b0a19 Merge pull request #10050 from dotCooCoo/fix/pathfinder-disabled-shape-modes-dim
Pathfinder: Shape Modes buttons dim while they are off
2026-11-29 09:06:31 -08:00
FredApps a9c926ba84 Merge branch 'main' into fix/craft-libs-869c970 2026-11-29 16:35:33 +01:00
dotCooCoo 6ef6df3407 Scripts: round artboard rows as main's New Document test expects, and drop pathItems= from the host table
Cause of the CI failures on 212090fd7a:
- main's dialogs::new_document test a_presets_rows_reach_the_document_create_makes
  sets artboardLayout.rows to 3.6 and expects 4, but this branch refused a
  rows value that was not a whole number. rows now rounds like columns and is
  still refused outside 1 to 1000.
- script_host_vs_scriptcheck listed Document.prototype.pathItems=, the
  setter of main's placeholder. This branch makes pathItems a read-only
  collection, like pageItems, so the row goes.
2026-11-29 06:45:32 -08:00
dotCooCoo fa1c0a8dc4 Tests: read retained paint chunks in every ui-egui shape walk
The pinned egui replays a region that did not change as one
Shape::PaintChunk of clipped shapes. Test helpers that walked
out.shapes by hand stopped at the chunk, so text, meshes, rects and
lines painted inside it were missed.

- Add painted_shapes and flat_painted_shapes next to text_shapes in
  tests/labels.rs. They open Shape::Vec and Shape::PaintChunk in paint
  order and compose each shape's transform and clip the same way.
- Route every remaining hand-written text and shape walk in the
  ui-egui tests through text_shapes or these helpers, keeping each
  test's assertions and its first-painted or last-painted order.
- panel_readout_copy: the Link Info Name check called the removed
  text_shape helper and did not compile; it now reads visible_paint.
  Format the file.
2026-11-29 06:01:24 -08:00
dotCooCoo 7a71837dea Scripts: keep new-art defaults and direct selections through path edits
- PathPoint.remove() renumbers the direct-selected anchors and segments
  after the removed point, and drops the removed anchor and the selected
  segments it ended, through selection commands after the points are
  written. A removed anchor no longer stays selected, and the same index
  no longer selects a different point.
- pathItems.add() reads new art's paint after the target document is
  active, so a path added to a document in the back keeps the stroke
  that document's selection gives new art.
- Paths a script draws put new art's paint back afterwards, so a
  defaultStrokeWidth the script set applies to every path it draws, not
  only the first.
- appearance.setNewArt refuses a fill or stroke paint with a setting a
  paint does not take, such as opacity, instead of applying the rest.
2026-11-29 05:51:46 -08:00
FredApps 98a8cda027 Track retained paint in VectorCraft menu and readout tests
Keep the existing pointer and text expectations on composed paint output. Preserve paint order and apply the retained transforms and clipping when finding drawn controls.
2026-11-29 14:25:08 +01:00
dotCooCoo dd93247cbf Scripts: tests index page items topmost first and check the preset fallback
Cause of the script_dom and script_dom_paths failures: main's 9872e6b679
("page items report their own members, and lists start with the topmost
object") made pageItems, pathItems and the selection list art topmost first.
The branch's tests still indexed the objects bottom first, so pageItems[1]
and pathItems[0] named the other object. The tests now make the objects in
the order the lists read them, and index them topmost first.

The own-members test asked about rotate, which this branch makes available,
so it now asks about transform, which is not available yet.

The fallback test for addDocument relied on five 1,000,000 pt artboards not
fitting, but a new DocumentPreset puts them in one column. It now unsets the
layout so the built-in preset puts them in one row, and the test fails when
addDocument falls back to the saved preset of the same name.
2026-11-29 04:41:14 -08:00
FredApps 267b55bfa5 Read retained paint chunks in UI label tests
Collect painted swatch labels from retained paint chunks as well as flat shapes. Keep the localized-label and physical pointer assertions unchanged in scope.
2026-11-29 13:40:19 +01:00
dotCooCoo 951e552a76 Symbols: Symbol Options and Replace Symbol that change nothing add no undo step
symbol.options recorded an undo step and moved the revision whenever any
option was passed, unless only alignToPixelGrid was given with the value
the symbol already had. A newName equal to the current name, or a
registration, export type, 9-slice, type or pixel grid value the symbol
already has, now leaves the document and its undo history as they are.

symbol.replace with the symbol the instances already show recorded an
undo step too. It now records one only when an instance changes.

Both run through colorcmds::edit_if_changed, as the Symbol Shifter and
the other symbolism tools do.
2026-11-29 02:43:57 -08:00
dotCooCoo ad0330f359 Merge main into fix/craft-libs-869c970 2026-11-29 02:37:56 -08:00
dotCooCoo 5ce0ab2e0d Tests: Save Options radio test measures the check box with its label
The check box and the text of its label are two accessibility nodes with the same name. The test now takes the bounds of every node so named on the same line, so it measures the gap from the check box row and not from its label text.
2026-11-29 02:37:49 -08:00
dotCooCoo 85d7248548 Window: Tab reads Standard Screen Mode's hidden chrome
In Standard Screen Mode the shell records Tab's hide as the chrome hidden, not as everything hidden. The Tab command and the tool lookup read only the second, so a second Tab hid again instead of showing the panels. Both now use panel_docking::tab_hidden.
2026-11-29 02:37:49 -08:00
dotCooCoo 7d9cd73f5f Toolbars: Rename Button works on a button whose command is dimmed
A context menu owned by a disabled button takes no clicks with the current craft-libs, so Rename Button... on a dimmed button opened no dialog. The row around the button now owns the menu, and a right click on the button opens it.
2026-11-29 02:37:49 -08:00
dotCooCoo cfa2bbb878 Dialogs: a style options dialog keeps its tab through its first measuring run
With the current craft-libs, the first show of a properties dialog is a measuring run that can end before the dialog's body runs, and it then sets the first tab as the shown one. A tab picked before the first frame (Tabs in Paragraph Style Options) was lost, so the Tabs pane and its Clear All Tabs button were not shown. The style options dialogs now keep the tab that was shown before a measuring run.
2026-11-29 02:37:49 -08:00
dotCooCoo 988edeabc6 Export for Screens: Space flips only the item it is pressed on
The items pane selects every checked item. Space on a selected item
flips that item and then the other selected items to its new value, so
Space on one checked artboard unchecked every checked artboard. The
pane now keeps only the flips of the first item a pass reports, which
is the lead item for Space. A test moves to a checked artboard with the
arrow keys, runs a frame and presses Space in the grid and the list.
2026-11-29 01:47:52 -08:00
dotCooCoo 31c0f6466a Import PDF: a page number the Page field refuses goes back to the shown page
The Page field in Import PDF and Place PDF read the typed number with
`value()`, so a number typed before text the field then refused on Tab
stayed as the chosen page while the field showed the page from before
the edit, and OK placed that page. The field now reads `landed()`, as
the DXF import options' Scale field does since #9747.

DXF import options gains a test for its Scale field that refuses text
on Tab and checks the import uses the restored scale; the Escape test
from #9747 passed with `value()` as well.
2026-11-29 01:18:05 -08:00
dotCooCoo c1bc3a2d50 Appearance: a narrow group shows the Stroke and Fill labels whole
In a 220 pt floating group the paint rows' links were cut to "S" and
"F": each row gives its trailing parts their full width first, and the
stroke weight was the Stroke panel's regular-size field with its
presets list. A paint row's weight is now a small field without the
presets list; its arrows, the arrow keys and the wheel still step it,
stopping at each preset. Fill rows reserve the same room, so the
swatches stay in one column.
2026-11-29 01:02:30 -08:00
dotCooCoo 4ce921dd1b Export for Screens: the items sit in a framed view, and checked items show selected
The Artboards and Assets panes drew their list and grid with no frame and
only as tall as their items, so with one artboard the view buttons, Clear
Selection and Prefix sat right under the thumbnail with empty space below.
The views were also shown without a selection, and the grid draws a tile's
check from the tile's selection, so a checked artboard had no outline and
its check box drew empty.

- The list and the grid sit on a sunken surface with control padding, and
  keep their height (9 rows, 4 tiles) when fewer items are shown.
- The checked items are bound as the view's selection, so they draw the
  selection outline and a checked box. The lead and anchor are kept per tab
  from pass to pass; the checks still decide which items are exported.
2026-11-29 00:59:38 -08:00
dotCooCoo b0b10c6109 Panels: tests compare the menu rows' flags now that rows are named
Four tests compared a panel menu row's whole state with one that had no
name, and failed once the rows were named: the Symbols view rows, the
Paragraph composer rows, the Links panel's Select rows and OpenType's
Reset row. They now compare the enabled and checked flags, or the state
with its name. The Links test also checks each Select row's Shift
alternate. Two lines in Align and CSS Properties are split to fit the
150-column width.
2026-11-29 00:46:50 -08:00
dotCooCoo 4b7ac69692 Scripts: fix path handles after main's revert count and review findings on path edits
PathItem handles carry the document's revert count, as page item
handles on main do, so path members find their path again.

setEntirePath and the path point setters throw a RangeError for a point
off the canvas. Opening a path whose closing segment is selected keeps
the edit. pathItems.add() leaves new art's paint as it was with New Art
Has Basic Appearance off. addDocument reports settings the built-in
preset refuses. appearance.setNewArt refuses a swatch that is not a
name. Writing one path's points looks only at that path afterwards.
2026-11-29 00:42:20 -08:00
dotCooCoo b0f821f2db Graph Type: test that typed numbers and text reach the draft only on commit
The Column Width and Prefix rows write the draft only when their edit is
committed. The existing dialog test still passed with either row reading
every proposal while typing, so a new test types into each row, checks
that the draft keeps its value, then presses Tab and checks that the
typed value is in the draft.
2026-11-29 00:39:56 -08:00
FredApps 452bf2013d Constrain the paragraph Tabs action row to the form width
Wrap the action buttons against the offered form width. Keep the accessibility lookup and pointer-click regression at both viewport sizes, and assert that the click target is inside the viewport.
2026-11-29 09:34:32 +01:00
dotCooCoo de7f1fc144 New Document: a test checks that a typed Artboards count keeps the preset until committed
Artboards is the one numeric field in Preset Details without a cancel
test. The new test types a count over the preset's 5, checks that the
dialog still shows the preset and its settings, presses Escape, and
creates the document with the preset's settings.
2026-11-29 00:07:51 -08:00
FredApps 6f3703bbab Advance shared PDF pin and honor Standard-mode Tab hiding
Keep the native and web craft-libs pins, Cargo.lock and PDF source checks on 57c8c8d4. Preserve the matching egui pin. Consult the shared Standard-mode chrome state for visibility and for show-panel requests; the dock already honors that state when drawing.
2026-11-29 08:38:26 +01:00
dotCooCoo 0bd735f53d Merge main into feat/scripts-doc-defaults 2026-11-28 23:20:21 -08:00
dotCooCoo 5ff0885acb Merge main into fix/panel-menu-command-names 2026-11-28 23:14:11 -08:00
dotCooCoo 8254c2f6d4 Slices: a refused OK keeps Slice Options and Divide Slices open with what was typed
Both dialogs closed on OK before the app checked the document and slices
they opened with, so a refusal (the selection changed, the document was
reverted, or the command failed) went to the status line and the typed
values were lost. They now open through the held-OK host: the check and
the command run while the dialog waits, a refusal shows its reason under
the rows with the values kept, and OK applies once the opening slices are
selected again.
2026-11-28 23:10:00 -08:00
dotCooCoo 7b7ad0bd0e Brush Options: test that a canceled Bristle slider drag leaves the brush as it was
For each of the five Bristle sliders, a held drag ended with Escape
restores the open dialog's field, and OK then keeps the brush and the
undo history unchanged. A released drag is kept by OK in one undo step.
2026-11-28 23:07:01 -08:00
dotCooCoo dc6ba53e6e Tool options: tests cover a canceled field edit that keeps the dialog open
The Live Paint Bucket Width test and the nullable length test pressed
Escape, which closes the modal, and then reopened it, so they passed with
the number and length rows still reading only proposals. Each test now
also types a value, adds text that does not parse, and leaves the field
with Tab. The dialog stays open, and the row must hold the opening value
again (4 px, and null).
2026-11-28 23:06:27 -08:00
.CooCoo 5f92d8987f Merge pull request #10040 from dotCooCoo/fix/scriptcheck-linear-steps
Script check: a script whose only finding is unsure names is scanned once
2026-11-28 23:02:49 -08:00
dotCooCoo 148541971f UI: Fidelity applies only once committed in freehand Tool Options and the Contextual Task Bar
The Contextual Task Bar ran tool.setOption for the Smooth tool's Fidelity
on every typed proposal, so a value typed and then canceled with Escape
stayed set on the tool. The bar now sets the option only when the field
commits the value.

In the freehand Tool Options dialog, Escape during a Fidelity slider drag
left the dragged value in the dialog. The draft now follows the drag
unrounded, takes the rounded value when the drag ends, and gets the value
from before the drag back on Escape, including a value above the slider's
end that the field allows. The dialog's Fidelity field reads its edit
events with landed(), as the variation fields do.

Follow-up to #9753.
2026-11-28 22:58:54 -08:00
dotCooCoo 4aea768632 Merge main into fix/panel-menu-command-names 2026-11-28 22:56:24 -08:00
dotCooCoo 92b009d819 Panels: menu rows show their names instead of command ids
The menus of Swatches, Brushes, Symbols, Graphic Styles, Appearance,
Paragraph, OpenType, Align, Glyphs, Pathfinder, Links, Actions, Asset
Export, Image Trace, Separations, Tabs, Flattener Preview, Color Themes
and CSS Properties showed 137 rows by their command ids, such as
"ui.swatches.newSwatch" and "brush.new". A panel menu row takes its
label from the command catalog, which lists the keymap's commands and
the menu bar's rows only; the panels' own commands, and commands with
params, have no entry there.

Each panel's menu states now name its rows, as Stroke and Transform
already did. Symbols' New Symbol… and Symbol Options… rows share one
command and showed one name, and the Links menu's four Select rows all
read Select by Link Status; each now shows its own name. The Paragraph
menu's East Asian rows are named too.

A test opens every panel menu in a frame of the whole app and fails
on a row that shows its command id, or on two rows of one menu level
that show the same name, with the East Asian and Indic options off
and on.
2026-11-28 22:56:23 -08:00
.CooCoo 81e7545e1b Merge pull request #10045 from dotCooCoo/fix/set-corners-commit
Set Corners: typed values reach the preview
2026-11-28 22:55:49 -08:00
dotCooCoo 5881c0c3f6 Arrange: tests cover the settings chosen in Replace with Top Object and Sort Objects
Replace with Top Object and Sort Objects bind their dialogs' values to
the fields the preview and OK read, as Arrange in Grid, Set Size of Each
and Randomize Opacity do, but no test covered those two. The new tests
pick Bounds and Keep Original in Replace with Top Object and Large to
Small in Sort Objects with the dialog's own controls, then check the
dialog's values, the preview and the document after OK. Each fails when
its dialog's values are not bound.
2026-11-28 22:53:58 -08:00
dotCooCoo 5b76aa74fe Merge main into fix/links-panel-row-thumbnails 2026-11-28 22:34:59 -08:00