Skip to content

Commit f660167

Browse files
committed
pass by const ref, fix docstring
1 parent aaf8bcd commit f660167

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+93
-72
lines changed

python/PyQt6/core/auto_generated/geometry/qgsabstractgeometry.sip.in

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -519,15 +519,20 @@ Deletes a vertex within the geometry
519519
.. seealso:: :py:func:`moveVertex`
520520
%End
521521

522-
virtual bool deleteVertices( QList<QgsVertexId> positions ) = 0;
522+
virtual bool deleteVertices( const QList<QgsVertexId> &positions ) = 0;
523523
%Docstring
524-
Deletes vertices within the geometry
524+
Deletes vertices within the geometry If a vertex cannot be deleted, the
525+
method returns ``False`` and the geometry may be left in a partially
526+
modified and invalid state
525527

526528
:param positions: list of vertex ids for vertices to delete
527529

528-
:return: ``True`` if delete was successful
530+
:return: ``True`` if all requested vertices were deleted, ``False`` if a
531+
single vertex could not be deleted
529532

530533
.. seealso:: :py:func:`deleteVertex`
534+
535+
.. versionadded:: 4.0
531536
%End
532537

533538
virtual double length() const;

python/PyQt6/core/auto_generated/geometry/qgscircularstring.sip.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ circular string.
175175

176176
virtual bool deleteVertex( QgsVertexId position );
177177

178-
virtual bool deleteVertices( QList<QgsVertexId> positions );
178+
virtual bool deleteVertices( const QList<QgsVertexId> &positions );
179179

180180
virtual double closestSegment( const QgsPoint &pt, QgsPoint &segmentPt /Out/, QgsVertexId &vertexAfter /Out/, int *leftOf /Out/ = 0, double epsilon = 4 * DBL_EPSILON ) const;
181181

python/PyQt6/core/auto_generated/geometry/qgscompoundcurve.sip.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ Converts the vertex at the given position from/to circular
167167

168168
virtual bool deleteVertex( QgsVertexId position );
169169

170-
virtual bool deleteVertices( QList<QgsVertexId> positions );
170+
virtual bool deleteVertices( const QList<QgsVertexId> &positions );
171171

172172
virtual double closestSegment( const QgsPoint &pt, QgsPoint &segmentPt /Out/, QgsVertexId &vertexAfter /Out/, int *leftOf /Out/ = 0, double epsilon = 4 * DBL_EPSILON ) const;
173173

python/PyQt6/core/auto_generated/geometry/qgscurvepolygon.sip.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ This convention matches the OGC Simple Features specification.
265265

266266
virtual bool deleteVertex( QgsVertexId position );
267267

268-
virtual bool deleteVertices( QList<QgsVertexId> positions );
268+
virtual bool deleteVertices( const QList<QgsVertexId> &positions );
269269

270270

271271
virtual QgsCoordinateSequence coordinateSequence() const;

python/PyQt6/core/auto_generated/geometry/qgsgeometry.sip.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -809,7 +809,7 @@ is index 0)
809809
object to help make the distinction?)
810810
%End
811811

812-
bool deleteVertices( const QList<int> atVertices );
812+
bool deleteVertices( const QList<int> &atVertices );
813813
%Docstring
814814
Deletes vertices at the given positions (first number is index 0)
815815

python/PyQt6/core/auto_generated/geometry/qgsgeometrycollection.sip.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ ownership to the caller.
223223

224224
virtual bool deleteVertex( QgsVertexId position );
225225

226-
virtual bool deleteVertices( QList<QgsVertexId> positions );
226+
virtual bool deleteVertices( const QList<QgsVertexId> &positions );
227227

228228

229229
virtual double length() const /HoldGIL/;

python/PyQt6/core/auto_generated/geometry/qgslinestring.sip.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -728,7 +728,7 @@ approximation of the curve.
728728

729729
virtual bool deleteVertex( QgsVertexId position );
730730

731-
virtual bool deleteVertices( QList<QgsVertexId> positions );
731+
virtual bool deleteVertices( const QList<QgsVertexId> &positions );
732732

733733

734734
virtual QgsLineString *reversed() const /Factory/;

python/PyQt6/core/auto_generated/geometry/qgspoint.sip.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,7 @@ Example
419419

420420
virtual bool deleteVertex( QgsVertexId position );
421421

422-
virtual bool deleteVertices( QList<QgsVertexId> positions );
422+
virtual bool deleteVertices( const QList<QgsVertexId> &positions );
423423

424424

425425
virtual double closestSegment( const QgsPoint &pt, QgsPoint &segmentPt /Out/, QgsVertexId &vertexAfter /Out/, int *leftOf /Out/ = 0, double epsilon = 4 * DBL_EPSILON ) const;

python/PyQt6/core/auto_generated/geometry/qgspolyhedralsurface.sip.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ deleted.
168168

169169
virtual bool deleteVertex( QgsVertexId position );
170170

171-
virtual bool deleteVertices( QList<QgsVertexId> positions );
171+
virtual bool deleteVertices( const QList<QgsVertexId> &positions );
172172

173173

174174
virtual QgsCoordinateSequence coordinateSequence() const;

python/PyQt6/core/auto_generated/geometry/qgstriangle.sip.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ triangle.
9292
Inherited method not used. You cannot delete or insert a vertex
9393
directly. Returns always ``False``.
9494
%End
95-
virtual bool deleteVertices( QList<QgsVertexId> positions );
95+
virtual bool deleteVertices( const QList<QgsVertexId> &positions );
9696

9797
virtual bool insertVertex( QgsVertexId position, const QgsPoint &vertex );
9898

0 commit comments

Comments
 (0)