Skip to content

Artboards: Duplicate Artboards, Copy and Cut take every selected artboard - #2567

Merged
bflatastic merged 1 commit into
storytold:mainfrom
dotCooCoo:feat/artboards-duplicate-copy-cut-selected
Oct 17, 2026
Merged

bflatastic merged 1 commit into
storytold:mainfrom
dotCooCoo:feat/artboards-duplicate-copy-cut-selected

Conversation

@dotCooCoo

Copy link
Copy Markdown
Contributor

What and why

On main, select two artboards with the Artboard tool (Shift-click) and choose Duplicate Artboards in the Artboards
panel menu: only the active artboard is copied. Copy and Cut with the Artboard tool also take only the active artboard,
so Paste brings back one. The public Use the artboard context menu
and Cut, copy, and paste artboards
pages describe these commands acting on the selected artboards.

artboard.duplicate, artboard.copy and artboard.cut now take indices. Without index or indices they act on
the artboards the Artboard tool has selected, so Edit › Copy and Cut take them all with the art on each. Duplicate and
Cut are one undo step each, and Paste adds every copied artboard back in one undo step. The copies keep their places
relative to each other, together right of the last artboard. The panel menu's Duplicate Artboards passes the selected
artboards and selects the copies.

How it was tested

  • tests_panelcmds::duplicate_artboards_copies_every_selected_artboard_in_one_step: with two of three artboards
    selected, artboard.duplicate with indices and with no params copies both with their art in one undo step.
  • tests_panelcmds::artboard_tool_copy_and_paste_bring_every_selected_artboard: Copy then Paste adds both artboards
    with their art in one undo step, and the tool selects them; Paste in Place puts them where they were.
  • tests_panelcmds::artboard_tool_cut_removes_every_selected_artboard: Cut removes both and their art in one undo
    step, and fails with every artboard selected.
  • panels::artboards::tests::the_panel_menus_duplicate_artboards_copies_every_selected_artboard: the menu item
    copies both artboards in one undo step and selects the copies.

With the commands acting on one artboard only, as on main, and the menu item calling duplicate as on main, each
of the four tests fails at its first check.

On Windows 11 (x86-64) with rustc 1.99.0, on top of main at 8bc6532:

  • CRAFT_FONTS_DIR=<craft-fonts checkout> cargo xtask ci passes its 9 steps: 7,368 tests passed, 0 failed, 11 ignored.

git merge-tree reports no conflicts with main at 8bc6532. The branch conflicts with #2556, which adds a
duplicate_picked at the same place (keep this branch's; the task bar then calls it), with #2532 in the cut (run
ensure_unlocked on every index), with #2566 (keep this branch's boards_and_art, #2566's artboard_index and test
with clipboard.artboards, and #2566's last docs/mcp.md sentence), and with #2559, #1838 and #1295.

Checklist

  • cargo xtask ci passes (fmt, clippy, tests, assets, brands, layers, wasm).
  • No panics in shipped code: no unwrap(), expect(), panic!, unreachable!, todo! or
    unimplemented! outside tests, and no unchecked indexing on data from files, parameters or
    messages. Errors are returned as Result and shown to the user
    (why and how).
  • Clean-room: nothing copied from Adobe products or GPL/AGPL code (AGENTS.md).
  • Every new asset has a row in ASSETS.md.

…oard

With several artboards selected, the Artboards panel menu's Duplicate
Artboards copied only the active one, and Copy and Cut with the
Artboard tool took only the tool's active artboard.

artboard.duplicate, artboard.copy and artboard.cut now take `indices`,
and without `index` or `indices` they act on the artboards the
Artboard tool has selected. Duplicate Artboards passes the selected
artboards and selects the copies. Duplicate and Cut are one undo step
each, and Paste adds every copied artboard back, with its art, in one
undo step. The copies keep their places relative to each other,
together right of the last artboard. A cut fails when it names every
artboard.

Docs: docs/mcp.md, docs/target-app-parity.md.
@bflatastic
bflatastic force-pushed the feat/artboards-duplicate-copy-cut-selected branch from 63f40c2 to cdb0bbe Compare October 17, 2026 07:37
@bflatastic
bflatastic merged commit c1f543d into storytold:main Oct 17, 2026
2 of 3 checks passed
@bflatastic

Copy link
Copy Markdown
Member

Thanks @dotCooCoo, merged. We merged it with #2566 (merged earlier today): the copy commands use your boards_and_art, Move Artboard Up/Down keeps #2566's index check, and the docs keep both notes. It went through the full gate (fmt, clippy, tests, layers, wasm) in a batch with the other PRs landed today.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants