16380 Commits

Author SHA1 Message Date
Nyall Dawson
1a74938ba8 [processing] Add option for multiple field parameters to default to
selecting all available fields

For some algorithms this is better UX then defaulting to an empty list
2020-01-04 23:06:03 +10:00
Nyall Dawson
d788dfc0cb Update menu link 2020-01-03 05:25:33 +10:00
Alex
e9aff0b695 join by location c++ port 2020-01-03 05:25:33 +10:00
Nyall Dawson
c43613d0b2 Another hash 2020-01-02 18:26:49 +10:00
Nyall Dawson
158dfcc3cc More test hashes 2020-01-02 18:26:49 +10:00
Nyall Dawson
c4672ef984 Add extra raster hashes 2020-01-02 18:26:49 +10:00
Panos Mavrogiorgos
d7f0ea2293 Fix tests 2020-01-02 18:26:49 +10:00
Panos Mavrogiorgos
0c3cb558a8 Introduce GRASS_USE_REXTERNAL setting
GRASS GIS, in addition to importing data in its native formats via
`r.in.gdal`/`v.in.ogr` (and likewise `r.import`/v.import`),
also supports `r.external`/`v.external` which only link the data into
the GRASS DB.

Nevertheless, both `r.external` and `v.external` occasionally have problems,
especially on windows. E.g.:

- https://trac.osgeo.org/grass/ticket/3927

GRASS 7 Processing Plugin already has a setting that controls whether
`v.external` is used (disabled by default).

With this commit the complementary setting for `r.external` gets added too.
Usage of `r.external` is disabled by default. This is changing the existing
behavior, which was to use r`r.external`. The downsides of this change
should be the somewhat lower import speed + higher disk usage. Nevertheless
this way we have the same default value as `v.external` + we circumvent the
`r.import/v.import` shortcomings.
2020-01-02 18:26:49 +10:00
Nyall Dawson
5792966b12 Update test results 2020-01-02 14:20:14 +10:00
Nyall Dawson
fe6abba251 [api] Add constructor for QgsSpatialIndex which allows for a callback
function during bulk index load from a feature iterator

Allows single-iteration of a source for dual purposes simultaneously,
e.g. doing other feature-based operations while still gaining the full
advantage of the bulk loaded spatial index without having to do multiple
feature iterations
2020-01-02 14:20:14 +10:00
Vincent Cloarec
30569bce1f Move QgsRasterLayerProperties class to the gui API
Motivation :
Move the QgsRasterLayerProperties class to the GUI API.
So, this class could be used using the QGIS API, notably for standalone applications.

The instance of this class was dependent, since QGIS 3.8, from the QgisApp instance, when calling the askUserForDatumTransform(). As this method, defines a title and only call QgsDatumTransformDialog::run() method from the gui API, this PR purpose to :
2020-01-02 13:02:32 +10:00
Andrea Giudiceandrea
ef9b8c2c25 Fix missing flags in r.reclass.area GRASS alg
Fixes #33569
2020-01-02 11:43:10 +10:00
Andrea Giudiceandrea
19465c6295 Fix validity mask filename quoting in Fillnodata alg
Fixes a bug similar to #33562
2020-01-01 09:07:58 +10:00
Andrea Giudiceandrea
fbca3641e5 Fix validity mask filename quoting in Sieve alg
Fixes #33562
2020-01-01 09:07:58 +10:00
Nyall Dawson
12006de1aa [processing] Port Delete Duplicate Geometries to c++ 2019-12-31 15:06:42 +10:00
Nyall Dawson
2433ee555f [FEATURE][processing] Add native affine transform algorithm for vectors
Offers the following benefits over the GRASS/SAGA versions:
- Full support for z/m values and handling curved geometries without loss
of curves
- Works with all native data types, no need for format transformation
- Supports dynamic (data defined, per feature) translate/scale/rotate parameters
- Allows transformation and scaling of both Z and M values (if present)
- Supports in-place edit mode

Fixes #33550
2019-12-31 15:01:34 +10:00
Andrea Giudiceandrea
c062b52fd8 Fix SAGA Raster Buffer algorithm (GridBuffer.txt)
Since SAGA 2.3.0, DIST and BUFFERTYPE parameters for Gid Buffer module were renamed to DISTANCE and TYPE, respectively.
2019-12-29 05:49:27 +10:00
Mathieu Pellerin
ddd2c6ea3d Expose QgsBearingUtils to QML 2019-12-27 09:08:38 +07:00
Nyall Dawson
f44c229405 Fix dox test 2019-12-26 13:18:10 +10:00
Nyall Dawson
1899f90a04 [needs-docs] Rework label engine "maximum line candidates" and "maximum polygon candidates"
settings and logic

The previous approach of a single fixed value which applied to ALL line and ALL polygon
features was... not ideal. It meant that all line features would be assigned the same
number of candidates, regardless of length. So a road of length 1 cm on the rendered
map would have an identical number of candidates as a 30cm road covering the length of the
whole map!! This resulted in both a lot of wasted calculations (generating a ridiculous
number of candidates for small lines at barely discernable distances from each other)
AND an insufficient number of candidates for lengthy features (resulting in worse label
placement for these features).

(The situation was similar, but even worse for polygons)

Now, the setting is reworked to "Number of line candidates per cm" and "number of
polygon candidates per cm2". This means that small features get much less candidates,
and large features get much more features! Both a win for map rendering speed in many
circumstances AND good cartography... now that's a nice Christmas gift for QGIS :)
2019-12-26 13:18:10 +10:00
Nyall Dawson
df102a98da [needs-docs] Drop setting for maximum number of point label candidates
This setting is easily replaced by automatically calculated, optimised
values for each separate point plcaement mode individually
2019-12-26 13:18:10 +10:00
Matthias Kuhn
4f625ce733
Merge pull request #33476 from dmarteau/fix-project-relation-manager
Fix inconsistent dependency to project in QgsRelation/QgsRelationManager
2019-12-23 07:23:08 +01:00
Nyall Dawson
fb5b440d5d [FEATURE] Allow dropping a map layer from the layer tree onto
a projection selection widget to set the projection to match that layer

Just a little timesaving shortcut!
2019-12-23 05:17:40 +10:00
Nyall Dawson
d5821feb9f [api] Add api to allow panel widgets to show a "hamburger" style
menu in the top right of the panel

This gives the panel a place to add menu actions like help links
for the panel.
2019-12-22 20:33:55 +10:00
David Marteau
907b27309c
Add missing parameter documentation 2019-12-21 13:28:31 +01:00
David Marteau
5bf8d2cd26
Pass project when creating relation from Xml
Fix dependency inconsistency to project from QgsRelationManager
    by forcing  'QgsRelation::createFromXml' to rely on project passed
    to 'QgsRelationManager' instead of using 'QgisProject::instance()'
2019-12-20 23:56:17 +01:00
Nyall Dawson
521080cd13 Add API to auto set QgsCoordinateOperationWidget selection to match
a QgsCoordinateTransformContext's state
2019-12-21 05:07:39 +10:00
Nyall Dawson
b8b668888c Allow algorithms to link to multiple depandant parameters in modeler scene 2019-12-21 05:07:39 +10:00
Nyall Dawson
3e9aaaa6ea Move variant to CRS resolution out to QgsProcessingUtils for wider
usability
2019-12-21 05:07:39 +10:00
Nyall Dawson
fe622dd24a [API][processing] New parameter type for coordinate operations
Allows selection of the proj coordinate operation to use when
reprojecting between two CRSes
2019-12-21 05:07:39 +10:00
Nyall Dawson
c04d4faf7f Allow double-clicking on coordinate operation to quickly select them 2019-12-21 05:07:39 +10:00
Nyall Dawson
f0f63d3802 Use QgsCoordinateOperationWidget in QgsDatumTransformDialog 2019-12-21 05:07:39 +10:00
Nyall Dawson
cb8b4a8831 Move guts of datum transformation dialog to a new standalone widget
QgsCoordinateOperationWidget

This widget shows a list of the available operations between a source
and destination CRS along with their properties
2019-12-21 05:07:39 +10:00
Matthias Kuhn
2a01772e46
Merge pull request #33436 from signedav/relating_values
List referenced layer values in Expression Builder
2019-12-20 17:29:10 +01:00
David Signer
ea912a170c since information 2019-12-20 09:39:50 +01:00
Peter Petrik
d211de2204
Other average methods 3d mesh (#33426)
[FEATURE] [MESH] add new 3d stacked mesh averaging methods (top, bottom, sigma, depth, height, elevation)

see https://fvwiki.tuflow.com/index.php?title=Depth_Averaging_Results for description of the methods. method can be selected for 3d stacked mesh dataset in the new widget added for QGIS 3.12 in the mesh layer styling dialog
2019-12-20 07:48:39 +01:00
Nyall Dawson
80be192d8f Fix doxygen warning 2019-12-20 12:13:06 +10:00
Nyall Dawson
b7a440938c Layout fixes 2019-12-20 12:13:06 +10:00
Nyall Dawson
fdf211a8a3 Add a method for retrieving a user friendly descriptive string for
a CRS

And use this wherever we show CRS values to users
2019-12-20 12:13:06 +10:00
Nyall Dawson
e152685d97 Cleanup handling of recent CRS list, add tests 2019-12-20 12:13:06 +10:00
Nyall Dawson
cbc1ee56cc Deprecate most methods which construct CRSes from internal CRS ids
These should NOT be used, and auth:code or WKT definitions used instead.

Unfortunately some use of these methods are very heavily entangled around
other code, so we can't deprecate all of them until 4.0
2019-12-20 12:13:06 +10:00
Nyall Dawson
c76813c434 Deprecate methods for constructing CRS from Postgis srids
Constructing CRS using Postgis srids is highly discouraged,
and instead CRSes should always be constructed using auth:id
codes or WKT strings.

QGIS 4.0: The logic should be isolated into the postgres
provider alone, and not exposed to stable API
2019-12-20 12:13:06 +10:00
Nyall Dawson
b37dd0984e Rip off a band aid, and deprecate all "proj4" calls from the API
Alias these across to new "proj" methods, which don't include the
version number.
2019-12-20 12:13:06 +10:00
David Signer
1f1a3fe6b7 pass field formatter context as a reference instead of a pointer to implify his not optionality 2019-12-19 21:08:02 +01:00
signedav
7f9aa3d2bb
Merge branch 'master' into relating_values 2019-12-19 14:12:38 +00:00
David Signer
e8b82c15b8 use of context to pass project and avoid QgsProject::instance() 2019-12-19 15:07:52 +01:00
Alessandro Pasotti
90ac90b4a9 Weak relations and auto-restore when loading a style 2019-12-19 10:33:24 +01:00
David Signer
9e5657c8fe use of QVariantList instead of QList<QVariant> 2019-12-19 10:15:33 +01:00
Alessandro Pasotti
ecff2e6e04
Merge pull request #33462 from elpaso/stored-expressions-no-groups
[feature] User expressions followup
2019-12-18 20:59:27 +01:00
Alessandro Pasotti
a8c0e4cbf6 User expressions followup
- renamed the group to "User"
- added help text for the group
- added QgsSettings Expressions namespace
- reworded tooltips for store/remove actions
2019-12-18 14:24:02 +01:00