Skip to main content

Module selection_handles

Module selection_handles 

Expand description

Selection handles for a canvas: the frame around what is selected, its resize handles at the corners and (once the frame is big enough on screen, or always with SelectionHandles::with_edges) at the middle of each edge, and its rotation handle above (unless SelectionHandles::without_rotation: a crop, a text box, a clip), drawn in your colour and hit-tested at a constant size on screen whatever the zoom.

The frame may be turned (a rotated shape keeps a frame along its own sides), and every drag is answered in the frame’s own axes.

The frame owns no document state. A canvas keeps its selection, asks SelectionHandles::handle_at what a press landed on, and turns the drag into its own action with SelectionHandles::stretch_for or SelectionHandles::rotation_for, so every edit still goes through the canvas’s published vocabulary.

Structs§

SelectionHandles
The frame around a selection, in content coordinates: bounds turned by angle about its centre.

Enums§

Handle
A grip on the selection frame.
ToolFeedback
Feedback over authored canvas content. The contrasting under-stroke keeps a brush footprint or erased boundary visible over either light or dark paint.