5472 Commits

Author SHA1 Message Date
Alessandro Pasotti
17280c3e4d
Merge pull request #9203 from elpaso/bugfix-21305-paste-slow-no-provider
Cache unique values when creating features
2019-02-21 08:31:41 +01:00
Matthias Kuhn
968e08c6c9
Geometry validator: do not report result summary as error 2019-02-20 18:14:41 +01:00
Matthias Kuhn
ddbd06f3f1
Merge pull request #9207 from mbernasocchi/master
Add safety guard when mDataProvider is not set
2019-02-20 14:02:16 +01:00
Matthias Kuhn
8ea09b61c8
Run sipify 2019-02-20 12:01:56 +01:00
Alessandro Pasotti
ff9a65c1b4
Merge pull request #9193 from elpaso/bugfix-21270-processing-algrunner-crash
Processing: fix crash in alg runner task with bad scripts
2019-02-20 07:43:50 +01:00
Nyall Dawson
979adbbabf Indicate exception types to sip
Exposes the full Python exception when an error occurs in createInstance()
2019-02-20 13:05:09 +10:00
Nyall Dawson
c8a4dff475 Add maximum search distance parameter to QgsSpatialIndex::nearestNeighbor 2019-02-20 05:40:02 +10:00
Nyall Dawson
362ba02ade When a QgsSpatialIndex is storing feature geometry, then
nearestNeighbor search performs an EXACT nearest neighbour search,
instead of just a nearest-neighbour-by-bounding-box search
2019-02-20 05:40:02 +10:00
Nyall Dawson
26555358f9 Add API for QgsSpatialIndex to optionally store feature geometries
This potentially avoids a second expensive feature request after
building a spatial index and later needing to re-request features
which match spatial index search.

It's non-default, as it requires the index to store all feature
geometries, so it's more memory expensive.
2019-02-20 05:40:02 +10:00
Juergen E. Fischer
6090a932c2 dwg import: less noisy debugging 2019-02-19 19:56:40 +01:00
Alessandro Pasotti
d239ea2df9 Fix unique values when generating a set of features 2019-02-19 19:04:48 +01:00
Alessandro Pasotti
348e6837ac Fix docs for createFeatures 2019-02-19 11:17:48 +01:00
Alessandro Pasotti
490c1fedfb Rename QgsFeaturesData to QgsFeatureData and fix test case 2019-02-19 10:51:53 +01:00
Alessandro Pasotti
ba3d9ed066 Cache unique values when creating features
Fixes #21305 - pasting features is very slow

Aggressively optimize createFeature for speed
and introduces createFeatures for bulk creation.
2019-02-19 10:02:17 +01:00
Hugo Mercier
9ed5b3f874
Merge pull request #9063 from mhugo/fix_19355
Fix $length in labels
2019-02-14 14:34:13 +01:00
Hugo Mercier
e4288e5dea QgsExpression: set setGeomCalculator precedence
setGeomCalculator, setDistanceUnits and setAreaUnits have now
 precedence over expression scopes.
2019-02-14 13:40:12 +01:00
Hugo Mercier
809196693c Fix $length in labels (fixes #19355)
Use the project expression scope to access project
parameters (ellipsoid and distance/area units)
2019-02-14 13:40:12 +01:00
Nyall Dawson
7418c189d0 [processing] Also generate friendly names for outputs when converting models to scripts 2019-02-14 15:36:55 +10:00
Nyall Dawson
d342ce939b [processing] When converting models to Python, use friendlier (more
descriptive) names when storing child algorithm results

Makes for much easier to understand scripts
2019-02-14 15:36:55 +10:00
Nyall Dawson
69f45e389c Refactor QgsExpressionContext and move QgsExpressionContextUtils
out to its own header

Avoids slow recompilation caused by changes to the frequently
modified QgsExpressionContextUtils class
2019-02-13 07:59:30 +10:00
Nyall Dawson
e533a4078c [processing] Expose some model related variables to expressions
run inside models

Allows expressions to access important variables like the current
model path
2019-02-13 07:59:30 +10:00
Nyall Dawson
493aed58fb API tweak 2019-02-13 07:59:30 +10:00
Luigi Pirelli
2a917f4c10
Merge pull request #9049 from luipir/rasterSLD_export
Add SLD 1.0 export for rasters
2019-02-11 22:04:30 +01:00
Nyall Dawson
ceaf97b204 Remove a totally unused enum 2019-02-09 07:27:39 +10:00
Nyall Dawson
48e05434e4 Dox++ 2019-02-09 07:27:39 +10:00
Nyall Dawson
35ddb3b630 [browser] Provide mime data for directory items
Allows them to be dragged and dropped to file widgets
2019-02-09 07:27:39 +10:00
Matthias Kuhn
09407c1258
Merge pull request #9128 from m-kuhn/todo-qgis-4
Move QGIS 3 todos to QGIS 4
2019-02-08 08:02:17 +01:00
Matthias Kuhn
2fb37042a5
Fix TODO and docstrings 2019-02-07 14:36:43 +01:00
Matthias Kuhn
90f7989f4d
Move QGIS 3 todos to QGIS 4 2019-02-07 09:10:03 +01:00
Matthias Kuhn
32b6599df0
Merge pull request #9074 from m-kuhn/til
Deprecate QgsGeometry::set for usage in Python
2019-02-07 09:07:14 +01:00
lbartoletti
b4d01e461f qgsRound: places should be of integer type instead of double 2019-02-07 17:00:41 +11:00
Nyall Dawson
d61694cb42 Deprecate QgsDataItem API for setting item CRS
This is no longer used by QGIS (it was only ever used by the standalone
browser)
2019-02-07 04:14:16 +11:00
Matthias Kuhn
2400050878
Deprecate for sip 2019-02-06 13:09:23 +01:00
Matthias Kuhn
89ea819938
Make sure Python wrappers of quasi-singletons are kept alive
If they are deleted, any other python wrappers which have been parented to these singletons are deleted too.

One of the most common issues with this is, that subclasses of registry items are deleted and lost.
2019-02-06 12:18:41 +01:00
Matthias Kuhn
5f1cea13c7
Add docstrings and modernize code 2019-02-05 17:57:27 +01:00
Matthias Kuhn
4612521c50
Const correctnes for QgsFeature in labeling
A feature is not modified while it's sent through the labeling pipeline.
2019-02-05 17:16:23 +01:00
Martin Dobias
4f905cc2e8 [vertex tool] right-click to loop through editable features
Until now mouse right-click could only select and deselect the highlighted
feature to "lock" vertex tool (and numerical editor) to it, so that it is
easier to focus only on editing of the particular feature. It was however
still difficult to pick the right feature in case there were multiple
features in one location or very close to each other. This is now solved
by the fact that repeated right button clicks will loop through the editable
features. So if there are two features in one location (A, B) then repeated
right-clicks will select: A - B - nothing - A - B - nothing ...
2019-02-05 09:07:58 +01:00
Nyall Dawson
715395aa47 Fix incorrect 'not available in Python' dox 2019-02-05 13:46:34 +11:00
Nyall Dawson
867e39947b Allow for exact calculation of symbol sizes with mixed layer units
Fixes #21143
2019-02-05 11:07:02 +11:00
Nyall Dawson
384d310233 Minor improvements to PyQGIS returns for SIP_OUT params 2019-02-05 04:55:34 +11:00
Nyall Dawson
4b0f6b756c Slight improvements to Python docs 2019-02-05 04:55:34 +11:00
Mathieu Pellerin
8ac762e5e1
[ui] Fix tiny vertex marker on hidpi 2019-02-04 16:43:04 +07:00
Matthias Kuhn
612576ca8e
Deprecate QgsGeometry::set for usage in Python
When a new QgsAbstractGeometry is set on a geometry object, the previous child is deleted.
If the previous object was constructed by Python, it's wrapper will still be alive for
as long as the QgsGeometry is alive. If a new QgsAbstractGeometry is constructed at the same
memory address as the old one, the wrapper will be reused with wrong type (and other)
information, leading to all kind of weird issues.

See also https://www.riverbankcomputing.com/pipermail/pyqt/2019-January/041251.html
2019-02-03 19:47:01 +01:00
Nyall Dawson
eba5409ebc Dox++ 2019-02-03 13:02:18 +11:00
Nyall Dawson
c9e7616498 Fix hang when WMS credentials requested
Remove responsibility for credentials mutex locking from external
callers and handle appropriate locks internally. This allows the
mutex lock to be much "tighter" and avoids deadlocks when
credentials are requested while an existing credentials dialog
is being shown.

(No mutex is required protecting the credentials dialog itself
as this is ALWAYS shown in the main thread)

Fixes #20826
2019-02-03 13:02:18 +11:00
Etienne Trimaille
57695bd036 use upper camel case for the class name 2019-02-03 07:18:34 +11:00
Luigi Pirelli
3b1127ee70 spellechck do warning if htmls tags in methoid description => fail travis 2019-02-02 11:01:09 +01:00
Luigi Pirelli
bdda8d0b37 back to const methods 2019-02-01 18:13:05 +01:00
Luigi Pirelli
0e9af79165 fixed AStyle with astyle-all.sh 2019-02-01 14:42:36 +01:00
Nyall Dawson
03a2a03dcf Dox 2019-02-01 21:44:53 +11:00