Skip to main content

Cursor

Enum Cursor 

Source
pub enum Cursor {
Show 39 variants Default = 0, Help = 1, Pointer = 2, Progress = 3, Wait = 4, Cell = 5, Crosshair = 6, Text = 7, VerticalText = 8, Alias = 9, Copy = 10, Move = 11, NotAllowed = 12, Grab = 13, Grabbing = 14, ColResize = 15, RowResize = 16, EastWestResize = 17, NorthSouthResize = 18, NorthEastSouthWestResize = 19, NorthWestSouthEastResize = 20, ZoomIn = 21, ZoomOut = 22, UpArrow = 23, Pin = 24, Person = 25, Pen = 26, Cd = 27, PanMiddle = 28, PanMiddleHorizontal = 29, PanMiddleVertical = 30, PanEast = 31, PanNorth = 32, PanNorthEast = 33, PanNorthWest = 34, PanSouth = 35, PanSouthEast = 36, PanSouthWest = 37, PanWest = 38,
}
Expand description

Describes a possible cursor type.

Variants§

§

Default = 0

The platform default cursor. Typically an arrow.

§

Help = 1

A cursor indicating that helpful information is available.

§

Pointer = 2

A cursor indicating that something is clickable, typically a pointing hand.

§

Progress = 3

The program is busy at background but can still interactable. Typically an arrow with a loading indicator.

§

Wait = 4

The program is busy and cannot interact. Typically an hourglass or spinning circle.

§

Cell = 5

Table cell selection cursor

§

Crosshair = 6

Cross cursor typically used for precision selection, e.g. in graphics applications.

§

Text = 7

A horizontal ibeam cursor for indicating text insertion, typically used for text.

§

VerticalText = 8

A vertical ibeam cursor for indicating text insertion, typically used for vertical text.

§

Alias = 9

Cursor for indicating something can be aliased or shortcuted.

§

Copy = 10

Cursor for indicating something can be copied.

§

Move = 11

Crossed arrows for moving something.

§

NotAllowed = 12

Not allowed cursor (typically a circle with a line through it)

§

Grab = 13

Hand cursor for something can be grabbed. e.g. draggable item

§

Grabbing = 14

Hand grabbing cursor.

§

ColResize = 15

Cursor for horizontal resizing (e.g. left-right arrows with a bar in the middle)

§

RowResize = 16

Cursor for vertical resizing (e.g. up-down arrows with a bar in the middle)

§

EastWestResize = 17

Cursor for horizontal resizing (e.g. left-right arrows)

§

NorthSouthResize = 18

Cursor for vertical resizing (e.g. up-down arrows)

§

NorthEastSouthWestResize = 19

Cursor for diagonal resizing (e.g. top-left to bottom-right arrows)

§

NorthWestSouthEastResize = 20

Cursor for diagonal resizing (e.g. top-right to bottom-left arrows)

§

ZoomIn = 21

Cursor for something can be zoomed in. Typically a magnifying glass with a plus sign.

§

ZoomOut = 22

Cursor for something can be zoomed out. Typically a magnifying glass with a minus sign.

§

UpArrow = 23

Windows specific up arrow cursor matching IDC_UPARROW

§

Pin = 24

Windows specific pin cursor matching IDC_PIN

§

Person = 25

Windows specific person cursor matching IDC_PERSON

§

Pen = 26

Windows specific pen cursor matching 32631

§

Cd = 27

Windows specific cd cursor matching 32663

§

PanMiddle = 28

Panning cursors with crossed arrows

§

PanMiddleHorizontal = 29

Panning cursors with horizontal arrows

§

PanMiddleVertical = 30

Panning cursors with vertical arrows

§

PanEast = 31

Panning cursors with a arrow to right.

§

PanNorth = 32

Panning cursors with a arrow to top.

§

PanNorthEast = 33

Panning cursors with arrows to top and right.

§

PanNorthWest = 34

Panning cursors with arrows to top and left.

§

PanSouth = 35

Panning cursors with a arrow to down.

§

PanSouthEast = 36

Panning cursors with arrows to down and right.

§

PanSouthWest = 37

Panning cursors with arrows to down and left.

§

PanWest = 38

Panning cursors with a arrow to left.

Trait Implementations§

Source§

impl<'__de, __Context> BorrowDecode<'__de, __Context> for Cursor

Source§

fn borrow_decode<__D: BorrowDecoder<'__de, Context = __Context>>( decoder: &mut __D, ) -> Result<Self, DecodeError>

Attempt to decode this type with the given BorrowDecode.
Source§

impl Clone for Cursor

Source§

fn clone(&self) -> Cursor

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for Cursor

Source§

impl Debug for Cursor

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<__Context> Decode<__Context> for Cursor

Source§

fn decode<__D: Decoder<Context = __Context>>( decoder: &mut __D, ) -> Result<Self, DecodeError>

Attempt to decode this type with the given Decode.
Source§

impl Default for Cursor

Source§

fn default() -> Cursor

Returns the “default value” for a type. Read more
Source§

impl Encode for Cursor

Source§

fn encode<__E: Encoder>(&self, encoder: &mut __E) -> Result<(), EncodeError>

Encode a given type.
Source§

impl Eq for Cursor

Source§

impl FromPrimitive for Cursor

Source§

fn from_i64(n: i64) -> Option<Self>

Converts an i64 to return an optional value of this type. If the value cannot be represented by this type, then None is returned.
Source§

fn from_u64(n: u64) -> Option<Self>

Converts an u64 to return an optional value of this type. If the value cannot be represented by this type, then None is returned.
Source§

fn from_isize(n: isize) -> Option<Self>

Converts an isize to return an optional value of this type. If the value cannot be represented by this type, then None is returned.
Source§

fn from_i8(n: i8) -> Option<Self>

Converts an i8 to return an optional value of this type. If the value cannot be represented by this type, then None is returned.
Source§

fn from_i16(n: i16) -> Option<Self>

Converts an i16 to return an optional value of this type. If the value cannot be represented by this type, then None is returned.
Source§

fn from_i32(n: i32) -> Option<Self>

Converts an i32 to return an optional value of this type. If the value cannot be represented by this type, then None is returned.
Source§

fn from_i128(n: i128) -> Option<Self>

Converts an i128 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more
Source§

fn from_usize(n: usize) -> Option<Self>

Converts a usize to return an optional value of this type. If the value cannot be represented by this type, then None is returned.
Source§

fn from_u8(n: u8) -> Option<Self>

Converts an u8 to return an optional value of this type. If the value cannot be represented by this type, then None is returned.
Source§

fn from_u16(n: u16) -> Option<Self>

Converts an u16 to return an optional value of this type. If the value cannot be represented by this type, then None is returned.
Source§

fn from_u32(n: u32) -> Option<Self>

Converts an u32 to return an optional value of this type. If the value cannot be represented by this type, then None is returned.
Source§

fn from_u128(n: u128) -> Option<Self>

Converts an u128 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more
Source§

fn from_f32(n: f32) -> Option<Self>

Converts a f32 to return an optional value of this type. If the value cannot be represented by this type, then None is returned.
Source§

fn from_f64(n: f64) -> Option<Self>

Converts a f64 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more
Source§

impl Hash for Cursor

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl PartialEq for Cursor

Source§

fn eq(&self, other: &Cursor) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl StructuralPartialEq for Cursor

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.