FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    Cursor

    struct · ferroui-base · v0.5.0

    struct Cursor
    

    Represents a mouse cursor.

    Cursors have reference semantics: two cursors are equal only if they are the same object.

    View source

    Members

    default_cursor

    fn default_cursor() -> Rc<Cursor>
    

    The default cursor: the standard arrow.

    Panics if no cursor factory is registered with the locator.

    Source

    new

    fn new(cursor_type: StandardCursorType) -> Rc<Cursor>
    

    Creates a standard cursor.

    Panics if no cursor factory is registered with the locator.

    Source

    from_bitmap

    fn from_bitmap(cursor: &Bitmap, hot_spot: PixelPoint) -> Rc<Cursor>
    

    Creates a cursor from a bitmap. hot_spot is the position within the bitmap that is the position of the pointer.

    Panics if no cursor factory is registered with the locator.

    Source

    dispose

    fn dispose(self: &Self)
    

    Releases the platform resources of the cursor.

    Source

    parse

    fn parse(s: &str) -> Result<Rc<Cursor>, ParseCursorError>
    

    Creates a standard cursor from the name of its type.

    Panics if no cursor factory is registered with the locator.

    Source

    Trait implementations

    Availability

    Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.