IntDragSpinner#

class omni.kit.widget.spinner.IntDragSpinner(
model: ~omni.ui._ui.AbstractValueModel = None,
step: float | int = 1,
min: float | int | None = None,
max: float | int | None = None,
vertical: bool = True,
width: ~omni.ui._ui.Length = 1.000000fr,
style: ~typing.Dict | None = None,
precision: int = 7,
)#

Bases: AbstractSpinner

A spinner widget for integer values with a draggable interface.

This class extends the generic spinner functionality to offer an alternative input method using a draggable integer field. It relies on Omni UI components to maintain consistency in user interface appearance and behavior within Omni UI applications. In contrast to other spinner widgets, this class leverages a drag mechanism to adjust the value, making it suited for rapid and precise modifications.

Example: .. code-block:: python

int_drag_spinner = IntDragSpinner()

Methods

Attributes

__init__(
model: ~omni.ui._ui.AbstractValueModel = None,
step: float | int = 1,
min: float | int | None = None,
max: float | int | None = None,
vertical: bool = True,
width: ~omni.ui._ui.Length = 1.000000fr,
style: ~typing.Dict | None = None,
precision: int = 7,
)#

Initializes the AbstractSpinner object.