67 Commits

Author SHA1 Message Date
Nyall Dawson
8ffdb362cc Port some processing dataobjects routines to c++ 2017-04-05 15:27:17 +10:00
Nyall Dawson
ce7180ca64 [processing] Default to current layer in layer selection combos
Makes things easier for large projects and avoids scrolling through
a large list of layers
2017-03-21 10:26:58 +10:00
Matteo Ghetta
3bcf287a7e Processing tests (#4259)
* [processing] qgis regular points test

* [processing] qgis shape buffer variable tests

* [processing] qgis create grid lines test

* [processing] qgis convert geometry test

* [processing] qgis extract by location test

* [processing] qgis add field test

* [processing] trying to fix travis failing

* [processing] trying to fix travis failing/2

* trying to fix travis failing/3

* [processing] Add new default option "ProjectCrs" to ParameterCrs

* [processing] RegularPoints tests shouldn't rely on iface

* [processing] Fix regular points test

* [processing] RandmPointsExtent new CRS parameter

* [processing] qgis random point in extent test

* [processing] qgis random point in extent test/2

* [processing] remove qgis random point in extent test

* no output random points in extent test

* remove useless output
2017-03-16 16:42:53 +01:00
Juergen E. Fischer
ecc5bb508e pep8/pyflakes3 cleanups 2017-03-04 02:38:15 +01:00
Juergen E. Fischer
a10c890383 More QgsSettings updates:
* revives WMS
* QgsSettings::clear() added
* section added to QgsSettings::contains()
* type parameter added to sip binding of QgsSettings.value()
* TODO: customization & evis
2017-03-04 02:37:59 +01:00
Nyall Dawson
5312965e61 Rename projection selection widgets and cleanup API
The current names for QgsProjectionSelector and
QgsGenericProjectionSelector are confusing
2017-02-28 09:45:31 +10:00
Alexander Bruy
441f6e6e6e Merge pull request #4120 from arnaud-morvan/processing_fix_boolean_wrapper
[processing] fix boolean widget wrapper in batch dialog
2017-02-16 14:45:25 +02:00
volaya
cdb35d6288 Merge pull request #4119 from arnaud-morvan/processing_postgis_wrappers
[processing] Add PostGIS widget wrappers
2017-02-16 11:12:30 +01:00
Alexander Bruy
cc1adc528e [processing] handle case when default CRS is None and parameter is not optional 2017-02-10 17:39:45 +02:00
arnaud.morvan@camptocamp.com
f07154b613 [processing] Remove obsolete GeometryPredicateWidgetWrapper 2017-02-10 11:16:38 +01:00
arnaud.morvan@camptocamp.com
337d1889b8 [processing] Use ExpressionWidgetWrapperMixin in StringWidgetWrapper 2017-02-10 11:14:34 +01:00
arnaud.morvan@camptocamp.com
c768edf9d1 [processing] Add postgis widget wrappers 2017-02-10 11:01:41 +01:00
arnaud.morvan@camptocamp.com
dda667023a [processing] Add class ExpressionEnabledWidgetWrapper 2017-02-09 17:04:58 +01:00
arnaud.morvan@camptocamp.com
482aadc495 [processing] Add possibility to pass additionnal parameters to widget wrapper 2017-02-09 16:12:16 +01:00
arnaud.morvan@camptocamp.com
3a12f2a0b6 Fix Boolean widget wrapper in batch dialog 2017-02-09 11:14:05 +01:00
Juergen E. Fischer
a61b9222de Qt 5.2 has QComboBox::currentData 2017-01-25 03:28:53 +01:00
nirvn
c365439140 [processing] fix error in MultipleInputWidgetWrapper 2016-12-20 14:38:52 +07:00
volaya
0035c97f5b Merge pull request #3725 from arnaud-morvan/processing_geometry_predicate
[processing] Remove parameter geometry predicate
2016-12-13 15:58:16 +01:00
arnaud.morvan@camptocamp.com
322a565b8b [processing] Remove ParameterGeometryPredicate 2016-12-12 15:21:16 +01:00
arnaud.morvan@camptocamp.com
65a4e97a75 [processing] Support options as (value, text) in ParameterSelection 2016-12-12 15:12:55 +01:00
Nyall Dawson
bef5b5ed68 [processing][heatmap] custom parameter/widget for output resolution
Matches current behaviour of c++ heatmap plugin
2016-12-07 12:23:58 +10:00
Alexander Bruy
2fea23f1e5 Merge pull request #3779 from volaya/rastercalculator
[processing] add native raster calculator
2016-12-05 20:03:23 +02:00
volaya
16da906398 [processing] allow multiple selection of tables 2016-12-05 13:39:38 +01:00
volaya
fcc343724e [processing] some fixes and changes in parameters and parameters panel 2016-12-01 12:50:27 +01:00
Nyall Dawson
08505b388a [processing] Allow restricting fields to date/time types 2016-11-30 15:04:21 +10:00
Nyall Dawson
fb8b931a8e [processing] Fix error with field widget wrapper 2016-11-17 13:09:23 +10:00
Nyall Dawson
964ecfd743 Fix build 2016-11-17 09:04:19 +10:00
Nyall Dawson
fc65334a60 [processing] Add file picker to vector/raster/table parameters
in modeller

Makes it obvious that users can set an algorithm vector/raster/
table input to a fixed table
2016-11-17 09:04:19 +10:00
Nyall Dawson
f78f2a05c6 [processing] Use native QGIS map layer combobox
Switches the custom map layer combo box used in the run algorithm
dialog across to the standard QGIS map layer combo box
2016-11-17 09:04:19 +10:00
volaya
ff691a6bc4 Merge pull request #3747 from nyalldawson/num_input
[processing] Restore spin box widget for number inputs outside modeller
2016-11-16 13:59:25 +01:00
Nyall Dawson
d3f5314bf5 [processing] Use standard field combo box for field choices 2016-11-15 07:00:35 +10:00
Nyall Dawson
dbf6107b14 [processing] Add button for projection selection dialog to
Crs parameters in algorithm settings in modeler

This makes it easier to pick static CRSes for the parameter,
and also makes it obvious to users that they can use a fixed
CRS parameter in their model (as opposed to one taken from
a layer or input)
2016-11-13 20:34:35 +10:00
Nyall Dawson
3ef7b3b7eb [processing] Use standard QGIS projection selection widget for CRS params 2016-11-13 20:34:35 +10:00
Nyall Dawson
28d7ceaef5 Some fixes to processing expression parameters 2016-11-11 20:13:12 +10:00
Nyall Dawson
5625d6e9b6 Expression parameters don't have to have parent layers 2016-11-11 13:26:31 +10:00
Nyall Dawson
132e76a596 [FEATURE][processing] New input type for expressions
This adds a new input type for expression inputs. Expression
inputs can be linked to a parent layer so that the builder
shows the correct fields and layer variables.

It's designed for two use cases:

1. to be used when an algorithm specifically requires an expression,
eg Select by Expression and Extract by Expression.

2. to be potentially used as a replacement input instead of string
or number literals in algorithms. Eg - if the simplify algorithm
tolerance parameter was replaced with an expression paremeter, then
this expression would be evaluated for every feature before
simplifying that feature. It would allow parameters to be calculated
per feature, as opposed to the current approach of calculating
a parameter once before running the algorithm. It would also
mean algorithms like "variable distance buffer" would no longer
be needed, as a single "buffer" algorithm could then be used
for either a fixed distance, field based, or expression based
distance.
2016-11-11 13:26:31 +10:00
Nyall Dawson
72118f91f9 [processing] When an algorithm has string parameters, also
accept numeric, file and table field inputs in modeler

This allows a non-string parameter to be reused as a string
parameter in contexts where it makes sense.
2016-11-11 13:26:31 +10:00
Nyall Dawson
a3ae0b28fc [processing] Restore spin box widget for number inputs outside modeller
This commit restores some pre 3.0 processing behaviour for number inputs.
Now, if a number input is required outside of modeller than a spin box
will be shown instead of a free text input.

Clicking the expression builder button results in an expression
which is evaluated immediately to avoid users expecting that
the expression will be evaluated per feature.
2016-11-11 11:02:42 +10:00
arnaud.morvan@camptocamp.com
4a62699472 [processing] Fix TableWidgetWrapper in batch dialog 2016-11-06 13:05:32 +01:00
Nyall Dawson
3caccd531d [processing] Fix handling of multiple field input in modeller 2016-10-31 11:41:40 +10:00
Nyall Dawson
3cc9b5d962 Indentation 2016-10-22 09:03:24 +10:00
arnaud.morvan@camptocamp.com
4184934b9a [processing] Apply 2to3 on changes 2016-10-05 12:39:01 +02:00
volaya
effcb5ed14 [processing] [modeler] show options of MultipleInputParameter sorted in alphabetical order
fixes # 4836
2016-10-05 12:38:59 +02:00
volaya
404c57bc59 [processing] fixed table fields in batch processing interface
Conflicts:
	python/plugins/processing/gui/BatchInputSelectionPanel.py
2016-10-05 12:38:58 +02:00
volaya
23aec61501 [processing] connect signal in multipleinput widget 2016-10-05 12:38:57 +02:00
volaya
b2fd1a4560 [processing] use cmp_to_key to ensure Python3 compatibility
Conflicts:
	python/plugins/processing/gui/wrappers.py
2016-10-05 12:38:53 +02:00
Alexander Bruy
3407ced90e fix indentation
Conflicts:
	python/plugins/processing/gui/BatchInputSelectionPanel.py
	python/plugins/processing/gui/wrappers.py
2016-10-05 12:38:50 +02:00
volaya
a20c86c0c3 [processing] use InputLayerSelectorPanel for vector layers 2016-10-05 12:38:49 +02:00
volaya
c605c67b8c [processing] some minor changes for batch processing interface 2016-10-05 12:38:48 +02:00
arnaud.morvan@camptocamp.com
d33e33874a Fix StringWidgetWrapper.value method 2016-10-05 12:38:47 +02:00