mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-12-03 12:35:48 -05:00
A document now has layers, activeLayer, groupItems, compoundPathItems and artboards, and every page item has its layer. - Layers and sublayers: add, remove, removeAll, getByName, index, name, visibility, lock, print, preview, dim images, opacity, color, stacking, move and zOrder, each through the existing layer and node commands. - Groups: clipped makes or releases the clipping mask, and groupItems.add() makes an empty group through the new narrow command object.newGroup. A document's groupItems and compoundPathItems hold every group or compound path at any depth; a layer's or group's hold only the ones directly in it. - Artboards: add, insert, remove, getByName, rectangles, names, ruler origin, pixel aspect ratio and display options, and the active artboard. A new artboard gets an "Artboard N" name no other artboard has. setActiveArtboardIndex adds no undo step; script.run's report lists the change in activeArtboards and the app shows it. - Bad values throw before any command runs, and a value a layer or artboard already has runs no command. Handles to a deleted layer or artboard throw Stale layer or Stale artboard. Docs: docs/mcp.md, docs/gaps.md, docs/target-app-parity.md.