Skip to content

SpinBox

Properties

  • enabled: (in bool): Defaults to true. You can’t interact with the spinbox if enabled is false.
  • has-focus: (out bool): Set to true when the spinbox currently has the focus
  • value (in-out int): The value. Defaults to the minimum.
  • minimum (in int): The minimum value (default: 0).
  • maximum (in int): The maximum value (default: 100).
  • step-size (in int): The size that is used on increment or decrement of value (default: 1).

Callbacks

  • edited(int): Emitted when the value has changed because the user modified it

Example

import { SpinBox } from "std-widgets.slint";
export component Example inherits Window {
width: 200px;
height: 25px;
SpinBox {
width: parent.width;
height: parent.height;
value: 42;
}
}