43349 Commits

Author SHA1 Message Date
Nyall Dawson
48d43d37ed
Merge pull request #5497 from nyalldawson/svg_crash
Fix crashes and issues with SVG rendering
2017-11-01 05:21:37 +11:00
Sandro Mani
8b7fd5428f [Globe] Port for QgsGeometry::constGet API changes 2017-10-31 15:04:24 +01:00
Luigi Pirelli
192d6f93d0 Update Attr Table after field calculation: fixes #17312 2017-10-31 14:20:19 +01:00
lbartoletti
5f750e72cb Fix connection 2017-10-31 11:45:10 +01:00
Matthias Kuhn
87643e9c8f Harden taskmanager tests
By using local variables and functions interdependency of the tests is decreased
2017-10-31 07:28:09 +01:00
Nyall Dawson
5000f9aac3
Merge pull request #5488 from nyalldawson/network
[processing] Fix some issues with network analysis shortest path algs
2017-10-31 17:27:58 +11:00
nirvn
9a1cd9dde7 [welcome page] avoid vertical shift when pinning/unpinning projects 2017-10-31 13:12:42 +07:00
Nyall Dawson
05ad0bc04a Update API break dox 2017-10-31 16:01:33 +10:00
Nyall Dawson
dbe2b340ac Update copyright date 2017-10-31 16:01:33 +10:00
Nyall Dawson
2bdc323d72 More test tolerance 2017-10-31 16:01:33 +10:00
Nyall Dawson
284c4d35cd Fix tests 2017-10-31 16:01:33 +10:00
Nyall Dawson
8f22f5eb3b [processing] Misc fixes for network analysis tools
Also maintain attributes in service area from layer alg, add test

Fixes #17325
2017-10-31 16:01:32 +10:00
Nyall Dawson
8d32bf729e Fix QgsGraphAnalyzer::dijkstra traverses through edges backwards
This means that it flips the direction of the graph edge, breaking
route restrictions.

Refs #17325
2017-10-31 16:01:32 +10:00
Nyall Dawson
57edec668e Fix incorrect enum values in network analysis algs
Didn't result in a bug, but made the code confusing to read
2017-10-31 16:01:32 +10:00
Nyall Dawson
199b569275 Fix broken network analysis network tolerance option
The tolerance option was not correctly calculated, resulting in
semi-random behavior for networks which relied on a non-zero
tolerance.

Also possible speed boost for complex networks by using
proper spatial index instead of custom sorting/filtering code.

Refs #17325
2017-10-31 16:01:32 +10:00
Nyall Dawson
ae8dc1cfb3 Optimise and simplify tie point calculation 2017-10-31 16:00:19 +10:00
Nyall Dawson
8a68a410bf Simplify overly complex code 2017-10-31 16:00:19 +10:00
Nyall Dawson
ab05fe7603 Fix extremely confusing network graph API naming
Since names of api calls were backwards to expectations
2017-10-31 16:00:19 +10:00
Nyall Dawson
b337335e9c Start unit tests for network analysis lib 2017-10-31 16:00:18 +10:00
Nyall Dawson
5ffd7214ee [processing] Shortest path handling for multipoint layers
Fixes shortest path algorithms fail for multipoint source layers
or layers with null geometries

Refs #17325
2017-10-31 16:00:18 +10:00
Nyall Dawson
4149da0556 Better reporting of errors when paths cannot be found, also
output point but with no geometry and missing attributes so
that it's clear which points could not be linked
2017-10-31 16:00:18 +10:00
Nyall Dawson
36a38f4e2d [processing] Keep attributes from start/end points layer in
output layer for shortest path algorithms

Otherwise the paths are nearly impossible to link back to
the source layer for further analysis
2017-10-31 16:00:18 +10:00
Nyall Dawson
49254384df Fix index out of range error in shortest path algs 2017-10-31 16:00:18 +10:00
nirvn
d1d95b1d6f [welcome page] reverse chronological order for pinned projects 2017-10-31 10:23:49 +07:00
Nyall Dawson
0b2de85fe7 Check file modified time when retrieving svg images from cache
If file has been modified since the cache, regenerate a new cache
image.

We don't want to check the file modified time too often though,
(e.g., we don't want to check for every point render in a 100k
point file), so use a hardcoded 30 second minimum time between
consecutive file modified checks.

This means that file modifications occuring more often than
every 30 seconds won't be picked up till 30 seconds has elapsed
since the last modification. But at the same time it means that
if the render takes < 30 seconds we'll only check each svg
at most once (and if a render takes > 30 seconds, adding a few
more milliseconds won't hurt!).

Fixes #13565
2017-10-31 12:12:24 +10:00
Nyall Dawson
b07f6757a5 Cleanup QgsSvgCache API
- Remove QgsSvgCacheEntry from public API (is an internal detail only)
- Modernize code
- Make protected QgsSvgCache members private, since this class is not
designed to be subclassed
2017-10-31 10:43:44 +10:00
Nyall Dawson
a6eea7205c Fix crashes caused by concurrent rendering of cached QPictures from QgsSvgCache
QgsSvgCache::svgAsPicture was rendering an implicitly shared copy when
the picture had already been cached. It turns out that rendering an
implicitly shared QPicture copy isn't thread safe, and rendering shared
copies simulataneously across different threads leads quickly to a crash.

Accordingly we always detach the QPicture objects returned by
svgAsPicture, so that the returned QPicture is safe to use across threads.

Also add unit tests for this, and a similar unit test to verify that
rendering of QImage based cached copies does *not* suffer the same
issue.

Fixes #17089, #17077
2017-10-31 10:24:18 +10:00
Juergen E. Fischer
3ae9ac5e82 translation string fixes 2017-10-30 20:13:51 +01:00
Nyall Dawson
942f431f0f Fix crash when rendering with SVG based symbols and SVG cache is filled
When the svg cache was full, any attempt to render an svg from the
cache would crash QGIS.

Fixes #16643
2017-10-30 21:32:48 +10:00
Nyall Dawson
b3ef4da2c0 Fix use after free 2017-10-30 21:13:41 +10:00
Nyall Dawson
ba05edcb89 Remove unnecessary debug message 2017-10-30 21:13:41 +10:00
Nyall Dawson
7843d22bde Fix memory leaks 2017-10-30 21:13:41 +10:00
Matthias Kuhn
7c5811ca2c
Fix building grass 2017-10-30 11:49:34 +01:00
Matthias Kuhn
59c3b86aec
Revert "Avoid recursion in feature filter model"
This reverts commit a3eadd320f28249915db54a02bbde9140327c6e3.
2017-10-30 11:45:54 +01:00
Matthias Kuhn
ec27839aff
Better typing for variables in configuration options 2017-10-30 11:29:16 +01:00
Matthias Kuhn
257f442901
Fix proxy basic authentication setting 2017-10-30 11:27:35 +01:00
Matthias Kuhn
a3eadd320f
Avoid recursion in feature filter model 2017-10-30 11:17:37 +01:00
Matthias Kuhn
1d21072bf0
Merge pull request #5491 from m-kuhn/dropV2
Drop V2 suffix on all geometry classes
2017-10-30 09:49:12 +01:00
Matthias Kuhn
d2c1011a13
Convert missing from[Geometry]XY calls 2017-10-30 09:14:06 +01:00
Matthias Kuhn
e0025b65b1
Rename QgsGeometry::fromPoint to QgsGeometry::fromPointXY
Also introduces the from[Geometry]XY for QgsGeometryFactory
2017-10-30 09:14:06 +01:00
Matthias Kuhn
82e6d1219f
Rename from[GeometryType] to from[GeometryType]XY
- QgsGeometry::fromPoint() was renamed to fromPointXY()
- QgsGeometry::fromMultiPoint() was renamed to fromMultiPointXY()
- QgsGeometry::fromMultiPolyline() was renamed to fromMultiPolylineXY()
- QgsGeometry::fromPolygon() was renamed to fromPolygonXY()
- QgsGeometry::fromMultiPolygon() was renamed to fromMultiPolygonXY()
2017-10-30 09:14:06 +01:00
Matthias Kuhn
bde014ec7b
Adjust leftovers addPointsV2 to addPoints 2017-10-30 09:14:06 +01:00
Matthias Kuhn
ca74e391cd
Rename QgsGeometry.addPoints with XY / V2-less versions 2017-10-30 09:14:05 +01:00
Matthias Kuhn
750a54f8f6
More drop V2 suffix fixes 2017-10-30 09:14:05 +01:00
Matthias Kuhn
271ef7c0a3
More V2 drop fixes 2017-10-30 09:14:05 +01:00
Matthias Kuhn
e19f6482ca
Various fixes to dropping V2 suffix 2017-10-30 09:14:05 +01:00
Matthias Kuhn
b4e0ebe4a8
Document API breaks 2017-10-30 09:14:05 +01:00
Matthias Kuhn
7f3ad76882
Rename QgsMultiPolygonV2 to QgsMultiPolygon 2017-10-30 09:14:04 +01:00
Matthias Kuhn
3fcdcd87af
Rename QgsMultiPointV2 to QgsMultiPoint 2017-10-30 09:14:04 +01:00
Matthias Kuhn
b6f46eae11
Rename QgsPolygonV2 to QgsPolygon 2017-10-30 09:14:04 +01:00