QGIS API Documentation 3.99.0-Master (8e76e220402)
Loading...
Searching...
No Matches
QgsAdvancedDigitizingFloater Class Reference

A widget that floats next to the mouse pointer, and allows interaction with the AdvancedDigitizing feature. More...

#include <qgsadvanceddigitizingfloater.h>

Inheritance diagram for QgsAdvancedDigitizingFloater:

Public Types

enum class  FloaterItem : int {
  XCoordinate = 1 << 1 , YCoordinate = 1 << 2 , MCoordinate = 1 << 3 , ZCoordinate = 1 << 4 ,
  Angle = 1 << 5 , CommonAngleSnapping = 1 << 6 , Distance = 1 << 7 , Bearing = 1 << 8 ,
  Weight = 1 << 9 , Area = 1 << 10 , TotalLength = 1 << 11
}
 Available floater items. More...
typedef QFlags< FloaterItemFloaterItems

Public Slots

void changeWeight (const QString &text)
 Updates the weight value displayed in the floater for NURBSCurve.
void enabledChangedWeight (bool enabled)
 Shows or hides the weight widget in the floater for NURBSCurve.
void focusOnWeight ()
 Requests focus on the weight input field for NURBSCurve.
void setActive (bool active)
 Set whether the floater should be active or not.
void setItemMeasurementType (QgsAdvancedDigitizingFloater::FloaterItem item, Qgis::CadMeasurementDisplayType type)
 Set whether the measurement display type for a floater item.
void setItemVisibility (QgsAdvancedDigitizingFloater::FloaterItem item, bool visible)
 Set whether the floater item should be visible or not.

Public Member Functions

 QgsAdvancedDigitizingFloater (QgsMapCanvas *canvas, QgsAdvancedDigitizingDockWidget *cadDockWidget)
 Create an advanced digitizing floater widget.
bool active ()
 Whether the floater is active or not.
Qgis::CadMeasurementDisplayType itemMeasurementDisplayType (QgsAdvancedDigitizingFloater::FloaterItem item) const
 Returns the measurement display type for a floater item.
bool itemVisibility (QgsAdvancedDigitizingFloater::FloaterItem item) const
 Returns true if the floater item visibility setting is enabled.

Static Public Member Functions

static bool itemSupportsMeasurementType (QgsAdvancedDigitizingFloater::FloaterItem item)
 Returns true if a floater item supports display in different Qgis::CadMeasurementDisplayType values.

Detailed Description

A widget that floats next to the mouse pointer, and allows interaction with the AdvancedDigitizing feature.

It proxies display and actions to QgsMapToolAdvancedDigitizingDockWidget.

Note
This class is a technology preview and unstable API.
Since
QGIS 3.8

Definition at line 42 of file qgsadvanceddigitizingfloater.h.

Member Typedef Documentation

◆ FloaterItems

Member Enumeration Documentation

◆ FloaterItem

Available floater items.

Enumerator
XCoordinate 

X coordinate.

YCoordinate 

Y coordinate.

MCoordinate 

M coordinate.

ZCoordinate 

Z coordinate.

Angle 

Angle between segments.

CommonAngleSnapping 

Common angles.

Distance 

Distance (segment length).

Bearing 

Segment bearing.

Weight 

Weight for NURBSCurve.

Since
QGIS 4.0
Area 

Total area.

Since
QGIS 4.0
TotalLength 

Total length (or perimeter).

Since
QGIS 4.0

Definition at line 48 of file qgsadvanceddigitizingfloater.h.

Constructor & Destructor Documentation

◆ QgsAdvancedDigitizingFloater()

QgsAdvancedDigitizingFloater::QgsAdvancedDigitizingFloater ( QgsMapCanvas * canvas,
QgsAdvancedDigitizingDockWidget * cadDockWidget )
explicit

Create an advanced digitizing floater widget.

Parameters
canvasThe map canvas on which the widget operates
cadDockWidgetThe cadDockWidget to which the floater belongs
Since
QGIS 3.8

Definition at line 33 of file qgsadvanceddigitizingfloater.cpp.

Member Function Documentation

◆ active()

bool QgsAdvancedDigitizingFloater::active ( )

Whether the floater is active or not.

Note that the floater may be active but not visible (e.g. if the mouse is not over the canvas).

Since
QGIS 3.8

Definition at line 190 of file qgsadvanceddigitizingfloater.cpp.

◆ changeWeight

void QgsAdvancedDigitizingFloater::changeWeight ( const QString & text)
slot

Updates the weight value displayed in the floater for NURBSCurve.

Parameters
textThe weight value as a string
Since
QGIS 4.0

Definition at line 699 of file qgsadvanceddigitizingfloater.cpp.

◆ enabledChangedWeight

void QgsAdvancedDigitizingFloater::enabledChangedWeight ( bool enabled)
slot

Shows or hides the weight widget in the floater for NURBSCurve.

Parameters
enabledWhether weight editing is active
Since
QGIS 4.0

Definition at line 704 of file qgsadvanceddigitizingfloater.cpp.

◆ focusOnWeight

void QgsAdvancedDigitizingFloater::focusOnWeight ( )
slot

Requests focus on the weight input field for NURBSCurve.

Since
QGIS 4.0

Definition at line 633 of file qgsadvanceddigitizingfloater.cpp.

◆ itemMeasurementDisplayType()

Qgis::CadMeasurementDisplayType QgsAdvancedDigitizingFloater::itemMeasurementDisplayType ( QgsAdvancedDigitizingFloater::FloaterItem item) const

Returns the measurement display type for a floater item.

If the item does not support measurement types (see itemSupportsMeasurementType()), Qgis::CadMeasurementDisplayType::Hidden will be returned. For these items use itemVisibility() instead.

Since
QGIS 4.0

Definition at line 200 of file qgsadvanceddigitizingfloater.cpp.

◆ itemSupportsMeasurementType()

bool QgsAdvancedDigitizingFloater::itemSupportsMeasurementType ( QgsAdvancedDigitizingFloater::FloaterItem item)
static

Returns true if a floater item supports display in different Qgis::CadMeasurementDisplayType values.

Since
QGIS 4.0

Definition at line 337 of file qgsadvanceddigitizingfloater.cpp.

◆ itemVisibility()

bool QgsAdvancedDigitizingFloater::itemVisibility ( QgsAdvancedDigitizingFloater::FloaterItem item) const

Returns true if the floater item visibility setting is enabled.

Parameters
itemfloater item
Since
QGIS 3.32

Definition at line 195 of file qgsadvanceddigitizingfloater.cpp.

◆ setActive

void QgsAdvancedDigitizingFloater::setActive ( bool active)
slot

Set whether the floater should be active or not.

Note that the floater may be active but not visible (e.g. if the mouse is not over the canvas).

Parameters
active
Since
QGIS 3.8

Definition at line 211 of file qgsadvanceddigitizingfloater.cpp.

◆ setItemMeasurementType

void QgsAdvancedDigitizingFloater::setItemMeasurementType ( QgsAdvancedDigitizingFloater::FloaterItem item,
Qgis::CadMeasurementDisplayType type )
slot

Set whether the measurement display type for a floater item.

Since
QGIS 4.0

Definition at line 266 of file qgsadvanceddigitizingfloater.cpp.

◆ setItemVisibility

void QgsAdvancedDigitizingFloater::setItemVisibility ( QgsAdvancedDigitizingFloater::FloaterItem item,
bool visible )
slot

Set whether the floater item should be visible or not.

Parameters
itemfloater item
visible
Since
QGIS 3.32

Definition at line 220 of file qgsadvanceddigitizingfloater.cpp.


The documentation for this class was generated from the following files: