Commit Graph
12 Commits
Author SHA1 Message Date
dotCooCoo c7aa27ec12 Transform: saved Scale and Reflect steps without a basis keep the page's axes
An action or journal entry recorded before Scale and Reflect followed the
turned bounding box has no basis value. Replayed, such a step now acts along
the page's axes, as it did when it was recorded; steps recorded now carry
basis "box" and replay along the box. The built-in Reflect Horizontal action
names basis "box", so it keeps reflecting across the box's own axis.

The symbol test that reflects a turned instance names basis "page", which
is the reflection it was written for.
2026-11-14 16:30:56 -08:00
dotCooCoo b00e50d4c5 Transform: pattern-only Scale and Reflect of selected anchors follow the box
With anchors selected and Transform Objects off (objects: false, or the
backquote key during a Scale or Reflect drag), the transform moves the
whole objects' pattern tiles, so it now acts along the turned bounding
box instead of the page axes that apply to the anchors alone.
2026-11-13 11:32:51 -08:00
dotCooCoo 78889ce8af Transform: Scale and Reflect act along a rotated bounding box
The Scale and Reflect tools, object.scale, object.reflect and the
Transform panel flips act along a rotated bounding box instead of the
page axes, until Object > Transform > Reset Bounding Box, as Free
Transform does. The Scale and Reflect dialogs and the Properties panel
flips run the same commands and follow the box too.

- object.scale and object.reflect with a named axis take
  basis?: "box"|"page" ("box" by default; "page" keeps the page axes;
  any other value is an error before anything changes). The journal
  records the basis, so recorded actions replay in the same frame; an
  older recording without it acts along the box.
- A numeric Reflect axis and a Reflect axis drawn with the tool stay
  lines on the page. While a Reflect drag has not drawn an axis away
  from the reference point, the tool uses the box's vertical axis, and
  Shift steps 45 degrees from the box.
- Mixed-angle selections and anchors selected with Direct Selection use
  the page axes; an Alt-drag copy of such anchors scales the whole
  objects along their box. Transform Again repeats the page matrix.

Docs: docs/mcp.md, docs/target-app-parity.md, docs/ui-parity.md.
2026-11-13 09:37:31 -08:00
dotCooCoo 5ac7d97d85 Guides: ruler guides are document objects on their layers
Ruler guides were a list kept beside the layers. Each guide is now an
object of its layer or sublayer, always directly in it and above the
layer's art. These behave as on main:

- Guides draw on screen only. Exports (SVG, PDF, PNG, PSD), Fit All,
  Select All, the art bounds, clicks and marquees, and a layer's
  Pathfinder and Transform effects leave them out. The Layers panel
  lists them as guide rows of their layer, the highest guide.list
  index first.
- Deleting a layer deletes its guides, and merging layers keeps their
  guides in the merged layer.
- The guide commands number guides as guide.list does, in the order
  they were made.

New: each guide takes an id from the document's object ids. An object
command given a guide's id fails with an error, and node.move cannot
put a guide into a group or out of its layers. A guide made while an
opacity mask, a symbol or a pattern is edited moves to the top
visible, unlocked layer when editing ends.

File format: native files still save the guides in the document's
guides list, in every file version, so older builds read them. Each
entry may now also carry the guide's id, name, locked and hidden
flags; older builds ignore those fields. Opening a file puts each
saved guide on its layer (on the top visible, unlocked layer when the
file names none or a layer it does not have), and each saved guide
counts against the object limit for opening a file. A ruler guide node
that a file holds below a layer's art moves up to the layer's guides,
and one anywhere else (in a group or another object, beside the
layers, or in a symbol) is removed. Ruler guides read from an .ai file
become guide objects on the layer they were on, numbered in the order
the file lists them.
2026-11-11 09:52:28 -08:00
dotCooCoo a1949095c6 Type: an option fits a text object's bounds to its glyph outlines
Measure Type by Glyph Bounds (`typeGlyphBounds`, off by default) is in
Preferences > Type > Glyph Bounds and the Transform panel menu. With it
on, the bounding box, the Transform, Control bar and Properties X, Y, W
and H, `object.setBounds`, the transform tools' reference point and the
Arrange commands measure point type selected on its own by the ink of
its glyphs instead of its em box. A typed W or H scales the live type
until its ink has that size.

- The engine caches each type object's ink in text space with its
  layout bounds; the cache is not saved.
- Use Preview Bounds adds the characters' strokes, and type with
  geometry effects is measured as drawn. Skewed type is measured by its
  outlines.
- Type that draws nothing, area type, type on a path and type inside a
  selected group are measured as before. Align and Distribute keep
  following Align to Glyph Bounds.

Docs: docs/mcp.md, docs/control-protocol.md, docs/target-app-parity.md,
object.setBounds params text.
2026-11-09 21:07:55 -08:00
dotCooCoo 1f38a16329 Commands: an ids list with an entry that is not an id is refused instead of dropping the entry
Squashed from #6179 onto main.
2026-11-09 02:54:32 +07:00
dotCooCoo 581ced3213 Transform: Align to Pixel Grid keeps an object's horizontal and vertical edges on the pixel grid
Squashed from #6169 onto main.
2026-11-09 00:29:28 +07:00
dotCooCoo 434c032f9e Symbols: Direct Selection sets the solid fill and stroke of one object in a dynamic instance
Squashed from #5962 onto main.
2026-11-09 00:26:11 +07:00
dotCooCoo 48a3710fae Reuse selected object locations for large transforms 2026-11-06 09:58:43 +07:00
dotCooCoo a4ca347692 Shaper: dragging a shape out of a Shaper Group's bounds takes it out of the group
Squashed from #4415 onto main.
2026-10-29 15:16:17 +07:00
Dylan M. Taylor 7043ef6f3d Extract geometry command helpers 2026-10-28 16:44:11 +00:00
aiongg 43ae75d4dc refactor(engine): move cmd/object.rs items to cmd/object/{align,arrange,bounds,commands,compound,props,shape,spans,transform}.rs 2026-10-26 22:01:25 +00:00