2444 Commits

Author SHA1 Message Date
Sandro Santilli
f0e0ba5bb0 Add test for QgsGeometryUtils::sqrDistToLine
See #13952
2016-06-28 12:24:20 +02:00
Sandro Santilli
ba1d38c2ed Add comment describing the invalid polygon
Follow up to
https://github.com/qgis/QGIS/pull/3246#discussion_r68661723
2016-06-28 06:17:36 +02:00
Sandro Santilli
3d319d90bd Add test for selecting invalid geometries (#3246)
See #13635
The test passes
2016-06-28 00:27:16 +02:00
mhugent
21b8ef0e4a Merge pull request #3242 from mhugent/full_circle
Change full circle interpretation, fixes #15116
2016-06-27 16:15:07 +02:00
Marco Hugentobler
663333de7d Indentation 2016-06-27 15:00:18 +02:00
Marco Hugentobler
ef90c0b2f7 Add unit test for ticket #15116 2016-06-27 13:32:36 +02:00
Nyall Dawson
4080aad0ee [ogr] Read GPX elevation values as geometry Z values 2016-06-27 19:34:28 +10:00
Nyall Dawson
9f0ae9b408 Make outline only simple markers work with categorised/graduated
etc renderers (fix #15132)
2016-06-27 10:17:54 +10:00
Nyall Dawson
e6034e9a1e Fix vector field symbol does not use subsymbol color (fix #15130) 2016-06-26 17:40:50 +10:00
Alessandro Pasotti
c1d0fab04f Fix env var 2016-06-24 17:17:41 +02:00
Hugo Mercier
defd7388bc Merge pull request #3229 from mhugo/fix_15113
Allow curved polygons to be inverted (fixes #15113)
2016-06-23 17:17:20 +02:00
Nyall Dawson
b63f7887e9 Add qgstestutils.h file with test helpers (#3208)
Initially containing QGSCOMPARENEAR(a,b,epsilon) which prints
debug information if the comparison fails
2016-06-23 16:16:04 +02:00
Hugo Mercier
8976c9de02 Allow curved polygons to be inverted (fixes #15113) 2016-06-23 16:09:23 +02:00
Even Rouault
d7414d7eca [WFS provider] Handle the case where the layer schema has a ogc_fid field
Fixes #15062
2016-06-22 23:01:44 +02:00
Sandro Santilli
b040410c5e Fix comment about precision loss
Thanks Even for helping with this
2016-06-22 15:26:02 +02:00
Sandro Santilli
e92e7fe472 Allow converting polygons with unclosed rings to GEOS
Forces ring close on conversion, fixing a regression
from 2.8 (and 2.14). See #13635

Adds test for identifying invalid polygons, currently only
testing for the unclosed-ring invalidity.

The test was verified to fail without the fixes included
in this same commit, and to pass in 2.14.
2016-06-22 13:28:39 +02:00
Hugo Mercier
6fae6e22b0 Update arrow mask image 2016-06-21 11:18:19 +02:00
Hugo Mercier
36e7f920c2 Fix outline rendering in arrow symbol layer 2016-06-21 10:33:54 +02:00
Even Rouault
ab98858b98 Fix build failure due to dabc3b16d72184da2867e0b3ae37b1d45928cddd 2016-06-20 22:03:11 +02:00
Even Rouault
6ea03ea4e2 [Geometry] Fix various issues related to Wkb/Wkt import
- Make QgsCurvePolygonV2::fromWkb() accept CompoundCurveM sub-geometries
- Make QgsGeometryCollectionV2::fromWkb() validate the sub-geometry type,
  so that QgsGeometryCollectionV2 subclasses do not import incompatible
  sub-geometries
- Make QgsGeometryCollectionV2::fromWkt() accept curve sub-geometries
- Make QgsMultiPolygonV2::addGeometry() accept only Polygon and not
  CurvePolygon
- Add tests
2016-06-20 21:08:51 +02:00
Even Rouault
dabc3b16d7 [Geometry] Fix deleteVertex() for CircularString, CompoundCurve and CurvePolygon
In some situations, deleteVertex() could generate an invalid geometry, causing
later crashes due to unexpected structure.

Fix #15087
2016-06-20 17:05:16 +02:00
Even Rouault
4c56fa6e8e [OGR provider] Make changeGeometryValues() accept null geometry
Fixes #15081
2016-06-20 12:20:41 +02:00
Even Rouault
85128c5419 QgsCoordinateReferenceSystem::setProj4String(): harden validation
OSRImportFromProj4() may accept strings that are not valid proj.4 strings,
e.g if they lack a +ellps parameter, it will automatically add +ellps=WGS84, but as
we use the original mProj4 with QgsCoordinateTransform, it will fail to initialize
so better detect it now.

Fixes #14844
2016-06-20 11:30:29 +02:00
Even Rouault
22dfd764eb [OGR provider] Avoid considering mix of Polygon and CurvePolygon as 2 sublayers
Fixes #15066
2016-06-18 19:21:10 +02:00
Even Rouault
3b65568c73 [OGR provider] Improve detection of layer geometry type
When a OGR layer is of geometry type "unknown", we use the
geometry of the first feature to guess the geometry type. But
if this feature has no geometry, then we assume that we have no
geometry for the whole layer. This is a bit extreme. Let us
allow to probe a few features before giving up.

Fixes #15065
2016-06-18 18:36:47 +02:00
Even Rouault
f3549981a6 [WFS provider] Add heuristics to detect MapServer WFS 1.1 behaviour (sometimes)
Fix #15061

MapServer honours EPSG axis order in WFS 1.1, but returns srsName in GetFeature
response with EPSG:XXXX syntax instead of urn EPSG srs. This confuses the GML
parser that thinks that no axis inversion should then happen.

The heuristics here consist in checking the envelope of the response with the
capabilities extent.

This should be safe and should work for layers with non global extent, but will
not detect all issues.

Proper fix is either to force WFS 1.0, or upgrade to MapServer 7.0 with WFS 2.0
2016-06-18 15:10:44 +02:00
Sandro Santilli
a211c982cf Allow to undo/redo composer grouping/ungrouping
Fixes #11371 (crash on ungrouping after moving the group) and more
undo/redo related issues.

Enable pending test for the crash (now passing) and add many more
undo/redo related ones (including signals testing).

Includes a new QgsGroupUngroupItemsCommand class
and its SIP bindings.
2016-06-17 13:41:56 +02:00
Nyall Dawson
9abb6c43f2 Revert "[FEATURE][expressions] implicit feature->geom conversion"
This reverts commit 7cab60bc4328e6cb4c57f8320c2d85d9383a2424.

The conversion was unreliable, as it was not correctly determining
that the feature's geometry was required and consequently not
fetching it from the provider. This isn't trivial to fix, so
I'm reverting this feature before release.
2016-06-17 11:16:08 +10:00
Sandro Santilli
57ff59aa2d Ignore files generated during "make check" 2016-06-16 18:38:36 +02:00
Nyall Dawson
aa0e6d8944 Followup c78347, update test images 2016-06-16 18:30:22 +10:00
Nyall Dawson
33a5ee7ab4 Fix selecting features by radius (fix #14748) 2016-06-15 11:57:04 +10:00
Nyall Dawson
bf4cf51e1a Fix incorrect area calculation for polygon (fix #14675) 2016-06-15 11:10:32 +10:00
Matthias Kuhn
0c10f68a01 Followup bbbc9d0: Fix tests 2016-06-14 14:40:45 +02:00
Nyall Dawson
6568da6ce0 Rename arrow symbol head width/height to length/thickness
Width/height naming is dependant on line direction, so for
clarity rename them to something which doesn't depend
on direction (fix #15002)
2016-06-14 12:54:49 +10:00
Nyall Dawson
660900ba6b Tweak test tolerance for xenial 2016-06-14 08:55:40 +10:00
Nyall Dawson
0a5ad73581 Invalid join cache when layer is modified (fix #11140) 2016-06-13 22:08:55 +10:00
Nyall Dawson
16eb1e14d0 Classifications on joined fields should only consider values which
are matched to layer's features (fix #9051)
2016-06-13 13:43:46 +10:00
Matthias Kuhn
4f803e8658 Fix failing test 2016-06-12 16:40:21 +02:00
Matthias Kuhn
7b3e667282 Remove more debug noise 2016-06-12 16:05:40 +02:00
Matthias Kuhn
c63b910d75 Remove debug noise 2016-06-12 16:01:51 +02:00
Even Rouault
5fcadebc50 Indentation fix 2016-06-12 15:46:33 +02:00
Even Rouault
31879e5211 [WFS provider] Fix handling of LatLongBoundingBox in WFS 1.0
According to the specification, the values of LatLongBoundingBox
are supposed to be in the SRS, not necessarily in WGS84.

But some servers do not follow the spec and return values in WGS84,
so let's try to accomodate for this too.

Fix #14876
2016-06-12 15:14:23 +02:00
Even Rouault
7ed1a7ff79 Merge branch 'master' of github.com:qgis/QGIS 2016-06-11 14:03:03 +02:00
Even Rouault
f7cf974774 Merge remote branch 'origin/wfs_geomedia_fixes' 2016-06-11 13:55:34 +02:00
Even Rouault
5839a3a8cd Merge branch 'master' of github.com:qgis/QGIS 2016-06-11 13:01:49 +02:00
Nyall Dawson
607b1df4dc Fix joined attributes can't be used in filter expressions
(fix #13176)
2016-06-10 18:49:01 +10:00
Even Rouault
12bb1f7b4a testqgsogcutils.cpp: add more debug output to diagnose flake failure on QT5 2016-06-10 10:44:24 +02:00
Even Rouault
690e554b61 QgsGML: handle more type of geometries (Arc, CompositeSurface, etc...) through OGR 2016-06-10 09:39:11 +02:00
Even Rouault
a4f151131b QgsGmlStreamingParser: fix memory leak if parsing a GML file truncated in the middle of a feature 2016-06-10 09:39:11 +02:00
Even Rouault
5acb128867 testqgsgml.cpp: fix memory leaks in test 2016-06-10 09:39:11 +02:00