Nyall Dawson
afccd31720
Add method to add a linestring to compound curves where we extend
...
the existing final part if it's a linestring and the newly added
curve is also a linestring, instead of adding a whole new curve
2021-03-05 04:28:31 +10:00
Nyall Dawson
6ab4ecfa58
Another attempt
2021-02-25 11:08:56 +10:00
Nyall Dawson
73658c5910
Fix mac build
2021-02-25 11:08:56 +10:00
Nyall Dawson
bd82925df3
Replace qgis::make_unique with std::make_unique
...
Now that we require c++14 features, we don't need to use the custom
backported version anymore...
2021-02-25 11:08:56 +10:00
Nyall Dawson
d007901f14
Allow QgsRectangle constructors to bypass the automatic normalization
...
step, when they know in advance they are already normalized
This step isn't free, and can add up when many rectangles are
constructed
2021-02-23 16:02:06 +10:00
Nyall Dawson
7dfef3a0b1
Newer doxygen versions don't auto convert the first line in a class'
...
documentation to a brief note, so we have to do it explicitly...
2021-02-19 08:15:29 +10:00
Loïc Bartoletti
e336b831c2
Remove automagic fix and tiny refacto
2021-02-13 09:25:19 +10:00
Loïc Bartoletti
7e7732218b
Add a message if a geometry was fixed
2021-02-13 09:25:19 +10:00
Nyall Dawson
6f4b32f658
Create class QgsAbstractGeometryTransformer, which can be used
...
to transform the vertices of a QgsAbstractGeometry
E.g.
class Transformer(QgsAbstractGeometryTransformer):
def transformPoint(self, x, y, z, m):
return True, x * 2, y + 1, z, m
transformer = Transformer()
g = QgsGeometry.fromWkt('LineString(3 0, 10 0, 10 10)')
g.get().transform(transformer)
print(g.asWkt()) # 'LineString (6 1, 20 1, 20 11)'
2021-02-08 12:12:53 +10:00
Nyall Dawson
50b9beaad6
[sipify] Catch more class references and insert :py:class: annotations
2021-01-31 05:41:22 +10:00
Harrissou Sant-anna
8a8d2a2c66
Fix some formatting in pyQGIS doc
2021-01-30 08:25:03 +10:00
Belgacem
f362eab3d8
fix indentation
2021-01-13 15:47:40 +01:00
Belgacem
0167d07eaa
fix tests
2021-01-13 15:47:40 +01:00
Belgacem
be88fff95c
add some QgsRay3D tests
2021-01-13 15:47:40 +01:00
Belgacem
2c9c6f94b9
fix somethings and testRayFromScreenPoint
2021-01-13 15:47:40 +01:00
Belgacem
fa7e3d4f7d
fix sip and add Nyall suggestions
2021-01-13 15:47:40 +01:00
Belgacem
59bb58f880
cleanup and fix symbol nullptr bug
2021-01-13 15:47:40 +01:00
Belgacem
0073c35b65
remove distanceFromPoint
2021-01-13 15:47:40 +01:00
Belgacem
a97ade0e88
address reviews
2021-01-13 15:47:40 +01:00
Belgacem
432f29be92
add pointsLimit and SIP
2021-01-13 15:47:40 +01:00
Belgacem
4f3f95a841
raycast intersection with node bounding box
2021-01-13 15:47:40 +01:00
Loïc Bartoletti
817744928c
Fix circle by three tangents parrallel when two are parallels ( #40702 )
...
* add new method to solve QgsCircle::from3tangents where 2 tangents are parallels
2020-12-23 09:00:15 +10:00
Nyall Dawson
932e70b247
Dox grammar
2020-12-14 08:51:51 +10:00
Loïc Bartoletti
fe80965d50
[API] Add angleBisector method
2020-12-07 08:40:59 +10:00
Loïc Bartoletti
d6ac6c4029
Fix since version for bisector method
2020-12-02 19:46:13 +10:00
Loïc Bartoletti
0f292cfb36
[API] Improve isValid method for curve type
2020-12-02 06:32:54 +10:00
Loïc Bartoletti
5f36925189
[API] Add asGml methods to QgsCircle
2020-12-02 06:32:00 +10:00
Loïc Bartoletti
25e14ee766
add python binding
2020-11-28 08:11:54 +10:00
Nyall Dawson
13e8d45fed
Add signal for when project preset full extent is changed
2020-11-24 04:44:19 +10:00
Even Rouault
af9da65c23
Add QgsLayerItem::iconForWkbType() and QgsWkbTypes::translatedDisplayString()
...
and use them to avoid a lot of copy&paste in "New layer XXXX" dialogs and
providers.
2020-11-12 10:19:55 +10:00
tschmetzer
df0950c6e6
Rename variables for a more intuitive documentation
2020-10-30 09:13:26 +10:00
Nyall Dawson
7e64d74f76
Add method to silence noisy GEOS error logging handling when not
...
desirable.
By default these errors are logged to the console and in the QGIS UI.
But for some operations errors are expected and logging these just results
in noise.
2020-10-21 11:08:35 +10:00
Even Rouault
7ac4b51885
Add QgsGeometry::wkbSize()
2020-10-19 09:25:10 +10:00
Nyall Dawson
746ee315bd
Fix boolean literal presentation in dox/PyQGIS docs
2020-10-16 16:03:26 +10:00
Nyall Dawson
41a30ac2e4
Better duplicate node detection/removal handling
2020-10-16 12:18:33 +10:00
Nyall Dawson
73b0e68eb2
Extract logic from QgsLineString::removeDuplicateNodes to a highly optimised check for duplicate nodes QgsLineString::hasDuplicateNodes
2020-10-16 12:18:33 +10:00
Nyall Dawson
f8222f0f16
[processing] Skip redundant and potentially expensive duplicate intersection
...
test in Split With Lines algorithm
2020-10-15 12:40:30 +10:00
Nyall Dawson
d3f038c929
Sipify
2020-10-09 11:20:09 +10:00
Nyall Dawson
4ee9feb56b
Sipify
2020-10-09 11:20:09 +10:00
Nyall Dawson
ab6bbfda1d
Fix all remaining Qt QFlags deprecated constructor warnings
2020-10-02 13:04:49 +10:00
Nyall Dawson
fe70bb2440
Dox
2020-09-18 11:50:27 +10:00
Nyall Dawson
c293d2c60d
[sipify] Correctly collapse TypeHint annotations
2020-09-18 11:50:27 +10:00
Nyall Dawson
fe5615ea44
Hold the GIL for more geometry related methods
2020-09-18 11:50:27 +10:00
Nyall Dawson
d4a2dddac5
Tag some inexpensive, frequently called methods with the HoldGIL annotation
...
This prevents the Python GIL from being released before calling the method
(which is the default behaviour). For very cheap to call c++ methods the
cost of releasing the GIL can outweigh the cost of the c++ call, which means
it's more efficient to retain the hold on the GIL.
Ideally we'd do this everywhere, and switch to an explicit ReleaseGIL
annotation on functions which are slow or risky (raise exceptions, or
do something which can cause a GIL deadlock). But those are very tricky
to identify, so instead just explicitly hold the gil on cheap methods
which are likely to be called many times and could have an impact on
script performance.
2020-09-18 04:34:57 +10:00
David Marteau
fc67ddc970
Change CRS serialization/deserialization for geometry parameter value
2020-09-15 07:39:10 +10:00
David Marteau
aa0a8ab628
Add geometry filter for processing geometry parameter
2020-09-15 07:39:10 +10:00
David Marteau
f2b8e6970b
Support point and rectangle as geometry parameter values
2020-09-15 07:39:10 +10:00
David Marteau
4eb779798e
Implement QgsReferencedGeometry
2020-09-15 07:39:10 +10:00
Nyall Dawson
f496173bd7
Fix messy doxygen blocks which mess with sipify script
...
Fixes #38291
2020-08-20 17:01:35 +10:00
Nyall Dawson
5d2495e65a
[api] Add helper api to directly retrieve a point/linestring/polygon from
...
a QgsMultiPoint/QgsMultiLineString/QgsMultiPolygon
Avoids the need to have to manually do an annoying cast when we
already know the geometry type
2020-08-18 08:33:53 +10:00