Isolation mode: double-clicking a single object isolates it

With Double Click To Isolate on, the Selection tool isolated groups only. A
double-click on a single path, compound path, image, mesh or placed file now
isolates it too, as the public documentation describes. Type still switches to
the Type tool; blends, envelopes, repeats and symbol instances keep their own
editing modes.

While a single object is isolated only it is hit, marqueed and taken by Select
All, new art goes beside it in its group or layer, and a double-click on the
empty canvas leaves with it selected. object.isolate accepts any object except
type.
This commit is contained in:
Ayberk A.
2026-10-12 18:56:41 +07:00
committed by bflatastic
parent 412e83c825
commit 3073f0ab03
9 changed files with 104 additions and 15 deletions
+2 -1
View File
@@ -193,7 +193,8 @@ pub fn specs() -> Vec<CommandSpec> {
fn selectable(d: &Document, iso: Option<NodeId>) -> Vec<NodeId> {
match iso.and_then(|i| d.node(i)) {
Some(c) if d.ancestry(c.id).is_some_and(|a| a.iter().all(|i| d.node(*i).is_some_and(|n| n.visible && !n.locked && !n.is_template()))) => {
c.layer_art(true)
// A single object isolated is all there is to select.
if c.is_container() { c.layer_art(true) } else { vec![c.id] }
}
Some(_) => vec![],
None => d.selectable_art(),