QgsMapUnitScaleDialog class
A dialog which allows the user to choose the minimum and maximum scale of an object in map units and millimeters.
Contents
This dialog is designed to allow users to edit the properties of a QgsMapUnitScale object.
Constructors, destructors, conversion operators
- QgsMapUnitScaleDialog(QWidget* parent = nullptr)
- Constructor for QgsMapUnitScaleDialog.
Public functions
- auto getMapUnitScale() const -> QgsMapUnitScale
- Returns a QgsMapUnitScale representing the settings shown in the dialog.
- void setMapCanvas(QgsMapCanvas* canvas)
- Sets the map canvas associated with the dialog.
- void setMapUnitScale(const QgsMapUnitScale& scale)
- Updates the dialog to reflect the settings from the specified QgsMapUnitScale object.
Function documentation
QgsMapUnitScaleDialog:: QgsMapUnitScaleDialog(QWidget* parent = nullptr)
Constructor for QgsMapUnitScaleDialog.
| Parameters | |
|---|---|
| parent | parent widget |
QgsMapUnitScale QgsMapUnitScaleDialog:: getMapUnitScale() const
Returns a QgsMapUnitScale representing the settings shown in the dialog.
void QgsMapUnitScaleDialog:: setMapCanvas(QgsMapCanvas* canvas)
Sets the map canvas associated with the dialog.
| Parameters | |
|---|---|
| canvas | map canvas |
This allows the dialog to retrieve the current map scale from the canvas.
void QgsMapUnitScaleDialog:: setMapUnitScale(const QgsMapUnitScale& scale)
Updates the dialog to reflect the settings from the specified QgsMapUnitScale object.
| Parameters | |
|---|---|
| scale | map unit scale to show in dialog |