6568 Commits

Author SHA1 Message Date
Alessandro Pasotti
c8b26771cf
Merge pull request #8359 from elpaso/handle-bad-layers2
[needs-docs][feature] Deferred handling of bad layers
2018-11-06 08:43:18 +01:00
Nyall Dawson
dc72f06e53 Bump minimum Qt version to 5.9 2018-11-06 08:45:37 +10:00
Matthias Kuhn
e9deafcf37
Merge pull request #8409 from DelazJ/renameFiles
Rename some rendererV2 ui files
2018-11-05 14:24:10 +01:00
Nyall Dawson
82baff87d4 Add a __repr__ method to QgsMimeDataUtils::Uri 2018-11-05 22:02:32 +10:00
Martin Dobias
93e737e4bf [vertex tool] Fix topo editing when moving vertices/edges (fixes #20158)
- when some "extra" vertices are selected when moving a vertex, their coincident
  vertices will be also moved (#20158)
- when moving an edge, coincident vertices to its endpoints will be also moved
- new tests to cover the above scenarios
- made the code hopefully easier to read
2018-11-05 12:31:51 +01:00
Alessandro Pasotti
f02345bd8b Remove unnecessary project from test data 2018-11-05 10:27:02 +01:00
Alessandro Pasotti
eb02004b60 Store original style as QDomDocument instead of an XML string 2018-11-05 10:27:02 +01:00
Alessandro Pasotti
a4182c1e04 Remove unnecessary project from test data 2018-11-05 10:26:39 +01:00
Alessandro Pasotti
7a259c6ea5 Better handling of invalid relations ...
- do not add them to the manager dialog
- do not add relations to not existent layers (but keep relations to invalid layers)
2018-11-05 10:26:39 +01:00
Alessandro Pasotti
bc424d09c1 Store original style as QDomDocument instead of an XML string 2018-11-05 10:26:39 +01:00
Alessandro Pasotti
d46d765d58 Restore handle bad layers dialog original behavior 2018-11-05 10:26:39 +01:00
Alessandro Pasotti
8493636f18 Data source select dialog now accepts a model 2018-11-05 10:26:39 +01:00
Alessandro Pasotti
086be3832c Rendering test for bad layers and setDataSource 2018-11-05 10:24:35 +01:00
Alessandro Pasotti
64c23dec34 Spelling 2018-11-05 10:24:35 +01:00
Alessandro Pasotti
17433181aa Fix raster style restore when setDataSource 2018-11-05 10:24:35 +01:00
Alessandro Pasotti
4481127b9a Fix raster set data source (with test) 2018-11-05 10:24:35 +01:00
Alessandro Pasotti
8d9d52d128 Add test data for relations 2018-11-05 10:24:35 +01:00
Alessandro Pasotti
0cd21c91f1 Keep invalid relations and update them when the data source changes
Added a check for layer.isValid in relation.isValid, keep
relations in the manager even if they are not valid and
connect dataSourceChanged with updateRelationStatus
2018-11-05 10:24:35 +01:00
Alessandro Pasotti
2bd90da9c1 Added a validOnly flag to mapLayers to filter for valid layers only 2018-11-05 10:24:35 +01:00
Alessandro Pasotti
bd71df0054 Add the bad layers test to cmake and fix it for renamed methods 2018-11-05 10:24:35 +01:00
Alessandro Pasotti
f856b4c8e3 Renamed originalXmlProperties methods and variables 2018-11-05 10:24:35 +01:00
Alessandro Pasotti
9cfb4369f9 Tests for bad layers raster support 2018-11-05 10:24:35 +01:00
Alessandro Pasotti
99638cfdb6 More readable test 2018-11-05 10:24:35 +01:00
Alessandro Pasotti
5010956cb4 Add test case for getFeatures on invalid bad layer 2018-11-05 10:24:35 +01:00
Alessandro Pasotti
497a7da9de Added API methods to retrieve only valid maplayers
... and to count them

Tests updated accordingly, note that from now on
the assumption that a layer store or a layer project
contains only valid layers will not be true anymore.

To be honest it has never been true, because a
layer can become invalid at any time during
its life cycle, so better never assume that a
layer from the store or from the project is vaid.
2018-11-05 10:24:35 +01:00
Alessandro Pasotti
f9289802a3 Add test for handle bad layers and invalid layers pass through 2018-11-05 10:24:35 +01:00
Nyall Dawson
18d4059546 Correct test comparisons
Previously QCOMPARE( QgsGeometry, QgsGeometry ) was actually only
testing for QCOMPARE( bool(QgsGeometry), bool(QgsGeometry) )...!
2018-11-05 08:39:10 +10:00
Nyall Dawson
7be2925649 Remove QgsGeometry bool operator
This is too dangerous -- it gets silently casted to numeric values
instead of throwing compilation errors
2018-11-05 08:39:10 +10:00
Nyall Dawson
c98d13d2f4 Add method to populate browser context menu to QgsDataItemGuiProvider 2018-11-04 21:07:27 +10:00
Nyall Dawson
6ec7f02e83 Add a QgsDataItemGuiProvider interface and registry for providers
These providers will be used to control how the browser data items
behave within GUI, and to allow separation of GUI related
properties of browser items from the core code.

A new registry QgsDataItemGuiProviderRegistry has been created
(modeled off QgsDataItemProviderRegistry), with an application
wide instance available from QgsGui::instance()->dataItemGuiProviderRegistry()
2018-11-04 21:07:27 +10:00
Nyall Dawson
0b17db6fc4 Add unit tests for QgsDataItemProviderRegistry 2018-11-04 21:07:27 +10:00
Martin Dobias
5dd566455f [vertex tool] Respect topo editing when adding a vertex (fixes #18046)
When adding a vertex to a segment that is coincident with some other
segments and topological editing is enabled, vertex tool will now correctly
add new vertex also the coincident segments to preserve shared borders.
2018-11-04 09:54:24 +01:00
Harrissou Sant-anna
fd2a599778 More rendererv2 cleanup 2018-11-03 17:17:01 +01:00
Denis Rouzaud
8ea02e9655
fix qgsDoubleString printing -0 (#8363) 2018-11-01 08:29:57 -08:00
Even Rouault
6d4935803b
Merge pull request #8397 from rouault/fix_20308
[BUGFIX] [OGR provider] Make filter by id(s) requests work again on OSM datasets (fixes #20308)
2018-11-01 14:32:01 +01:00
Even Rouault
986e11b6bb
[BUGFIX] [OGR provider] Make filter by id(s) requests work again on OSM datasets (fixes #20308) 2018-11-01 12:37:37 +01:00
Nyall Dawson
09c2daa1c1 [FEATURE] Allow exploration of QGS project file contents directly
within browser

Allows QGIS project file items inside the browser to be expanded,
showing the full layer tree (including groups) contained within
that project. Layers are shown as normal layer items, allowing
them to be easily added to the current project via drag and drop
or double click. Additionally, because they are treated just
the same as any other layer items in the browser, they can be
drag and dropped within the browser to e.g. directly copy the
layer to a geopackage file!

TODO: apply layer symbology from project file when adding a
layer from a different project to the current project
2018-11-01 20:41:08 +10:00
Nyall Dawson
f0436df618 [browser] Allow data item providers a chance to implement QGIS project
item creation and override default project file handling

If no provider is registered which handles QGIS project files,
then the default behavior is used as a fallback
2018-11-01 20:41:08 +10:00
Nyall Dawson
5c5f2ed7e3 Add method to get QgsLayerItem::LayerType from a map layer 2018-11-01 20:41:08 +10:00
Matthias Kuhn
429cd0bacd
Merge pull request #8240 from m-kuhn/mergeVectorLayersDuplicateFid
Ignore FID field when merging vector layers to geopackage
2018-10-31 13:47:12 +01:00
Alessandro Pasotti
467fae8e26
Merge pull request #8388 from elpaso/bugfix-20271-wms-null-styles
[wms] Do not pass null QStrings to QgsWmsProvider::setQueryItem
2018-10-31 13:34:47 +01:00
Matthias Kuhn
432bec17fc
Add test for QgsVectorLayerExporter with RegeneratePrimaryKey 2018-10-31 10:27:55 +01:00
Alessandro Pasotti
94aa628e3e [wms] Do not pass null QStrings to QgsWmsProvider::setQueryItem
Fix #20271 - WMS is not displayed in QGIS 3.4.0

With test
2018-10-31 10:06:47 +01:00
rldhont
b64e72a89d [Bugfix][Server] Use Project selection color in GetPrint 3.4 2018-10-31 09:38:28 +01:00
Nyall Dawson
0d7f59865b Fix broken handle bad layers dialog
Partially revert af0bae67f and ea2cc365

Fixes #20265
2018-10-31 04:45:31 +10:00
Nyall Dawson
a873289da7 [processing] Fix crash when right clicking toolbox outside of an item
Fixes #20264
2018-10-31 04:44:36 +10:00
Matthias Kuhn
8fc43780dc
Merge pull request #8114 from signedav/bugfix_not_deleting_relation
More intuitive relation reference widget text filter
2018-10-29 09:52:41 +01:00
rldhont
6249b07f7c
Merge pull request #8320 from rldhont/server-reactivate-print-selection-3
[Server] Reactivate the capability to print selection with Server 3.4
2018-10-26 14:23:09 +02:00
Hugo Mercier
443afcd0bf
Merge pull request #8323 from mhugo/fix_15709
Fix virtual layer FilterRect handling when no uid is defined
2018-10-26 14:04:27 +02:00
rldhont
c47c0ef7d5 [Server][Tests] Update WMS GetPrint Selection 2018-10-26 11:36:28 +02:00