QGIS API Documentation 3.99.0-Master (d270888f95f)
Loading...
Searching...
No Matches
qgsadvanceddigitizingdockwidget.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsadvanceddigitizingdockwidget.h - dock for CAD tools
3 ----------------------
4 begin : October 2014
5 copyright : (C) Denis Rouzaud
7 ***************************************************************************
8 * *
9 * This program is free software; you can redistribute it and/or modify *
10 * it under the terms of the GNU General Public License as published by *
11 * the Free Software Foundation; either version 2 of the License, or *
12 * (at your option) any later version. *
13 * *
14 ***************************************************************************/
15
16#ifndef QGSADVANCEDDIGITIZINGDOCK
17#define QGSADVANCEDDIGITIZINGDOCK
18
19#include "ui_qgsadvanceddigitizingdockwidgetbase.h"
20
21#include <memory>
22
23#include "qgis_gui.h"
24#include "qgis_sip.h"
26#include "qgsdockwidget.h"
27#include "qgsmessagebaritem.h"
28#include "qgspointlocator.h"
29#include "qgspointxy.h"
30#include "qgssnapindicator.h"
31
32#include <QList>
33#include <QQueue>
34
38class QgsMapCanvas;
39class QgsMapTool;
43
51class GUI_EXPORT QgsAdvancedDigitizingDockWidget : public QgsDockWidget, private Ui::QgsAdvancedDigitizingDockWidgetBase
52{
53 Q_OBJECT
54
55 public:
68 Q_DECLARE_FLAGS( CadCapacities, CadCapacity )
69 Q_FLAG( CadCapacities )
70
71
82
83
90 class GUI_EXPORT CadConstraint
91 {
92 public:
102
110 CadConstraint( QLineEdit *lineEdit, QToolButton *lockerButton, QToolButton *relativeButton = nullptr, QToolButton *repeatingLockButton = nullptr )
111 : mLineEdit( lineEdit )
112 , mLockerButton( lockerButton )
113 , mRelativeButton( relativeButton )
114 , mRepeatingLockButton( repeatingLockButton )
115 {}
116
121 LockMode lockMode() const { return mLockMode; }
122
126 bool isLocked() const { return mLockMode != NoLock; }
127
133 bool isRepeatingLock() const { return mRepeatingLock; }
134
138 bool relative() const { return mRelative; }
139
143 double value() const { return mValue; }
144
148 QLineEdit *lineEdit() const { return mLineEdit; }
149
153 void setLockMode( LockMode mode );
154
161 void setRepeatingLock( bool repeating );
162
166 void setRelative( bool relative );
167
173 void setValue( double value, bool updateWidget = true );
174
179 QString displayValue() const;
180
184 void toggleLocked();
185
189 void toggleRelative();
190
197 int precision() const { return mPrecision; }
198
205 void setPrecision( int precision );
206
211 Qgis::CadConstraintType cadConstraintType() const;
212
217 void setCadConstraintType( Qgis::CadConstraintType constraintType );
218
223 void setMapCanvas( QgsMapCanvas *mapCanvas );
224
229 static QString removeSuffix( const QString &text, Qgis::CadConstraintType constraintType );
230
231
232 private:
233 QLineEdit *mLineEdit = nullptr;
234 QToolButton *mLockerButton = nullptr;
235 QToolButton *mRelativeButton = nullptr;
236 QToolButton *mRepeatingLockButton = nullptr;
237 LockMode mLockMode = NoLock;
238 bool mRepeatingLock = false;
239 bool mRelative = false;
240 double mValue = 0.0;
241 int mPrecision = 6;
243 QgsMapCanvas *mMapCanvas = nullptr;
244 };
245
252 explicit QgsAdvancedDigitizingDockWidget( QgsMapCanvas *canvas, QWidget *parent = nullptr, QgsUserInputWidget *userInputWidget = nullptr );
254
261 bool canvasKeyPressEventFilter( QKeyEvent *e );
262
267 bool applyConstraints( QgsMapMouseEvent *e );
268
274
278 void processCanvasPressEvent( QgsMapMouseEvent *event );
279
283 void processCanvasMoveEvent( QgsMapMouseEvent *event );
284
288 void processCanvasReleaseEvent( QgsMapMouseEvent *event );
289
294 void setTool( QgsAdvancedDigitizingTool *tool );
295
300 QgsAdvancedDigitizingTool *tool() const;
301
306 QgsAdvancedDigitizingFloater *floater() const;
307
312 void releaseLocks( bool releaseRepeatingLocks = true );
313
317 void clear();
318
319 void keyPressEvent( QKeyEvent *e ) override;
320
322 bool cadEnabled() const { return mCadEnabled; }
323
328 void switchZM();
329
334 void setEnabledZ( bool enable );
335
340 void setEnabledM( bool enable );
341
346 bool constructionMode() const { return mConstructionMode; }
347
352 QgsVectorLayer *constructionGuidesLayer() const { return mConstructionGuidesLayer.get(); }
353
358 bool showConstructionGuides() const;
359
364 bool snapToConstructionGuides() const;
365
370 bool recordConstructionGuides() const;
371
376 Qgis::BetweenLineConstraint betweenLineConstraint() const { return mBetweenLineConstraint; }
378 const CadConstraint *constraintAngle() const { return mAngleConstraint.get(); }
380 const CadConstraint *constraintDistance() const { return mDistanceConstraint.get(); }
382 const CadConstraint *constraintX() const { return mXConstraint.get(); }
384 const CadConstraint *constraintY() const { return mYConstraint.get(); }
385
390 const CadConstraint *constraintZ() const { return mZConstraint.get(); }
391
396 const CadConstraint *constraintM() const { return mMConstraint.get(); }
398 bool commonAngleConstraint() const { return !qgsDoubleNear( mCommonAngleConstraint, 0.0 ); }
399
401 const CadConstraint *constraintLineExtension() const { return mLineExtensionConstraint.get(); }
402
404 Qgis::LineExtensionSide lineExtensionSide() const { return mSoftLockLineExtension; }
405
407 const CadConstraint *constraintXyVertex() const { return mXyVertexConstraint.get(); }
408
410 double softLockX() const { return mSoftLockX; }
411
413 double softLockY() const { return mSoftLockY; }
414
419 void toggleConstraintDistance();
420
425 QgsPointLocator::Match mapPointMatch() const { return mSnapMatch; }
426
431 QList<QgsPointLocator::Match> lockedSnapVertices() const { return mLockedSnapVertices; }
432
438 void clearLockedSnapVertices( bool force = true );
439
443 void clearPoints();
444
448 void addPoint( const QgsPointXY &point );
449
454 void removePreviousPoint();
455
460 void updateCurrentPoint( const QgsPoint &point );
461
468 void setPoints( const QList<QgsPointXY> &points );
469
477 QgsPoint currentPointV2( bool *exists = nullptr ) const;
478
484 QgsPoint currentPointLayerCoordinates( QgsMapLayer *layer ) const;
485
492 Q_DECL_DEPRECATED QgsPointXY currentPoint( bool *exists = nullptr ) const SIP_DEPRECATED { return currentPointV2( exists ); };
493
499 QgsPoint previousPointV2( bool *exists = nullptr ) const;
500
507 Q_DECL_DEPRECATED QgsPointXY previousPoint( bool *exists = nullptr ) const SIP_DEPRECATED { return previousPointV2( exists ); };
508
514 QgsPoint penultimatePointV2( bool *exists = nullptr ) const;
515
522 Q_DECL_DEPRECATED QgsPointXY penultimatePoint( bool *exists = nullptr ) const SIP_DEPRECATED { return penultimatePointV2( exists ); };
523
527 inline int pointsCount() const { return mCadPointList.count(); }
528
532 inline bool snappedToVertex() const { return ( mSnapMatch.isValid() && ( mSnapMatch.hasVertex() || mSnapMatch.hasLineEndpoint() ) ); }
533
537 QList<QgsPointXY> snappedSegment() const { return mSnappedSegment; }
538
540 QAction *enableAction() { return mEnableAction; }
541
548 void enable();
549
553 void disable();
554
558 void updateCadPaintItem();
559
568 void setX( const QString &value, WidgetSetMode mode );
569
578 void setY( const QString &value, WidgetSetMode mode );
579
588 void setZ( const QString &value, WidgetSetMode mode );
589
598 void setM( const QString &value, WidgetSetMode mode );
599
608 void setAngle( const QString &value, WidgetSetMode mode );
609
618 void setDistance( const QString &value, WidgetSetMode mode );
619
624 double getLineZ() const;
625
630 double getLineM() const;
631
639 void setWeight( const QString &value, bool enabled );
640
646 QString weight() const;
647
652 CadCapacities capacities() const { return mCapacities; };
653
658 QString formatCommonAngleSnapping( double angle );
659
660 signals:
661
667 void pushWarning( const QString &message );
668
673
681 void pointChangedV2( const QgsPoint &point );
682
690 Q_DECL_DEPRECATED void pointChanged( const QgsPointXY &point ) SIP_DEPRECATED;
691
693
701 void cadEnabledChanged( bool enabled );
702
709 void valueXChanged( const QString &value );
710
717 void valueYChanged( const QString &value );
718
725 void valueZChanged( const QString &value );
726
733 void valueMChanged( const QString &value );
734
741 void valueAngleChanged( const QString &value );
742
749 void valueDistanceChanged( const QString &value );
750
757 void valueBearingChanged( const QString &value );
758
765 void valueWeightChanged( const QString &value );
766
773 void lockXChanged( bool locked );
774
781 void lockYChanged( bool locked );
782
789 void lockZChanged( bool locked );
790
797 void lockMChanged( bool locked );
798
805 void lockAngleChanged( bool locked );
806
813 void lockDistanceChanged( bool locked );
814
823 void relativeXChanged( bool relative );
824
833 void relativeYChanged( bool relative );
834
843 void relativeZChanged( bool relative );
844
853 void relativeMChanged( bool relative );
854
863 void relativeAngleChanged( bool relative );
864
871 void softLockLineExtensionChanged( bool locked );
872
879 void softLockXyChanged( bool locked );
880
881 // relativeDistanceChanged doesn't exist as distance is always relative
882
892 void enabledChangedX( bool enabled );
893
903 void enabledChangedY( bool enabled );
904
914 void enabledChangedZ( bool enabled );
915
925 void enabledChangedM( bool enabled );
926
936 void enabledChangedAngle( bool enabled );
937
947 void enabledChangedDistance( bool enabled );
948
957 void enabledChangedWeight( bool enabled );
958
966
974
982
990
998
1006
1014
1020
1026
1027 private slots:
1029 void betweenLineConstraintClicked( bool activated );
1030
1032 void lockConstraint( bool activate = true );
1033
1035 void lockParameterlessConstraint( bool activate = true );
1036
1041 void constraintTextEdited( const QString &textValue );
1042
1047 void constraintFocusOut();
1048
1050 void setConstraintRelative( bool activate );
1051
1053 void setConstraintRepeatingLock( bool activate );
1054
1059 void activateCad( bool enabled );
1060
1062 void setConstructionMode( bool enabled );
1063
1065 void settingsButtonTriggered( QAction *action );
1066
1067 private:
1071 QgsMapLayer *targetLayer() const;
1072
1074 void setCadEnabled( bool enabled );
1075
1080 void updateCapacity( bool updateUIwithoutChange = false );
1081
1083 void lockBetweenLineConstraint( Qgis::BetweenLineConstraint constraint );
1084
1090 QList<QgsPointXY> snapSegmentToAllLayers( const QgsPointXY &originalMapPoint, bool *snapped = nullptr ) const;
1091
1096 bool filterKeyPress( QKeyEvent *e );
1097
1102 bool eventFilter( QObject *obj, QEvent *event ) override SIP_SKIP;
1103
1105 void triggerMouseMoveEvent();
1106
1108 CadConstraint *objectToConstraint( const QObject *obj ) const;
1109
1111 double parseUserInput( const QString &inputValue, const Qgis::CadConstraintType type, bool &ok ) const;
1112
1119 void updateConstraintValue( CadConstraint *constraint, const QString &textValue, bool convertExpression = false );
1120
1122 void updateUnlockedConstraintValues( const QgsPoint &point );
1123
1129 void toggleLockedSnapVertex( const QgsPointLocator::Match &snapMatch, const QgsPointLocator::Match &previouslySnap );
1130
1134 void resetConstructionGuides();
1135
1140 void updateConstructionGuidesCrs();
1141
1142 QgsMapCanvas *mMapCanvas = nullptr;
1143 QgsUserInputWidget *mUserInputWidget = nullptr;
1144
1145 QgsAdvancedDigitizingCanvasItem *mCadPaintItem = nullptr;
1147 std::unique_ptr<QgsSnapIndicator> mSnapIndicator;
1148
1149 CadCapacities mCapacities = CadCapacities();
1150
1151 bool mCurrentMapToolSupportsCad = false;
1152
1153 // Pointer to the floater
1154 QgsAdvancedDigitizingFloater *mFloater = nullptr;
1155
1156 // CAD properties
1158 bool mCadEnabled = false;
1159 bool mConstructionMode = false;
1160
1161 // constraints
1162 std::unique_ptr<CadConstraint> mAngleConstraint;
1163 std::unique_ptr<CadConstraint> mDistanceConstraint;
1164 std::unique_ptr<CadConstraint> mXConstraint;
1165 std::unique_ptr<CadConstraint> mYConstraint;
1166 std::unique_ptr<CadConstraint> mZConstraint;
1167 std::unique_ptr<CadConstraint> mMConstraint;
1168 std::unique_ptr<CadConstraint> mLineExtensionConstraint;
1169 std::unique_ptr<CadConstraint> mXyVertexConstraint;
1170 Qgis::BetweenLineConstraint mBetweenLineConstraint;
1171 double mCommonAngleConstraint; // if 0: do not snap to common angles
1172
1173 // Weight for NURBS curves (not a constraint, just a value)
1174 QString mWeightValue;
1175 bool mWeightEnabled = false;
1176
1178 bool mSnappingPrioritizeFeatures = false;
1179
1180 // Point list and current snap point / segment
1181 QList<QgsPoint> mCadPointList;
1182 QList<QgsPointXY> mSnappedSegment;
1183
1184 bool mSessionActive = false;
1185
1186 // Construction path history
1187 std::unique_ptr<QgsVectorLayer> mConstructionGuidesLayer;
1188 QgsFeatureId mConstructionGuideId;
1189 QgsLineString mConstructionGuideLine;
1190 bool mDeferredUpdateConstructionGuidesCrs = false;
1191
1192 // Error message
1193 std::unique_ptr<QgsMessageBarItem> mErrorMessage;
1194
1195 // UI
1196 QMap<double, QAction *> mCommonAngleActions; // map the common angle actions with their angle values
1197 QAction *mLineExtensionAction = nullptr;
1198 QAction *mXyVertexAction = nullptr;
1199 QAction *mRecordConstructionGuides = nullptr;
1200 QAction *mShowConstructionGuides = nullptr;
1201 QAction *mSnapToConstructionGuides = nullptr;
1202 QAction *mClearConstructionGuides = nullptr;
1203
1204 // Snap indicator
1205 QgsPointLocator::Match mSnapMatch;
1206 QgsPointLocator::Match mLastSnapMatch;
1207
1208 // Extra constraint context
1209 Qgis::LineExtensionSide mSoftLockLineExtension;
1210 double mSoftLockX;
1211 double mSoftLockY;
1212 QQueue<QgsPointLocator::Match> mLockedSnapVertices;
1213
1214 // Advanced digitizing tool
1215 QPointer<QgsAdvancedDigitizingTool> mCurrentTool;
1216
1217#ifdef SIP_RUN
1219 bool eventFilter( QObject *obj, QEvent *event );
1220#endif
1222 QgsPoint pointXYToPoint( const QgsPointXY &point ) const;
1223
1224 QMenu *mCommonAngleActionsMenu = nullptr;
1225 QMenu *mFloaterActionsMenu = nullptr;
1226
1227 /* Store whether the target layer supports Z and M, to avoid unnecessary checks
1228 * when floater settings are changed */
1229 bool mTargetLayerSupportsZ = false;
1230 bool mTargetLayerSupportsM = false;
1231
1232 static const QgsSettingsEntryBool *settingsCadSnappingPriorityPrioritizeFeature;
1233 static const QgsSettingsEntryBool *settingsCadRecordConstructionGuides;
1234 static const QgsSettingsEntryBool *settingsCadShowConstructionGuides;
1235 static const QgsSettingsEntryBool *settingsCadSnapToConstructionGuides;
1236
1239};
1240
1242
1243#endif // QGSADVANCEDDIGITIZINGDOCK_H
CadConstraintType
Advanced digitizing constraint type.
Definition qgis.h:4133
@ Generic
Generic value.
Definition qgis.h:4134
BetweenLineConstraint
Between line constraints which can be enabled.
Definition qgis.h:4107
LineExtensionSide
Designates whether the line extension constraint is currently soft locked with the previous or next v...
Definition qgis.h:4120
Draws the graphical elements of the CAD tools (.
The CadConstraint is a class for all basic constraints (angle/distance/x/y).
CadConstraint(QLineEdit *lineEdit, QToolButton *lockerButton, QToolButton *relativeButton=nullptr, QToolButton *repeatingLockButton=nullptr)
Constructor for CadConstraint.
bool isLocked() const
Is any kind of lock mode enabled.
bool isRepeatingLock() const
Returns true if a repeating lock is set for the constraint.
LockMode lockMode() const
The current lock mode of this constraint.
int precision() const
Returns the numeric precision (decimal places) to show in the associated widget.
bool relative() const
Is the constraint in relative mode.
QLineEdit * lineEdit() const
The line edit that manages the value of the constraint.
A dockable widget used to handle the CAD tools on top of a selection of map tools.
void valueDistanceChanged(const QString &value)
Emitted whenever the distance value changes (either the mouse moved, or the user changed the input).
bool commonAngleConstraint() const
Returns true if a constraint on a common angle is active.
Q_DECL_DEPRECATED QgsPointXY currentPoint(bool *exists=nullptr) const
The last point.
QgsAdvancedDigitizingDockWidget(QgsMapCanvas *canvas, QWidget *parent=nullptr, QgsUserInputWidget *userInputWidget=nullptr)
Create an advanced digitizing dock widget.
void lockZChanged(bool locked)
Emitted whenever the Z parameter is locked.
double softLockY() const
Returns the Y value of the Y soft lock. The value is NaN is the constraint isn't magnetized to a line...
const CadConstraint * constraintM() const
Returns the CadConstraint on the M coordinate.
void enabledChangedY(bool enabled)
Emitted whenever the Y field is enabled or disabled.
QAction * enableAction()
Returns the action used to enable/disable the tools.
bool cadEnabled() const
determines if CAD tools are enabled or if map tools behaves "nomally"
void valueWeightChanged(const QString &value)
Emitted whenever the weight value changes for NURBS curves.
void enabledChangedWeight(bool enabled)
Emitted whenever the weight field is enabled or disabled for NURBS curves.
int pointsCount() const
The number of points in the CAD point helper list.
QList< QgsPointXY > snappedSegment() const
Snapped to a segment.
void relativeMChanged(bool relative)
Emitted whenever the M parameter is toggled between absolute and relative.
void lockXChanged(bool locked)
Emitted whenever the X parameter is locked.
void softLockLineExtensionChanged(bool locked)
Emitted whenever the soft line extension parameter is locked.
void focusOnXRequested()
Emitted whenever the X field should get the focus using the shortcuts (X).
bool constructionMode() const
Returns whether the construction mode is activated.
void enabledChangedX(bool enabled)
Emitted whenever the X field is enabled or disabled.
void valueYChanged(const QString &value)
Emitted whenever the Y value changes (either the mouse moved, or the user changed the input).
Q_DECL_DEPRECATED QgsPointXY penultimatePoint(bool *exists=nullptr) const
The penultimate point.
const CadConstraint * constraintLineExtension() const
Returns the CadConstraint.
void focusOnWeightRequested()
Emitted whenever the weight field should get the focus using the shortcuts (W).
void focusOnYRequested()
Emitted whenever the Y field should get the focus using the shortcuts (Y).
void enabledChangedDistance(bool enabled)
Emitted whenever the distance field is enabled or disabled.
bool snappedToVertex() const
Is it snapped to a vertex.
void valueZChanged(const QString &value)
Emitted whenever the Z value changes (either the mouse moved, or the user changed the input).
QList< QgsPointLocator::Match > lockedSnapVertices() const
Returns the snap matches whose vertices have been locked.
QgsPoint previousPointV2(bool *exists=nullptr) const
The previous point.
void lockAngleChanged(bool locked)
Emitted whenever the angle parameter is locked.
QgsPoint penultimatePointV2(bool *exists=nullptr) const
The penultimate point.
void pointChangedV2(const QgsPoint &point)
Sometimes a constraint may change the current point out of a mouse event.
void commonAngleSnappingShowInFloaterChanged(bool enabled)
Emitted whenever the option to show common angle snapping in the floater changes.
void relativeXChanged(bool relative)
Emitted whenever the X parameter is toggled between absolute and relative.
void focusOnAngleRequested()
Emitted whenever the angle field should get the focus using the shortcuts (A).
WidgetSetMode
Type of interaction to simulate when editing values from external widget.
const CadConstraint * constraintXyVertex() const
Returns the CadConstraint.
void focusOnZRequested()
Emitted whenever the Z field should get the focus using the shortcuts (Z).
void focusOnMRequested()
Emitted whenever the M field should get the focus using the shortcuts (M).
void popWarning()
Remove any previously emitted warnings (if any).
void valueXChanged(const QString &value)
Emitted whenever the X value changes (either the mouse moved, or the user changed the input).
void lockMChanged(bool locked)
Emitted whenever the M parameter is locked.
void cadEnabledChanged(bool enabled)
Signals for external widgets that need to update according to current values.
void lockYChanged(bool locked)
Emitted whenever the Y parameter is locked.
const CadConstraint * constraintY() const
Returns the CadConstraint on the Y coordinate.
void valueAngleChanged(const QString &value)
Emitted whenever the angle value changes (either the mouse moved, or the user changed the input).
void valueMChanged(const QString &value)
Emitted whenever the M value changes (either the mouse moved, or the user changed the input).
QgsVectorLayer * constructionGuidesLayer() const
Returns the vector layer within which construction guides are stored.
void relativeZChanged(bool relative)
Emitted whenever the Z parameter is toggled between absolute and relative.
double softLockX() const
Returns the X value of the X soft lock. The value is NaN is the constraint isn't magnetized to a line...
Q_DECL_DEPRECATED void pointChanged(const QgsPointXY &point)
Sometimes a constraint may change the current point out of a mouse event.
CadCapacity
The CadCapacity enum defines the possible constraints to be set depending on the number of points in ...
@ RelativeAngle
Also for parallel and perpendicular.
@ RelativeCoordinates
This corresponds to distance and relative coordinates.
Qgis::BetweenLineConstraint betweenLineConstraint() const
Returns the between line constraints which are used to place perpendicular/parallel segments to snapp...
void enabledChangedAngle(bool enabled)
Emitted whenever the angle field is enabled or disabled.
Q_DECL_DEPRECATED QgsPointXY previousPoint(bool *exists=nullptr) const
The previous point.
void enabledChangedZ(bool enabled)
Emitted whenever the Z field is enabled or disabled.
void lockDistanceChanged(bool locked)
Emitted whenever the distance parameter is locked.
void relativeAngleChanged(bool relative)
Emitted whenever the angleX parameter is toggled between absolute and relative.
const CadConstraint * constraintX() const
Returns the CadConstraint on the X coordinate.
CadCapacities capacities() const
Returns the capacities.
void softLockXyChanged(bool locked)
Emitted whenever the soft x/y extension parameter is locked.
const CadConstraint * constraintZ() const
Returns the CadConstraint on the Z coordinate.
void valueBearingChanged(const QString &value)
Emitted whenever the bearing value changes.
void enabledChangedM(bool enabled)
Emitted whenever the M field is enabled or disabled.
QgsPointLocator::Match mapPointMatch() const
Returns the point locator match.
QgsPoint currentPointV2(bool *exists=nullptr) const
The last point.
void focusOnDistanceRequested()
Emitted whenever the distance field should get the focus using the shortcuts (D).
const CadConstraint * constraintAngle() const
Returns the CadConstraint on the angle.
void valueCommonAngleSnappingChanged(double angle)
Emitted whenever the snapping to common angle option changes, angle = 0 means that the functionality ...
void pushWarning(const QString &message)
Push a warning.
Qgis::LineExtensionSide lineExtensionSide() const
Returns on which side of the constraint line extension point, the line was created.
const CadConstraint * constraintDistance() const
Returns the CadConstraint on the distance.
void relativeYChanged(bool relative)
Emitted whenever the Y parameter is toggled between absolute and relative.
A widget that floats next to the mouse pointer, and allows interaction with the AdvancedDigitizing fe...
An abstract class for advanced digitizing tools.
QgsDockWidget(QWidget *parent=nullptr, Qt::WindowFlags flags=Qt::WindowFlags())
Constructor for QgsDockWidget.
Line string geometry type, with support for z-dimension and m-values.
Map canvas is a class for displaying all GIS data types on a canvas.
Base class for all map layer types.
Definition qgsmaplayer.h:83
A mouse event which is the result of a user interaction with a QgsMapCanvas.
A QgsMapTool which gives events directly in map coordinates and allows filtering of events.
Abstract base class for all map tools.
Definition qgsmaptool.h:72
Represents a 2D point.
Definition qgspointxy.h:62
Point geometry type, with support for z-dimension and m-values.
Definition qgspoint.h:53
A boolean settings entry.
A floating widget that can be used to display widgets for user inputs.
Represents a vector layer which manages a vector based dataset.
bool qgsDoubleNear(double a, double b, double epsilon=4 *std::numeric_limits< double >::epsilon())
Compare two doubles (but allow some difference).
Definition qgis.h:6900
#define SIP_DEPRECATED
Definition qgis_sip.h:114
#define SIP_ENUM_BASETYPE(type)
Definition qgis_sip.h:275
#define SIP_SKIP
Definition qgis_sip.h:134
qint64 QgsFeatureId
64 bit feature ids negative numbers are used for uncommitted/newly added features
Q_DECLARE_OPERATORS_FOR_FLAGS(QgsProjectionSelectionWidget::CrsOptions)