Skip to content

Commit 90f7989

Browse files
committedFeb 7, 2019
Move QGIS 3 todos to QGIS 4
1 parent 6c1036c commit 90f7989

13 files changed

+43
-43
lines changed
 

‎python/core/auto_generated/qgscoordinatereferencesystem.sip.in

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ If no prefix is specified, WKT definition is assumed.
191191
:param definition: A String containing a coordinate reference system definition.
192192

193193
.. seealso:: :py:func:`createFromString`
194-
/ // TODO QGIS 3: remove "POSTGIS" and "INTERNAL", allow PROJ4 without the prefix
194+
/ // TODO QGIS 4: remove "POSTGIS" and "INTERNAL", allow PROJ4 without the prefix
195195
%End
196196

197197
explicit QgsCoordinateReferenceSystem( long id, CrsType type = PostgisCrsId );
@@ -205,7 +205,7 @@ Constructor a CRS object using a PostGIS SRID, an EPSG code or an internal QGIS
205205

206206
:param id: The ID valid for the chosen CRS ID type
207207
:param type: One of the types described in CrsType
208-
/ // TODO QGIS 3: remove type and always use EPSG code
208+
/ // TODO QGIS 4: remove type and always use EPSG code
209209
%End
210210

211211
QgsCoordinateReferenceSystem( const QgsCoordinateReferenceSystem &srs );
@@ -304,7 +304,7 @@ Sets this CRS by lookup of the given ID in the CRS database.
304304

305305
We encourage you to use EPSG code, WKT or Proj4 to describe CRS's in your code
306306
wherever possible. Internal QGIS CRS IDs are not guaranteed to be permanent / involatile.
307-
/ // TODO QGIS 3: remove type and always use EPSG code, rename to createFromEpsg
307+
/ // TODO QGIS 4: remove type and always use EPSG code, rename to createFromEpsg
308308
%End
309309

310310
bool createFromOgcWmsCrs( const QString &crs );
@@ -322,7 +322,7 @@ and refer to QGIS internal CRS IDs.
322322
this method uses an internal cache. Call invalidateCache() to clear the cache.
323323

324324
.. seealso:: :py:func:`fromOgcWmsCrs`
325-
/ // TODO QGIS 3: remove "QGIS" and "CUSTOM", only support "USER" (also returned by authid())
325+
/ // TODO QGIS 4: remove "QGIS" and "CUSTOM", only support "USER" (also returned by authid())
326326
%End
327327

328328
bool createFromSrid( long srid );
@@ -332,7 +332,7 @@ Sets this CRS by lookup of the given PostGIS SRID in the CRS database.
332332
:param srid: The PostGIS SRID for the desired spatial reference system.
333333

334334
:return: True on success else false
335-
/ // TODO QGIS 3: remove unless really necessary - let's use EPSG codes instead
335+
/ // TODO QGIS 4: remove unless really necessary - let's use EPSG codes instead
336336
%End
337337

338338
bool createFromWkt( const QString &wkt );
@@ -500,7 +500,7 @@ pieces of information about CRS.
500500
The ellipsoid and projection acronyms must be set as well as the proj4string!
501501

502502
:return: long the SrsId of the matched CRS, zero if no match was found
503-
/ // TODO QGIS 3: seems completely obsolete now (only compares proj4 - already done in createFromProj4)
503+
/ // TODO QGIS 4: seems completely obsolete now (only compares proj4 - already done in createFromProj4)
504504
%End
505505

506506
bool operator==( const QgsCoordinateReferenceSystem &srs ) const;
@@ -543,7 +543,7 @@ Returns the internal CRS ID, if available.
543543
Returns PostGIS SRID for the CRS.
544544

545545
:return: the PostGIS spatial_ref_sys identifier for this CRS (defaults to 0)
546-
/ // TODO QGIS 3: remove unless really necessary - let's use EPSG codes instead
546+
/ // TODO QGIS 4: remove unless really necessary - let's use EPSG codes instead
547547
%End
548548

549549
QString authid() const;

‎python/core/auto_generated/qgsvectorlayertools.sip.in

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ This method should/will be called, whenever a new feature will be added to the l
3838
:return: - True in case of success, False if the operation failed/was aborted
3939
- feature: Updated feature after adding will be written back to this
4040

41-
TODO QGIS 3: remove const qualifier
41+
TODO QGIS 4: remove const qualifier
4242
%End
4343

4444
virtual bool startEditing( QgsVectorLayer *layer ) const = 0;
@@ -51,7 +51,7 @@ If successful layer->startEditing() will be called and true returned.
5151

5252
:return: True, if the editing session was started
5353

54-
TODO QGIS 3: remove const qualifier
54+
TODO QGIS 4: remove const qualifier
5555
%End
5656

5757
virtual bool stopEditing( QgsVectorLayer *layer, bool allowCancel = true ) const = 0;
@@ -64,7 +64,7 @@ Appropriate dialogs should be shown like
6464

6565
:return: True if successful
6666

67-
TODO QGIS 3: remove const qualifier
67+
TODO QGIS 4: remove const qualifier
6868
%End
6969

7070
virtual bool saveEdits( QgsVectorLayer *layer ) const = 0;
@@ -75,7 +75,7 @@ Should be called, when the features should be committed but the editing session
7575

7676
:return: True if successful
7777

78-
TODO QGIS 3: remove const qualifier
78+
TODO QGIS 4: remove const qualifier
7979
%End
8080

8181
virtual bool copyMoveFeatures( QgsVectorLayer *layer, QgsFeatureRequest &request /In,Out/, double dx = 0, double dy = 0, QString *errorMsg /Out/ = 0 ) const;
@@ -90,7 +90,7 @@ Copy and move features with defined translation.
9090
:return: - True if all features could be copied.
9191
- errorMsg: If given, it will contain the error message
9292

93-
TODO QGIS 3: remove const qualifier
93+
TODO QGIS 4: remove const qualifier
9494
%End
9595

9696
};

‎src/core/geometry/qgsgeometry.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -585,7 +585,7 @@ class CORE_EXPORT QgsGeometry
585585
* \param sqrDist will be set to the square distance between the closest vertex and the specified point
586586
* \returns closest point in geometry. If not found (empty geometry), returns null point nad sqrDist is negative.
587587
*/
588-
//TODO QGIS 3.0 - rename beforeVertex to previousVertex, afterVertex to nextVertex
588+
//TODO QGIS 4.0 - rename beforeVertex to previousVertex, afterVertex to nextVertex
589589
QgsPointXY closestVertex( const QgsPointXY &point, int &atVertex SIP_OUT, int &beforeVertex SIP_OUT, int &afterVertex SIP_OUT, double &sqrDist SIP_OUT ) const;
590590

591591
/**

‎src/core/qgscoordinatereferencesystem.h

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ class CORE_EXPORT QgsCoordinateReferenceSystem
223223
* If no prefix is specified, WKT definition is assumed.
224224
* \param definition A String containing a coordinate reference system definition.
225225
* \see createFromString()
226-
*/ // TODO QGIS 3: remove "POSTGIS" and "INTERNAL", allow PROJ4 without the prefix
226+
*/ // TODO QGIS 4: remove "POSTGIS" and "INTERNAL", allow PROJ4 without the prefix
227227
explicit QgsCoordinateReferenceSystem( const QString &definition );
228228

229229
/**
@@ -232,7 +232,7 @@ class CORE_EXPORT QgsCoordinateReferenceSystem
232232
* wherever possible. Internal QGIS CRS IDs are not guaranteed to be permanent / involatile.
233233
* \param id The ID valid for the chosen CRS ID type
234234
* \param type One of the types described in CrsType
235-
*/ // TODO QGIS 3: remove type and always use EPSG code
235+
*/ // TODO QGIS 4: remove type and always use EPSG code
236236
explicit QgsCoordinateReferenceSystem( long id, CrsType type = PostgisCrsId );
237237

238238
//! Copy constructor
@@ -310,7 +310,7 @@ class CORE_EXPORT QgsCoordinateReferenceSystem
310310
* \returns True on success else false
311311
* \note We encourage you to use EPSG code, WKT or Proj4 to describe CRS's in your code
312312
* wherever possible. Internal QGIS CRS IDs are not guaranteed to be permanent / involatile.
313-
*/ // TODO QGIS 3: remove type and always use EPSG code, rename to createFromEpsg
313+
*/ // TODO QGIS 4: remove type and always use EPSG code, rename to createFromEpsg
314314
bool createFromId( long id, CrsType type = PostgisCrsId );
315315

316316
/**
@@ -322,14 +322,14 @@ class CORE_EXPORT QgsCoordinateReferenceSystem
322322
* \returns True on success else false
323323
* \note this method uses an internal cache. Call invalidateCache() to clear the cache.
324324
* \see fromOgcWmsCrs()
325-
*/ // TODO QGIS 3: remove "QGIS" and "CUSTOM", only support "USER" (also returned by authid())
325+
*/ // TODO QGIS 4: remove "QGIS" and "CUSTOM", only support "USER" (also returned by authid())
326326
bool createFromOgcWmsCrs( const QString &crs );
327327

328328
/**
329329
* Sets this CRS by lookup of the given PostGIS SRID in the CRS database.
330330
* \param srid The PostGIS SRID for the desired spatial reference system.
331331
* \returns True on success else false
332-
*/ // TODO QGIS 3: remove unless really necessary - let's use EPSG codes instead
332+
*/ // TODO QGIS 4: remove unless really necessary - let's use EPSG codes instead
333333
bool createFromSrid( long srid );
334334

335335
/**
@@ -450,7 +450,7 @@ class CORE_EXPORT QgsCoordinateReferenceSystem
450450
* pieces of information about CRS.
451451
* \note The ellipsoid and projection acronyms must be set as well as the proj4string!
452452
* \returns long the SrsId of the matched CRS, zero if no match was found
453-
*/ // TODO QGIS 3: seems completely obsolete now (only compares proj4 - already done in createFromProj4)
453+
*/ // TODO QGIS 4: seems completely obsolete now (only compares proj4 - already done in createFromProj4)
454454
long findMatchingProj();
455455

456456
/**
@@ -507,7 +507,7 @@ class CORE_EXPORT QgsCoordinateReferenceSystem
507507
/**
508508
* Returns PostGIS SRID for the CRS.
509509
* \returns the PostGIS spatial_ref_sys identifier for this CRS (defaults to 0)
510-
*/ // TODO QGIS 3: remove unless really necessary - let's use EPSG codes instead
510+
*/ // TODO QGIS 4: remove unless really necessary - let's use EPSG codes instead
511511
long postgisSrid() const;
512512

513513
/**

‎src/core/qgspallabeling.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ class CORE_EXPORT QgsPalLayerSettings
132132
/**
133133
* Placement modes which determine how label candidates are generated for a feature.
134134
*/
135-
//TODO QGIS 3.0 - move to QgsLabelingEngine
135+
//TODO QGIS 4.0 - move to QgsLabelingEngine
136136
enum Placement
137137
{
138138
AroundPoint, //!< Arranges candidates in a circle around a point (or centroid of a polygon). Applies to point or polygon layers only.
@@ -146,7 +146,7 @@ class CORE_EXPORT QgsPalLayerSettings
146146
};
147147

148148
//! Positions for labels when using the QgsPalLabeling::OrderedPositionsAroundPoint placement mode
149-
//TODO QGIS 3.0 - move to QgsLabelingEngine
149+
//TODO QGIS 4.0 - move to QgsLabelingEngine
150150
enum PredefinedPointPosition
151151
{
152152
TopLeft, //!< Label on top-left of point
@@ -167,7 +167,7 @@ class CORE_EXPORT QgsPalLayerSettings
167167
* Behavior modifier for label offset and distance, only applies in some
168168
* label placement modes.
169169
*/
170-
//TODO QGIS 3.0 - move to QgsLabelingEngine
170+
//TODO QGIS 4.0 - move to QgsLabelingEngine
171171
enum OffsetType
172172
{
173173
FromPoint, //!< Offset distance applies from point geometry
@@ -177,7 +177,7 @@ class CORE_EXPORT QgsPalLayerSettings
177177
/**
178178
* Line placement flags, which control how candidates are generated for a linear feature.
179179
*/
180-
//TODO QGIS 3.0 - move to QgsLabelingEngine, rename to LinePlacementFlag, use Q_DECLARE_FLAGS to make
180+
//TODO QGIS 4.0 - move to QgsLabelingEngine, rename to LinePlacementFlag, use Q_DECLARE_FLAGS to make
181181
//LinePlacementFlags type, and replace use of pal::LineArrangementFlag
182182
enum LinePlacementFlags
183183
{
@@ -233,7 +233,7 @@ class CORE_EXPORT QgsPalLayerSettings
233233
* Valid obstacle types, which affect how features within the layer will act as obstacles
234234
* for labels.
235235
*/
236-
//TODO QGIS 3.0 - Move to QgsLabelingEngine
236+
//TODO QGIS 4.0 - Move to QgsLabelingEngine
237237
enum ObstacleType
238238
{
239239
PolygonInterior, /*!< avoid placing labels over interior of polygon (prefer placing labels totally

‎src/core/qgsproject.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -859,7 +859,7 @@ class CORE_EXPORT QgsProject : public QObject, public QgsExpressionContextGenera
859859
* \see removeMapLayer()
860860
* \see removeAllMapLayers()
861861
*/
862-
//TODO QGIS 3.0 - add PyName alias to avoid list type conversion error
862+
//TODO QGIS 4.0 - add PyName alias to avoid list type conversion error
863863
void removeMapLayers( const QList<QgsMapLayer *> &layers );
864864

865865
/**
@@ -1285,7 +1285,7 @@ class CORE_EXPORT QgsProject : public QObject, public QgsExpressionContextGenera
12851285
* layerWillBeRemoved() signals will still be emitted following this signal.
12861286
* You can use this signal to do easy (and fast) cleanup.
12871287
*/
1288-
//TODO QGIS 3.0 - rename to past tense
1288+
//TODO QGIS 4.0 - rename to past tense
12891289
void removeAll();
12901290

12911291
/**

‎src/core/qgsvectorlayertools.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ class CORE_EXPORT QgsVectorLayerTools : public QObject
5252
* \param feature Updated feature after adding will be written back to this
5353
* \returns True in case of success, False if the operation failed/was aborted
5454
*
55-
* TODO QGIS 3: remove const qualifier
55+
* TODO QGIS 4: remove const qualifier
5656
*/
5757
virtual bool addFeature( QgsVectorLayer *layer, const QgsAttributeMap &defaultValues = QgsAttributeMap(), const QgsGeometry &defaultGeometry = QgsGeometry(), QgsFeature *feature SIP_OUT = nullptr ) const = 0;
5858

@@ -65,7 +65,7 @@ class CORE_EXPORT QgsVectorLayerTools : public QObject
6565
*
6666
* \returns True, if the editing session was started
6767
*
68-
* TODO QGIS 3: remove const qualifier
68+
* TODO QGIS 4: remove const qualifier
6969
*/
7070
virtual bool startEditing( QgsVectorLayer *layer ) const = 0;
7171

@@ -77,7 +77,7 @@ class CORE_EXPORT QgsVectorLayerTools : public QObject
7777
* \param allowCancel True if a cancel button should be offered
7878
* \returns True if successful
7979
*
80-
* TODO QGIS 3: remove const qualifier
80+
* TODO QGIS 4: remove const qualifier
8181
*/
8282
virtual bool stopEditing( QgsVectorLayer *layer, bool allowCancel = true ) const = 0;
8383

@@ -87,7 +87,7 @@ class CORE_EXPORT QgsVectorLayerTools : public QObject
8787
* \param layer The layer to commit
8888
* \returns True if successful
8989
*
90-
* TODO QGIS 3: remove const qualifier
90+
* TODO QGIS 4: remove const qualifier
9191
*/
9292
virtual bool saveEdits( QgsVectorLayer *layer ) const = 0;
9393

@@ -101,7 +101,7 @@ class CORE_EXPORT QgsVectorLayerTools : public QObject
101101
* \param errorMsg If given, it will contain the error message
102102
* \returns True if all features could be copied.
103103
*
104-
* TODO QGIS 3: remove const qualifier
104+
* TODO QGIS 4: remove const qualifier
105105
*/
106106
virtual bool copyMoveFeatures( QgsVectorLayer *layer, QgsFeatureRequest &request SIP_INOUT, double dx = 0, double dy = 0, QString *errorMsg SIP_OUT = nullptr ) const;
107107

‎src/gui/attributetable/qgsattributetablemodel.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ class GUI_EXPORT QgsAttributeTableModel: public QAbstractTableModel
224224
/**
225225
* Gets the the feature request
226226
*/
227-
// TODO QGIS 3: return copy instead of reference
227+
// TODO QGIS 4: return copy instead of reference
228228
const QgsFeatureRequest &request() const;
229229

230230
/**

‎src/gui/editorwidgets/core/qgssearchwidgetwrapper.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ class GUI_EXPORT QgsSearchWidgetWrapper : public QgsWidgetWrapper
179179
* \returns filter expression
180180
* \since QGIS 2.16
181181
*/
182-
// TODO QGIS 3.0 - make pure virtual
182+
// TODO QGIS 4.0 - make pure virtual
183183
virtual QString createExpression( FilterFlags flags ) const { Q_UNUSED( flags ); return QStringLiteral( "TRUE" ); }
184184

185185
/**

‎src/gui/qgsattributeform.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,21 +78,21 @@ class GUI_EXPORT QgsAttributeForm : public QWidget
7878
* Hides the button box (OK/Cancel) and enables auto-commit
7979
* \note set Embed in QgsAttributeEditorContext in constructor instead
8080
*/
81-
// TODO QGIS 3.0 - make private
81+
// TODO QGIS 4.0 - make private
8282
void hideButtonBox();
8383

8484
/**
8585
* Shows the button box (OK/Cancel) and disables auto-commit
8686
* \note set Embed in QgsAttributeEditorContext in constructor instead
8787
*/
88-
// TODO QGIS 3.0 - make private
88+
// TODO QGIS 4.0 - make private
8989
void showButtonBox();
9090

9191
/**
9292
* Disconnects the button box (OK/Cancel) from the accept/resetValues slots
9393
* If this method is called, you have to create these connections from outside
9494
*/
95-
// TODO QGIS 3.0 - make private
95+
// TODO QGIS 4.0 - make private
9696
void disconnectButtonBox();
9797

9898
/**

‎src/gui/qgsmapcanvas.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ email : sherman at mrcc.com
7676
* Deprecated to be deleted, stuff from here should be moved elsewhere.
7777
* \note not available in Python bindings
7878
*/
79-
//TODO QGIS 3.0 - remove
79+
//TODO QGIS 4.0 - remove
8080
class QgsMapCanvas::CanvasProperties
8181
{
8282
public:

‎src/gui/qgsmaptoolcapture.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ class GUI_EXPORT QgsMapToolCapture : public QgsMapToolAdvancedDigitizing
121121
* 1 if the current layer is null or not a vector layer
122122
* 2 if the transformation failed
123123
*/
124-
// TODO QGIS 3.0 returns an enum instead of a magic constant
124+
// TODO QGIS 4.0 returns an enum instead of a magic constant
125125
int nextPoint( const QgsPoint &mapPoint, QgsPoint &layerPoint );
126126

127127
/**
@@ -134,7 +134,7 @@ class GUI_EXPORT QgsMapToolCapture : public QgsMapToolAdvancedDigitizing
134134
* 1 if the current layer is null or not a vector layer
135135
* 2 if the transformation failed
136136
*/
137-
// TODO QGIS 3.0 returns an enum instead of a magic constant
137+
// TODO QGIS 4.0 returns an enum instead of a magic constant
138138
int nextPoint( QPoint p, QgsPoint &layerPoint, QgsPoint &mapPoint );
139139

140140
/**
@@ -143,7 +143,7 @@ class GUI_EXPORT QgsMapToolCapture : public QgsMapToolAdvancedDigitizing
143143
* \returns 0 in case of success, 1 if not applicable (CRS mismatch), 2 in case of failure
144144
* \since QGIS 2.14
145145
*/
146-
// TODO QGIS 3.0 returns an enum instead of a magic constant
146+
// TODO QGIS 4.0 returns an enum instead of a magic constant
147147
int fetchLayerPoint( const QgsPointLocator::Match &match, QgsPoint &layerPoint );
148148

149149
/**
@@ -175,7 +175,7 @@ class GUI_EXPORT QgsMapToolCapture : public QgsMapToolAdvancedDigitizing
175175
* Adds a point to the rubber band (in map coordinates) and to the capture list (in layer coordinates)
176176
* \returns 0 in case of success, 1 if current layer is not a vector layer, 2 if coordinate transformation failed
177177
*/
178-
// TODO QGIS 3.0 returns an enum instead of a magic constant
178+
// TODO QGIS 4.0 returns an enum instead of a magic constant
179179
int addVertex( const QgsPointXY &point );
180180

181181
/**

‎src/gui/raster/qgsrasterrendererwidget.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ class GUI_EXPORT QgsRasterRendererWidget: public QWidget
3939

4040
public:
4141

42-
//TODO QGIS 3.0 - remove extent parameter, replace with map canvas parameter
42+
//TODO QGIS 4.0 - remove extent parameter, replace with map canvas parameter
4343
QgsRasterRendererWidget( QgsRasterLayer *layer, const QgsRectangle &extent )
4444
: mRasterLayer( layer )
4545
, mExtent( extent )

0 commit comments

Comments
 (0)