Package limn.backend

Enum Class Cursor

java.lang.Object
java.lang.Enum<Cursor>
limn.backend.Cursor
All Implemented Interfaces:
Serializable, Comparable<Cursor>, Constable

public enum Cursor extends Enum<Cursor>
A standard mouse-cursor shape a widget can request while hovered: the OS's native pointer, so it looks and feels exactly like every other application.

Widgets declare one via Widget.setCursor(limn.backend.Cursor); the scene resolves the hovered widget's cursor (walking up ancestors so a container can set a cursor for its whole subtree) and pushes it to the window through NativeWindow.setCursor(limn.backend.Cursor). DEFAULT is the plain arrow, the fallback when nothing under the pointer requests otherwise.

A shape unsupported by the platform falls back to DEFAULT.

  • Enum Constant Details

    • DEFAULT

      public static final Cursor DEFAULT
      The plain arrow, the default when nothing requests otherwise.
    • POINTER

      public static final Cursor POINTER
      Pointing hand, the "this is clickable" hint (buttons, checkboxes, tabs, links).
    • TEXT

      public static final Cursor TEXT
      I-beam: editable or selectable text (text fields and areas).
    • CROSSHAIR

      public static final Cursor CROSSHAIR
      Crosshair: precise picking/placement.
    • RESIZE_EW

      public static final Cursor RESIZE_EW
      Horizontal (east–west ↔) resize.
    • RESIZE_NS

      public static final Cursor RESIZE_NS
      Vertical (north–south ↕) resize.
    • RESIZE_NESW

      public static final Cursor RESIZE_NESW
      Diagonal (north-east ↔ south-west ⤢) resize.
    • RESIZE_NWSE

      public static final Cursor RESIZE_NWSE
      Diagonal (north-west ↔ south-east ⤡) resize.
    • MOVE

      public static final Cursor MOVE
      Move / resize-all (✥).
    • NOT_ALLOWED

      public static final Cursor NOT_ALLOWED
      Not-allowed (🚫): the action can't happen here.
  • Method Details

    • values

      public static Cursor[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static Cursor valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null