mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-10-24 09:46:59 -06:00
The drawing modes help page (https://helpx.adobe.com/illustrator/desktop/draw-shapes-and-paths/learn-drawing-basics/drawing-modes-overview.html) has you draw or paste into the selected object in Draw Inside. The isolation help page (https://helpx.adobe.com/illustrator/desktop/manage-objects/select-objects/isolate-objects.html) isolates a path, group or object on a double-click with the Selection tool, and puts art added in isolation mode where the isolated art was once the mode ends, so that art belongs with what is isolated. Steps: select a path, choose Draw Inside, double-click the path with the Selection tool (it is isolated), then draw or paste. The art went into the clip group Draw Inside makes around the path, but isolation mode stayed on the bare path, so the new art was outside it: drawn dimmed, passed through by clicks and marquees, and a double-click on it selected the path and never entered the clip group. Double-clicking an existing Draw Inside clip group from outside isolation mode already isolated it, and pastes then went inside it; that is unchanged. Cause: create::insert_look_turned and edit::paste_clip put the art into create::draw_inside_group's clip group but left DocState::isolation on the object drawn into, and with a single object isolated, hit testing reaches only that object. Change: when the object drawn into is the isolated one, isolation moves to its clip group (create::isolate_draw_inside_group), after new art and after Draw Inside pastes. A drag's previews replay from its snapshot and make the group under the same id, and cancelling the drag restores the isolation it began with. Undo and redo end isolation mode when the isolated object is no longer in the document (the undone clip group), as mask editing already does, instead of keeping an id a later object may take. Verification: drawing_inside_an_isolated_object_keeps_the_new_art_in_isolation_mode fails without the change (isolation Some(NodeId(2)) instead of the clip group Some(NodeId(6))). A whole-window egui run through the control channel's ui.click/ui.drag (double-click the rectangle, drag an ellipse inside, paste, click the copy) left isolation on the rectangle and the click selected the rectangle before; after, isolation is on the clip group and the click selects the copy.