class Slider(Control)

A Slider is a control that allows a user to select a value by dragging a knob along a scale. The range of values may be either discrete or continuous, and an action may be specified to be invoked whenever the user changes the value.

Constructor

Slider(orient)
Constructs a Slide with the specified orientation, 'h' for horizontal and 'v' for vertical.
Note: On some platforms, the orientation of the slider is determined by its relative width and height; on such platforms, the orient parameter is ignored. For maximum portability, ensure that the dimensions of the control and the orient parameter are in agreement with each other.

Properties

value
The current value of the slider.

min_value
max_value
The minimum and maximum values to which the slider can be set. These default to 0.0 and 1.0.

action
Action to perform when the user changes the value of the slider. See Actions.

ticks
The number of tick marks to display beside the slider, including the ones at each end. If this is set to 0, no tick marks will be displayed. The default is not to show any tick marks.

discrete
If true, the value of the control is constrained to correspond to one of the tick marks specified with the ticks property. If false, the value may be set to anything between the min_value and max_value. The default is false.

live
If true, the slider's action will be invoked continuously while the knob is being dragged. If false, the action will only be invoked when the mouse is released. The default is true.
---