pub enum Cursor {
}Expand description
The pointer’s shape over a piece (the .cursor() decorator, docs/cursor.md).
The named variants are the CSS cursor vocabulary: the largest set any toolkit accepts as it
is (GTK and the DOM take the names verbatim), and every other toolkit’s set is a subset of it
or maps onto it. A backend draws its own shape for each name, or the nearest one it has, and
answers Cap::Cursor with how faithful that is. Cursor::Native reaches a shape only one
toolkit names; the day::cursor::<toolkit> modules carry those as constants, gated on that
toolkit’s feature, and every other backend ignores a name it does not know.
A cursor applies to the node and its descendants until a descendant sets its own.
Cursor::Default hands the shape back to the platform rather than pinning an arrow, so a
reactive cursor can release what it took.
Variants§
Default
The platform default (an arrow), and the value that releases a node’s cursor.
Pointer
A pointing hand: links and other tap-to-activate content.
Text
An I-beam over editable or selectable text.
VerticalText
An I-beam for vertical text.
Crosshair
Move
Four-way move.
Grab
An open hand: content that can be dragged.
Grabbing
A closed hand: content being dragged.
NotAllowed
Wait
The app is busy and cannot take input.
Progress
The app is busy but still takes input.
Help
ContextMenu
Copy
A drop will copy.
Alias
A drop will link.
Cell
A table cell.
ZoomIn
ZoomOut
None
No pointer at all.
NsResize
Vertical (north–south) resize.
EwResize
Horizontal (east–west) resize.
NeswResize
Diagonal resize, north-east to south-west.
NwseResize
Diagonal resize, north-west to south-east.
ColResize
RowResize
Native(Cow<'static, str>)
A toolkit’s own named cursor, resolved by that backend’s lookup and ignored by every
other. Prefer the day::cursor::<toolkit> constants, which are gated on the toolkit.