11529 Commits

Author SHA1 Message Date
Nyall Dawson
5ee9cdd222 Rename layerRenderingTime()->perLayerRenderingTime() 2017-12-05 09:02:40 +10:00
Nyall Dawson
01e8ed85e3 More flexible API for preview job determination 2017-12-05 09:02:40 +10:00
Nyall Dawson
16a1bd7948 Store previous layer rendering time in canvas, not map layer 2017-12-05 09:02:40 +10:00
Even Rouault
997619c9ed [Rendering] Only render in preview jobs layers that are fast enough
This implements the improvements discussed in the mailing list thread
https://lists.osgeo.org/pipermail/qgis-developer/2017-November/050524.html
to avoid rendering layers in preview jobs that take too much time to render.
2017-12-05 09:02:40 +10:00
Nyall Dawson
32ba5bf23f
Merge pull request #5791 from nyalldawson/geom_snapper_vertices
Fix geometry snapper sometimes creates unwanted overlapping segments when snapping line layers
2017-12-05 09:47:27 +11:00
Nathan Woodrow
57dc9deb06
Add API to ease saving and restoring widget geometry. (#5615)
Usage:
 - QgsGui::instance()->enableAutoGeometryRestore( this ); just
after setupUi in your widgets to enable.
 - Remove any calls to saveGeometry() and restoreGeometry() in your
widgets.
2017-12-04 13:41:42 +10:00
Nyall Dawson
21fe98d5f0 Sipify 2017-12-04 13:10:28 +10:00
Nyall Dawson
5a818707c7 Update tests 2017-12-03 17:06:20 +10:00
Nyall Dawson
5b5560aaf9 Set default method for check validity alg 2017-12-03 15:16:17 +10:00
Nyall Dawson
5b05699fc9 Add some tags to check validity algorithm 2017-12-03 14:58:21 +10:00
Nyall Dawson
e12621ce2a Add API method to remove duplicate nodes from geometries
Removes duplicate nodes from the geometry, wherever removing the
nodes does not result in a degenerate geometry.

By default, z values are not considered when detecting duplicate
nodes. E.g. two nodes with the same x and y coordinate but
different z values will still be considered duplicate and one
will be removed. If useZValues is true, then the z values are
also tested and nodes with the same x and y but different z
will be maintained.

Note that duplicate nodes are not tested between different
parts of a multipart geometry. E.g. a multipoint geometry
with overlapping points will not be changed by this method.

The function will return true if nodes were removed, or false
if no duplicate nodes were found.

Includes unit tests and a processing algorithm which exposes
this functionality.
2017-12-03 14:58:21 +10:00
Nyall Dawson
0b452cabbb Spelling 2017-12-03 08:03:30 +10:00
Nyall Dawson
928afdd8c5 Fix geometry snapper sometimes creates unwanted overlapping segments
when snapping line layers

Because the default behavior of the snapper is to insert extra
vertices into the snapped geometry in order to make it 'follow'
the reference geometries exactly, this can result in unwanted
results for line layers where the resultant snapped layer
has overlapping line segments.

Since we can't always know what the desired result is that the
user wants (maybe they do want overlapping lines), instead
give them control over the result by exposing extra enum
options which never insert extra vertices.
2017-12-03 07:10:42 +10:00
Martin Dobias
f8788b9185 [3d] Fix style copy/paste for 3D renderer (fixes #17540) 2017-12-02 09:32:23 +01:00
Nyall Dawson
389435e1a0
Merge pull request #5729 from nyalldawson/proc_dyanmic
[processing] Expose dynamic ("data defined") numeric parameters to gui
2017-12-02 14:32:45 +11:00
Nyall Dawson
1625d1fa2c Disable direct parameter value input when data defined override is set 2017-12-02 11:17:19 +10:00
Nyall Dawson
8c9147eabd [processing] Make set m value accept dynamic m values 2017-12-02 11:17:19 +10:00
Nyall Dawson
d1a71f0971 Update algorithms for new API 2017-12-02 11:17:19 +10:00
Nyall Dawson
86958937ad Tweak processing API to better handle dynamic properties 2017-12-02 11:17:19 +10:00
Nyall Dawson
58ab507717 Fix failing test 2017-12-02 11:17:18 +10:00
Nyall Dawson
4b464f3d68 [processing] Allow data defined z value for "set z value" algorithm
Allows easy setting of z from an existing height attribute!
2017-12-02 11:17:18 +10:00
Nyall Dawson
901dae1110 [processing] Expose data defined button for dynamic numeric parameters
When running algorithms through the toolbox, which have dynamic
numeric parameters, add a data defined property override button
next to the widget so that users can set the overrides for these
parameters.

Previously this was available only in the backend, but not
exposed anywhere in the GUI.

Note that currently no algorithms support dynamic parameters,
so don't expect to see this everywhere. It's also only available
in toolbox/batch processing modes, not in models.
2017-12-02 11:17:18 +10:00
Nyall Dawson
ecbc4718d4 [processing] Some more framework for dynamic (data defined) parameters 2017-12-02 11:16:26 +10:00
Nyall Dawson
618baf925d Small refactor of QgsPropertyOverrideButton 2017-12-02 11:13:31 +10:00
Nyall Dawson
5f77a48e10 Remember window geometry for raster save dialog 2017-12-02 11:11:45 +10:00
Nyall Dawson
9e4518fe42 [FEATURE] More output format choices in raster save as dialog
Previously only geotiff format was available, even though the
underlying QgsRasterFileWriter/GDAL libraries support other
formats.

This commit exposes those other formats to the dialog so that
users can directly save rasters to them (including everyone's
new BFF, geopackage).
2017-12-02 11:11:45 +10:00
Nyall Dawson
6b23e1f299
Merge pull request #5600 from Gustry/sortby
add order by expression algorithm
2017-12-02 11:43:48 +11:00
Alessandro Pasotti
19b062c304
Merge pull request #5766 from Gustry/file_downloader
Display the downloaded size in QgsFileDownloaderDialog
2017-12-01 14:30:34 +01:00
Nyall Dawson
1c1de3a88b [processing] Fix optional numeric parameters cannot be cleared
Without this change optional numeric parameters have no way to
be cleared in the GUI - they are always forced to have a value

Fixes #17471 - but I've noticed that many optional numeric
GRASS parameters have a non-null default value. These may
need to be investigated and manually changed to None defaults
in the description files.
2017-12-01 20:42:38 +11:00
Nyall Dawson
db855029de Fix not-set defaults for numeric parameters were converted to 0 2017-12-01 20:42:38 +11:00
Nyall Dawson
297e8561a0 Bump lowest possible min for numeric parameters to -DBL_MAX + 1
We need to reserve -DBL_MAX as a special value, to allow it to
work correctly in QDoubleSpinBoxes (limitation of QDoubleSpinBox)
2017-12-01 20:42:38 +11:00
Nyall Dawson
6b56565f89 Show nicer tooltips for numeric processing parameters
With min/max and default values (when set)
2017-12-01 20:42:38 +11:00
Nyall Dawson
8303b94685 [processing] Fix optional layer parameters are filled by default
Refs #17471

Not a full fix for 17471 - that requires handling of optional
numeric values too
2017-12-01 20:42:38 +11:00
Nyall Dawson
8026008ae7 [processing] group option for autoincrement field algorithm 2017-12-01 20:42:38 +11:00
Alessandro Pasotti
62ff88af03
Merge pull request #5737 from elpaso/hidpi-cursors
[bugfix][hidpi] Scalable SVG theme cursors
2017-12-01 09:52:32 +01:00
Nyall Dawson
f6e63d7f4c Fixes and cleanups to algorithm dialogs 2017-12-01 18:15:40 +11:00
Nyall Dawson
ce170918c9 Start moving processing algorithm dialog to c++
In an attempt to avoid Python global interpreter locks which
block the UI thread.
2017-12-01 18:15:40 +11:00
Nyall Dawson
3c238a2ba4 Add missing overrides 2017-12-01 15:47:53 +10:00
Nyall Dawson
bcc1b91b74
Merge pull request #5717 from nyalldawson/layout_next4
[layouts] Port/adapt all remaining item types
2017-12-01 13:43:58 +11:00
Nyall Dawson
c12770d041 Indentation 2017-12-01 10:00:42 +11:00
Nyall Dawson
d7111b7849 Standardise some algorithm names 2017-12-01 10:00:42 +11:00
Nyall Dawson
e1ce7dda70 Show algorithm ID in tooltip in toolbox 2017-12-01 10:00:42 +11:00
Etienne Trimaille
7303297d7f add some notes in processing test readme 2017-11-30 15:22:13 +01:00
Etienne Trimaille
1b8faa2a79 add sort by expression algorithm 2017-11-30 15:22:13 +01:00
Etienne Trimaille
88054a3744 display the downloaded size in QgsFileDownloaderDialog 2017-11-30 14:29:24 +01:00
Blottiere Paul
3b7d2e3360
Merge pull request #5762 from pblottiere/fix_typo_as
Fixes typos in auxiliary storage documentation
2017-11-30 07:43:17 +00:00
Tim Sutton
f6acf37637
Fix processing errors on startup and execution on MacOS (#5769) 2017-11-30 07:17:12 +02:00
nirvn
f5702abae9 [processing] fix DlgModeler.ui layout warnings 2017-11-30 12:12:23 +07:00
Salvatore Larosa
d7485a4349 [pyqgis-console] fix strings in options tooltips 2017-11-29 17:45:46 +01:00
Matteo Ghetta
a10e753820 processing test for difference algorithm (#5764) 2017-11-29 15:25:30 +01:00