Class: QgsScaleVisibilityDialog¶
- class qgis.gui.QgsScaleVisibilityDialog¶
Bases:
PyQt5.QtWidgets.QDialog
A dialog allowing users to enter a scale visibility range.
QgsScaleVisibilityDialog(parent: Optional[QWidget] = None, title: Optional[str] = ‘’, mapCanvas: Optional[QgsMapCanvas] = None) Constructor for
QgsScaleVisibilityDialog
, with specified dialogtitle
. ThemapCanvas
argument can be used to associate the dialog with a map canvas, allowing use of the current map scale within the dialog.Methods
Returns
True
if scale based visibility is enabled.Returns the selected maximum scale, or 0 if maximum scale is not set.
Returns the selected minimum scale, or 0 if minimum scale is not set.
Set the maximum
scale
, or 0 to indicate the minimum is not set.Set the minimum
scale
, or 0 to indicate the minimum is not set.Set whether scale based visibility is enabled.
Set whether scale based visibility is enabled.
- actionEvent(self, a0: QActionEvent | None)¶
- changeEvent(self, a0: QEvent | None)¶
- childEvent(self, a0: QChildEvent | None)¶
- closeEvent(self, a0: QCloseEvent | None)¶
- connectNotify(self, signal: QMetaMethod)¶
- contextMenuEvent(self, a0: QContextMenuEvent | None)¶
- create(self, window: PyQt5.sip.voidptr = None, initializeWindow: bool = True, destroyOldWindow: bool = True)¶
- customEvent(self, a0: QEvent | None)¶
- destroy(self, destroyWindow: bool = True, destroySubWindows: bool = True)¶
- disconnectNotify(self, signal: QMetaMethod)¶
- dragEnterEvent(self, a0: QDragEnterEvent | None)¶
- dragLeaveEvent(self, a0: QDragLeaveEvent | None)¶
- dragMoveEvent(self, a0: QDragMoveEvent | None)¶
- dropEvent(self, a0: QDropEvent | None)¶
- enterEvent(self, a0: QEvent | None)¶
- event(self, a0: QEvent | None) bool ¶
- eventFilter(self, a0: QObject | None, a1: QEvent | None) bool ¶
- focusInEvent(self, a0: QFocusEvent | None)¶
- focusNextChild(self) bool ¶
- focusNextPrevChild(self, next: bool) bool ¶
- focusOutEvent(self, a0: QFocusEvent | None)¶
- focusPreviousChild(self) bool ¶
- hasScaleVisibility(self) bool ¶
Returns
True
if scale based visibility is enabled.- Return type:
bool
- hideEvent(self, a0: QHideEvent | None)¶
- initPainter(self, painter: QPainter | None)¶
- inputMethodEvent(self, a0: QInputMethodEvent | None)¶
- isSignalConnected(self, signal: QMetaMethod) bool ¶
- keyPressEvent(self, a0: QKeyEvent | None)¶
- keyReleaseEvent(self, a0: QKeyEvent | None)¶
- leaveEvent(self, a0: QEvent | None)¶
- maximumScale(self) float ¶
Returns the selected maximum scale, or 0 if maximum scale is not set. The scale value indicates the scale denominator, e.g. 1000.0 for a 1:1000 map.
See also
See also
- Return type:
float
- metric(self, a0: QPaintDevice.PaintDeviceMetric) int ¶
- minimumScale(self) float ¶
Returns the selected minimum scale, or 0 if minimum scale is not set. The scale value indicates the scale denominator, e.g. 1000.0 for a 1:1000 map.
See also
See also
- Return type:
float
- mouseDoubleClickEvent(self, a0: QMouseEvent | None)¶
- mouseMoveEvent(self, a0: QMouseEvent | None)¶
- mousePressEvent(self, a0: QMouseEvent | None)¶
- mouseReleaseEvent(self, a0: QMouseEvent | None)¶
- moveEvent(self, a0: QMoveEvent | None)¶
- nativeEvent(self, eventType: QByteArray | bytes | bytearray, message: PyQt5.sip.voidptr | None)¶
- paintEvent(self, a0: QPaintEvent | None)¶
- receivers(self, signal: PYQT_SIGNAL) int ¶
- resizeEvent(self, a0: QResizeEvent | None)¶
- sender(self) QObject | None ¶
- senderSignalIndex(self) int ¶
- setMaximumScale(self, scale: float)¶
Set the maximum
scale
, or 0 to indicate the minimum is not set. The scale value indicates the scale denominator, e.g. 1000.0 for a 1:1000 map.See also
See also
- Parameters:
scale (float)
- setMinimumScale(self, scale: float)¶
Set the minimum
scale
, or 0 to indicate the minimum is not set. The scale value indicates the scale denominator, e.g. 1000.0 for a 1:1000 map.See also
See also
- Parameters:
scale (float)
- setScaleVisibility(self, hasScaleVisibility: bool)¶
Set whether scale based visibility is enabled.
See also
Added in version 3.38.
- Parameters:
hasScaleVisibility (bool)
- setScaleVisiblity(self, hasScaleVisibility: bool)¶
Set whether scale based visibility is enabled.
See also
Deprecated since version Use:
setScaleVisibility()
- Parameters:
hasScaleVisibility (bool)
- showEvent(self, a0: QShowEvent | None)¶
- tabletEvent(self, a0: QTabletEvent | None)¶
- timerEvent(self, a0: QTimerEvent | None)¶
- updateMicroFocus(self)¶
- wheelEvent(self, a0: QWheelEvent | None)¶