Enum Class PointerEvents

java.lang.Object
java.lang.Enum<PointerEvents>
com.oorian.css.PointerEvents
All Implemented Interfaces:
Serializable, Comparable<PointerEvents>, Constable

public enum PointerEvents extends Enum<PointerEvents>
CSS pointer-events property values for controlling pointer interactions.

The pointer-events property sets whether an element reacts to pointer events (such as clicks and hovers). When set to none, the element becomes invisible to pointer events.

Common Values:

  • auto: Element reacts to pointer events normally (default)
  • none: Element does not react to pointer events
  • visiblePainted: SVG only - reacts when painted
  • visibleFill: SVG only - reacts when fill is visible
  • visibleStroke: SVG only - reacts when stroke is visible

Usage:


 overlay.setPointerEvents(PointerEvents.NONE);
 button.setPointerEvents(PointerEvents.AUTO);
 
Since:
2024
Version:
1.0
Author:
Marvin P. Warble Jr.
See Also:
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    SVG only: always reacts to pointer events.
    Element reacts to pointer events normally (default).
    SVG only: reacts when fill is set (regardless of visibility).
    Inherits from parent element.
    Sets to default value.
    Element does not react to pointer events.
    SVG only: reacts when painted (regardless of visibility).
    Rolls back to the value defined by a previous cascade origin.
    Rolls back to the value defined in the previous cascade layer.
    SVG only: reacts when stroke is set (regardless of visibility).
    Resets the property to its inherited value or initial value.
    SVG only: reacts when visibility is visible.
    SVG only: reacts when visibility is visible and has fill.
    SVG only: reacts when visibility is visible and painted.
    SVG only: reacts when visibility is visible and has stroke.
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the CSS value string.
    Returns the CSS value string.
    Returns the enum constant of this class with the specified name.
    static PointerEvents[]
    Returns an array containing the constants of this enum class, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • AUTO

      public static final PointerEvents AUTO
      Element reacts to pointer events normally (default).
    • NONE

      public static final PointerEvents NONE
      Element does not react to pointer events.
    • VISIBLE_PAINTED

      public static final PointerEvents VISIBLE_PAINTED
      SVG only: reacts when visibility is visible and painted.
    • VISIBLE_FILL

      public static final PointerEvents VISIBLE_FILL
      SVG only: reacts when visibility is visible and has fill.
    • VISIBLE_STROKE

      public static final PointerEvents VISIBLE_STROKE
      SVG only: reacts when visibility is visible and has stroke.
    • VISIBLE

      public static final PointerEvents VISIBLE
      SVG only: reacts when visibility is visible.
    • PAINTED

      public static final PointerEvents PAINTED
      SVG only: reacts when painted (regardless of visibility).
    • FILL

      public static final PointerEvents FILL
      SVG only: reacts when fill is set (regardless of visibility).
    • STROKE

      public static final PointerEvents STROKE
      SVG only: reacts when stroke is set (regardless of visibility).
    • ALL

      public static final PointerEvents ALL
      SVG only: always reacts to pointer events.
    • INITIAL

      public static final PointerEvents INITIAL
      Sets to default value.
    • INHERIT

      public static final PointerEvents INHERIT
      Inherits from parent element.
    • UNSET

      public static final PointerEvents UNSET
      Resets the property to its inherited value or initial value.
    • REVERT

      public static final PointerEvents REVERT
      Rolls back to the value defined by a previous cascade origin.
    • REVERT_LAYER

      public static final PointerEvents REVERT_LAYER
      Rolls back to the value defined in the previous cascade layer.
  • Method Details

    • values

      public static PointerEvents[] 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 PointerEvents 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
    • getValue

      public String getValue()
      Returns the CSS value string.
      Returns:
      the CSS value
    • toString

      public String toString()
      Returns the CSS value string.
      Overrides:
      toString in class Enum<PointerEvents>
      Returns:
      the CSS value