matplotlib.widgets.SliderBase#

class matplotlib.widgets.SliderBase(ax, orientation, closedmin, closedmax, valmin, valmax, valfmt, dragging, valstep)[source]#

Bases: AxesWidget

The base class for constructing Slider widgets. Not intended for direct usage.

For the slider to remain responsive you must maintain a reference to it.

disconnect(cid)[source]#

Remove the observer with connection id cid.

Parameters:
cidint

Connection id of the observer to be removed.

reset()[source]#

Reset the slider to the initial value.

Examples using matplotlib.widgets.SliderBase#

Image scaling using a RangeSlider

Image scaling using a RangeSlider

Slider

Slider

Snap sliders to discrete values

Snap sliders to discrete values