Class Cursor
Represents a cursor with position in screen coordinates and shape.
public record Cursor : IEquatable<Cursor>
- Inheritance
-
Cursor
- Implements
- Inherited Members
Remarks
The position is always in screen coordinates. Views are responsible for converting from their content-area or viewport coordinates to screen coordinates before setting the cursor.
Immutable value type - use with 'with' expression to modify:
Cursor newCursor = currentCursor with { Position = new Point(5, 0) };
To hide the cursor, set Position to null or set the Style property to Hidden.
Constructors
Properties
- IsVisible
Gets whether the cursor is visible (has valid position).
- Position
Gets the cursor position in screen coordinates.
- Style
Gets the cursor style.
Methods
- ToString()
Returns string representation for debugging.