Class: QgsRangeSlider¶
- class qgis.gui.QgsRangeSlider¶
Bases:
PyQt5.QtWidgets.QWidget
A slider control with two interactive endpoints, for interactive selection of a range of values.
New in version 3.18.
QgsRangeSlider(parent: QWidget = None) Constructor for
QgsRangeSlider
, with the specifiedparent
widget.QgsRangeSlider(orientation: Qt.Orientation, parent: QWidget = None) Constructor for
QgsRangeSlider
, with the specifiedparent
widget.The
orientation
parameter determines whether the slider is horizontal or vertical.Methods
- param event:
Returns
True
if the slider has its values flipped.- param event:
Returns the lower value for the range selected in the widget.
Returns the maximum value allowed by the widget.
Returns the minimum value allowed by the widget.
- rtype:
QSize
- param event:
- param event:
- param event:
Returns the orientation of the slider.
Returns the page step value for the widget.
- param event:
Sets whether the slider has its values
flipped
.Sets the lower
value
for the range currently selected in the widget.Sets the
maximum
value allowed in the widget.Sets the
minimum
value allowed in the widget.Sets the
orientation
of the slider.Sets the page
step
value for the widget.Sets the current range selected in the widget.
Sets the
minimum
andmaximum
range limits for values allowed in the widget.Sets the single
step
value for the widget.Sets the
interval
for tick marks shown in the widget.Sets the
position
of the tick marks shown in the widget.Sets the upper
value
for the range currently selected in the widget.Returns the single step value for the widget.
- rtype:
QSize
Returns the interval for tick marks shown in the widget.
Returns the position of the tick marks shown in the widget.
Returns the upper value for the range selected in the widget.
Signals
pyqtSignal(*types, name: str = ..., revision: int = ..., arguments: Sequence = ...) -> PYQT_SIGNAL
pyqtSignal(*types, name: str = ..., revision: int = ..., arguments: Sequence = ...) -> PYQT_SIGNAL
- actionEvent(self, QActionEvent)¶
- changeEvent(self, QEvent)¶
- childEvent(self, QChildEvent)¶
- closeEvent(self, QCloseEvent)¶
- connectNotify(self, QMetaMethod)¶
- contextMenuEvent(self, QContextMenuEvent)¶
- create(self, window: PyQt5.sip.voidptr = 0, initializeWindow: bool = True, destroyOldWindow: bool = True)¶
- customEvent(self, QEvent)¶
- destroy(self, destroyWindow: bool = True, destroySubWindows: bool = True)¶
- disconnectNotify(self, QMetaMethod)¶
- dragEnterEvent(self, QDragEnterEvent)¶
- dragLeaveEvent(self, QDragLeaveEvent)¶
- dragMoveEvent(self, QDragMoveEvent)¶
- dropEvent(self, QDropEvent)¶
- enterEvent(self, QEvent)¶
- event(self, event: QEvent) bool ¶
- Parameters:
event (QEvent) –
- Return type:
bool
- flippedDirection(self) bool ¶
Returns
True
if the slider has its values flipped.If this property is
False
(the default), the minimum and maximum will be shown in its classic position for the widget. If the value isTrue
, the minimum and maximum appear at their opposite location.See also
- Return type:
bool
- focusInEvent(self, QFocusEvent)¶
- focusNextChild(self) bool ¶
- focusNextPrevChild(self, bool) bool ¶
- focusOutEvent(self, QFocusEvent)¶
- focusPreviousChild(self) bool ¶
- hideEvent(self, QHideEvent)¶
- initPainter(self, QPainter)¶
- inputMethodEvent(self, QInputMethodEvent)¶
- isSignalConnected(self, QMetaMethod) bool ¶
- keyPressEvent(self, event: QKeyEvent)¶
- Parameters:
event (QKeyEvent) –
- keyReleaseEvent(self, QKeyEvent)¶
- leaveEvent(self, QEvent)¶
- lowerValue(self) int ¶
Returns the lower value for the range selected in the widget.
See also
See also
- Return type:
int
- maximum(self) int ¶
Returns the maximum value allowed by the widget.
See also
See also
- Return type:
int
- metric(self, QPaintDevice.PaintDeviceMetric) int ¶
- minimum(self) int ¶
Returns the minimum value allowed by the widget.
See also
See also
- Return type:
int
- minimumSizeHint(self) QSize ¶
- Return type:
QSize
- mouseDoubleClickEvent(self, QMouseEvent)¶
- mouseMoveEvent(self, event: QMouseEvent)¶
- Parameters:
event (QMouseEvent) –
- mousePressEvent(self, event: QMouseEvent)¶
- Parameters:
event (QMouseEvent) –
- mouseReleaseEvent(self, event: QMouseEvent)¶
- Parameters:
event (QMouseEvent) –
- moveEvent(self, QMoveEvent)¶
- nativeEvent(self, Union[QByteArray, bytes, bytearray], PyQt5.sip.voidptr) Tuple[bool, int] ¶
- orientation(self) Qt.Orientation ¶
Returns the orientation of the slider.
See also
- Return type:
Qt.Orientation
- pageStep(self) int ¶
Returns the page step value for the widget.
This corresponds to the larger increment or decrement applied when the user presses the page increment key (usually PageUp or PageDown).
See also
See also
- Return type:
int
- paintEvent(self, event: QPaintEvent)¶
- Parameters:
event (QPaintEvent) –
- rangeChanged¶
pyqtSignal(*types, name: str = …, revision: int = …, arguments: Sequence = …) -> PYQT_SIGNAL
types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.
- Parameters:
name (str = ...) –
revision (int = ...) –
arguments (Sequence = ...) –
- Return type:
PYQT_SIGNAL
- rangeLimitsChanged¶
pyqtSignal(*types, name: str = …, revision: int = …, arguments: Sequence = …) -> PYQT_SIGNAL
types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.
- Parameters:
name (str = ...) –
revision (int = ...) –
arguments (Sequence = ...) –
- Return type:
PYQT_SIGNAL
- receivers(self, PYQT_SIGNAL) int ¶
- resizeEvent(self, QResizeEvent)¶
- sender(self) QObject ¶
- senderSignalIndex(self) int ¶
- setFlippedDirection(self, flipped: bool)¶
Sets whether the slider has its values
flipped
.If this property is
False
(the default), the minimum and maximum will be shown in its classic position for the widget. If the value isTrue
, the minimum and maximum appear at their opposite location. (i.e. minimum at the bottom of a vertical slider, maximum at the top of a vertical slider).See also
- Parameters:
flipped (bool) –
- setLowerValue(self, value: int)¶
Sets the lower
value
for the range currently selected in the widget.See also
See also
See also
- Parameters:
value (int) –
- setMaximum(self, maximum: int)¶
Sets the
maximum
value allowed in the widget.See also
See also
- Parameters:
maximum (int) –
- setMinimum(self, minimum: int)¶
Sets the
minimum
value allowed in the widget.See also
See also
- Parameters:
minimum (int) –
- setOrientation(self, orientation: Qt.Orientation)¶
Sets the
orientation
of the slider.See also
- Parameters:
orientation (Qt.Orientation) –
- setPageStep(self, step: int)¶
Sets the page
step
value for the widget.This corresponds to the larger increment or decrement applied when the user presses the page increment key (usually PageUp or PageDown).
See also
See also
- Parameters:
step (int) –
- setRange(self, lower: int, upper: int)¶
Sets the current range selected in the widget.
See also
See also
- Parameters:
lower (int) –
upper (int) –
- setRangeLimits(self, minimum: int, maximum: int)¶
Sets the
minimum
andmaximum
range limits for values allowed in the widget.See also
See also
- Parameters:
minimum (int) –
maximum (int) –
- setSingleStep(self, step: int)¶
Sets the single
step
value for the widget.This corresponds to the smaller increment or decrement applied when the user presses an arrow key.
See also
See also
- Parameters:
step (int) –
- setTickInterval(self, interval: int)¶
Sets the
interval
for tick marks shown in the widget.See also
- Parameters:
interval (int) –
- setTickPosition(self, position: QSlider.TickPosition)¶
Sets the
position
of the tick marks shown in the widget.See also
- Parameters:
position (QSlider.TickPosition) –
- setUpperValue(self, value: int)¶
Sets the upper
value
for the range currently selected in the widget.See also
See also
See also
- Parameters:
value (int) –
- showEvent(self, QShowEvent)¶
- singleStep(self) int ¶
Returns the single step value for the widget.
This corresponds to the smaller increment or decrement applied when the user presses an arrow key.
See also
See also
- Return type:
int
- sizeHint(self) QSize ¶
- Return type:
QSize
- tabletEvent(self, QTabletEvent)¶
- tickInterval(self) int ¶
Returns the interval for tick marks shown in the widget.
See also
- Return type:
int
- tickPosition(self) QSlider.TickPosition ¶
Returns the position of the tick marks shown in the widget.
See also
- Return type:
QSlider.TickPosition
- timerEvent(self, QTimerEvent)¶
- updateMicroFocus(self)¶
- upperValue(self) int ¶
Returns the upper value for the range selected in the widget.
See also
See also
- Return type:
int
- wheelEvent(self, QWheelEvent)¶