Skip to main content

Module delete_selection

Module delete_selection 

Source
Expand description

What the Delete key / Delete command removes for the current selection (every target). THE delete-selection command: what the Delete / Backspace key, the context bar’s Delete entries and MCP selection_delete all run.

One question — what does “delete the selection” mean right now? — answered once (target), then one dispatch (apply) to the delete each kind already has: the same call the row ✕ / menu Delete makes, so the same (no) confirmation and the same single undo step. The modes are exclusive, in the order a user is inside them: an open sketch owns the key, then a 3D sketch, an eCAD editor, an open drawing sheet, a selected PMI annotation; otherwise the 3D selection is an assembly constraint (label-picked), one component (its member solids picked in the view or its BOM row), or one feature (its history-tree row). A sheet or PMI mode with nothing selected deletes nothing — it never falls through to a feature the user cannot see.

Enums§

DeleteTarget
What the delete command acts on.

Functions§

apply
Delete target through the delete its kind already has. Err carries the refusal the row action would have shown.
delete_selection
target then apply; Ok(None) when nothing was deletable.
target
What “delete the selection” means for docs now; None when nothing is deletable.