Nyall Dawson
01e3e1dddc
[api] Move QgsGeometry enums to Qgis, promote to enum classes
2021-08-04 09:54:32 +10:00
Harrissou Sant-anna
5bbae769d7
Fix QgsPoint code samples
2021-07-21 10:17:37 +10:00
Nyall Dawson
c8156b0106
Add c++20 todo for replacing equality operators with default implementations
2021-07-02 12:19:58 +10:00
Nyall Dawson
711a615be3
Fix raises sphinx format
2021-06-25 10:50:04 +10:00
Even Rouault
8a6ed7d8f9
Address -Woverloaded-virtual clang virtual and enable the warning
2021-06-25 06:37:49 +10:00
Olivier Dalang
527042ee1d
[convert to curve] style
...
# Conflicts:
# src/app/vertextool/qgsvertextool.cpp
2021-06-19 06:24:13 +10:00
Olivier Dalang
2c69acabe5
[convert to curve] PR review
2021-06-19 06:24:13 +10:00
Olivier Dalang
9739e07c38
[convert to curve] avancement
2021-06-19 06:24:13 +10:00
Olivier Dalang
351df3ef9f
[convert to curve] avancement
2021-06-19 06:24:13 +10:00
Nyall Dawson
480c2ebd65
Better docs and examples for QgsGeometryEngine class
2021-06-17 07:11:47 +10:00
Harrissou Sant-anna
636d5cc43d
Use better reference to distance methods whether it's 3D or not
2021-06-14 05:09:18 +10:00
Nyall Dawson
4ff3f447dc
Don't try to insert links in raises blocks in PyQGIS docs
...
These aren't formatted correctly if we do
2021-06-10 11:03:43 +10:00
Nyall Dawson
8359281012
Fix formatting of exception blocks in PyQGIS docs
2021-06-10 11:03:43 +10:00
Loïc Bartoletti
ba409e0832
readd qgsgeometry method
2021-06-09 10:45:40 +10:00
Loïc Bartoletti
da7c614f1a
sipify
2021-06-09 10:45:40 +10:00
Loïc Bartoletti
65392c2329
fix sip; add method using QgsGeometry, add tests, revert missing convertTo/add
2021-06-09 10:45:40 +10:00
Loïc Bartoletti
7c0f3a1f6c
sipify
2021-06-09 10:45:40 +10:00
Loïc Bartoletti
da7c8fa04e
sipify
2021-06-09 10:45:40 +10:00
Nyall Dawson
ae83444c9f
Expand on QgsPoint/QgsPointXY documentation to clarify when each
...
class should be used
Fixes #43598
2021-06-08 18:47:01 +10:00
Loïc Bartoletti
17d1443ace
is2DClosed -> isClosed2D and fix a typo
2021-06-08 14:26:20 +10:00
Loïc Bartoletti
df02c00f13
sipify
2021-06-08 14:26:20 +10:00
Denis Rouzaud
35c557a234
run sipify
2021-05-26 14:30:54 +02:00
Nyall Dawson
60f48bc6a2
Add typehint for QgsPoint constructor ( #43385 )
2021-05-25 15:20:59 +02:00
Nyall Dawson
615bbd8163
Fix SIP_HOLDGIL annotations
2021-05-25 21:07:50 +10:00
Nyall Dawson
2b6c3c1db2
Fix PyQGIS QgsLineString constructor only accepts lists of QgsPoint,
...
not QgsPointXY as indicated by the documentation
Also add support for constructing QgsLineString using arrays of
arrays of floats, given that we're having to hand-roll sip conversion
code anyway!
Now the following is supported:
line = QgsLineString([[1,2], [3,4], [5,6]])
which is much nicer and more "pythonic" then the explicit
QgsPoint/QgsPointXY sequences!
Fixes #43200
2021-05-25 21:07:50 +10:00
Nyall Dawson
adab3fe6a1
Dox
2021-05-24 10:11:37 +10:00
Nyall Dawson
0d768faa43
Add QgsAbstractGeometry::simplifiedTypeRef
...
Returns a reference to the simplest lossless representation of this geometry,
e.g. if the geometry is a multipart geometry type with a single member geometry,
a reference to that part will be returned.
This method employs the following logic:
- For multipart geometries containing a single part only a direct reference to that part will be returned.
- For compound curve geometries containing a single curve only a direct reference to that curve will be returned.
This method returns a reference only, and does not involve any geometry cloning.
2021-05-24 10:11:37 +10:00
Nyall Dawson
928e3ee2fe
Dox
2021-05-05 06:57:58 +10:00
Nyall Dawson
2f77f6f015
Dox++
2021-05-05 06:57:58 +10:00
Nyall Dawson
755182c134
Expose more geos methods
2021-05-05 06:57:58 +10:00
Loïc Bartoletti
0a48e804c8
dox++
2021-04-29 11:15:34 +10:00
Loïc Bartoletti
24dba98ab2
fix DocCoverage and Doxygen
2021-04-29 11:15:34 +10:00
Loïc Bartoletti
e837b6f5b5
deprecate and replace setZValueFromPoints by transferFirstZValuteToPoint
2021-04-29 11:15:34 +10:00
Loïc Bartoletti
95cff79cec
replace setMValueFromPoints by transferFirstMValuteToPoint
2021-04-29 11:15:34 +10:00
Loïc Bartoletti
4231134f78
add a warning
2021-04-29 11:15:34 +10:00
Loïc Bartoletti
dcfa1bd02d
Update setMValueFromPoints dox
2021-04-29 11:15:34 +10:00
Loïc Bartoletti
9e81011908
Adds setMValueFromPoints
2021-04-29 11:15:34 +10:00
Nyall Dawson
f22c63ec77
Rely on upstream GEOS makevalid algorithm for GEOS 3.9+
...
No point having our own internal fork of this code now that it's
included (and more importantly, maintained) upstream!
2021-04-29 08:45:25 +10:00
Nyall Dawson
1c11a91811
Add QgsGeometry::normalize()
...
A port of the equivalent method from GEOS, but with added support
for curved geometries and M values
Reorganizes the geometry into a normalized form (or "canonical" form).
Polygon rings will be rearranged so that their starting vertex is
the lower left and ring orientation follows the right hand rule, collections
are ordered by geometry type, and other normalization techniques are applied.
The resultant geometry will be geometrically equivalent to the original geometry.
2021-04-29 05:33:25 +10:00
Nyall Dawson
e3a73a1ac5
Add method to "scroll" the vertices of a closed curve geometry,
...
so that a particular vertex is the first one
2021-04-29 05:33:25 +10:00
Nyall Dawson
417d444429
Add api to condense compound curves by merging adjacent parts of the
...
same type to single parts
2021-04-28 11:15:17 +10:00
Nyall Dawson
bab01b1b75
Dox ++
2021-04-27 21:13:22 +10:00
Nyall Dawson
9c53fb8635
Add QgsAbstractGeometry::compareTo( QgsAbstractGeometry*)
...
Allows for comparison of geometry objects, e.g. to allow for stable
sorting of them.
Ported from the GEOS equivalent method, but with addition of support
for M values and curved geometry types
2021-04-27 21:13:22 +10:00
Nyall Dawson
36e52f8514
Add method to split QgsCurve geometries into two parts at a specific
...
vertex index
2021-04-27 19:15:51 +10:00
Nyall Dawson
a9a6e38665
Add QgsCircularString::append( const QgsCircularString* )
...
Appends the contents of one circular string to the end of another
2021-04-27 19:15:33 +10:00
Nyall Dawson
1c94f6b941
Dox++
2021-04-27 14:53:20 +10:00
Nyall Dawson
063f2ee852
Add optimised method to create QgsCircularString direct from coordinate
...
arrays
2021-04-27 14:53:20 +10:00
Nyall Dawson
729792d981
Add QgsCurve::indexOf to retrieve index of a specified QgsPoint
...
within the curve
2021-04-27 11:26:49 +10:00
Nyall Dawson
9c4375b4c7
Add QgsGeometry::isAxisParallelRectangle for checking whether
...
a geometry is a axis-parallel rectangle
Credit to @stefanuhrig
2021-04-24 06:25:02 +10:00
Denis Rouzaud
ba8a445850
run sipify
2021-03-22 21:13:52 +01:00