• Cursors

    A scriptable object that contains a list of different cursors types.
    Asset can be created with the Context menu / Create / New UI Widgets / Cursors.
  • UICursor

    Static class, wrapper for the Cursor.SetCursor() to avoid cursor conflicts between different widgets and components. For example :doc:/components/resizable` component should not change the cursor if currently controlled by the :doc:/components/drag-and-drop` component.

  • CursorDPISelector

    This component selects the most appropriate Cursors asset by Screen.dpi from the available cursors list and sets it as default cursors (UICursor.Cursors).
    Components like Resizable have the Cursors field, so they can have custom cursors to use instead of the default one.

Cursors Fields

  • Default Cursors.Cursor

    Default cursor.

  • Allowed Cursors.Cursor

    Cursor for the allowed actions.

  • Denied Cursors.Cursor

    Cursor for the not allowed actions

  • NorthSouthArrow Cursors.Cursor

    North <-> South arrow.

  • EastWestArrow Cursors.Cursor

    East <-> West arrow.

  • NorthEastSouthWestArrow Cursors.Cursor

    NorthEast <-> SouthWest arrow.

  • NorthWestSouthEastArrow Cursors.Cursor

    NorthWest <-> SouthEast arrow.

  • NorthWestRotateArrow Cursors.Cursor

    North <-> West arrow.

  • NorthEastRotateArrow Cursors.Cursor

    North <-> East arrow.

  • SouthWestRotateArrow Cursors.Cursor

    South <-> West arrow.

  • SouthEastRotateArrow Cursors.Cursor

    South <-> East arrow.

Cursors.Cursor Fields

  • Texture Texture2D

    Cursor texture.

  • Hotspot Vector2

    Cursor hot spot.

UICursor Static Fields

  • Cursors Cursors

    Different default cursors.

  • CanSet Func<Component, bool>

    Is can the specified component set the cursor?
    true if cursor does not have an owner or the owner is the same.
  • Set Action<Component, Cursors.Cursor>

    Set the cursor and current owner.
    The cursor will be changed only if CanSet(owner) returns true.
  • Reset Action<Component>

    Reset cursor and its owner to the default.