6691 Commits

Author SHA1 Message Date
Nyall Dawson
689ea67e74
Fix algorithm string conformance 2025-05-15 13:08:36 +10:00
Nyall Dawson
158b4a6b0d
Add conformance tests for algorithm descriptions 2025-05-15 13:08:36 +10:00
viperminiq
f11e2430d0 fix colliding fields in processing algs 2025-05-10 08:15:30 +02:00
Nyall Dawson
fa80bcfd5d [processing] Port SAGA "Fill Sinks Wang & Liu" to native tool
Based on tickets/stackexchange posts/mailing list activity, this
seems to be a highly in demand tool which is fragile and error
prone when run via the SAGA Processing Plugin.

Port to a native tool to avoid this situation, and give a nice
optimised out-of-the-box tool.

Note that this is functionally a 1:1 clone of the SAGA tool. I've
verified that the outputs match SAGAs outputs, but any bugs
present in the SAGA implementation will also be present here.
2025-05-07 13:35:28 +10:00
Alexander Bruy
4c1d27422b port Convert geometry type algorithm to C++ 2025-05-06 07:48:08 +10:00
Nyall Dawson
6bd91f8381 [processing][api] Add API for an algorithm to auto-set parameter values
Adds an API which an algorithm can implement to support auto-setting
parameter values. This is designed to handle the case
of eg an algorithm which does a file format translation, where
it's desirable to default the output parameter value to an input
parameter value with a different extension.

This can now be done by implementing autogenerateParameterValues
in the algorithm, eg:

    def autogenerateParameterValues(self, existingParameters, changedParameter, mode):
        if changedParameter == self.INPUT:
            input_file = existingParameters.get(self.INPUT)
            if input_file:
                input_path = Path(input_file)
                if input_path.exists():
                    # auto set output parameter to same as input but with 'qgs' extension
                    return {self.OUTPUT: input_path.with_suffix('.qgs').as_posix()}

        return {}

Works for both toolbox and batch modes for algorithms
2025-04-30 13:56:09 +10:00
Nyall Dawson
4220d9f227 Add flag to skip validation of processing parameters 2025-04-30 13:56:09 +10:00
Alexander Bruy
f3a0016f8e update expected file 2025-04-30 06:57:21 +10:00
Alexander Bruy
ed6f09b871 remove old implementation 2025-04-30 06:57:21 +10:00
Alexander Bruy
a0bde0b7a8 port Climb algorithm to C++ 2025-04-30 06:57:21 +10:00
Andrea Giudiceandrea
c4a2e9c6d2 [gui][processing] Fix "Check validity" algorithm ID in menu 2025-04-27 09:53:27 +10:00
Viper MiniQ
7d090fd7b9
fix starting interpolation algs and heatmap, qt6 compatibility 2025-04-25 13:20:02 +10:00
Nyall Dawson
b114e0aef3 Fix duplicate parameter warning in gdal rasterize algorithm 2025-04-24 10:19:56 +10:00
Alexander Bruy
2d1f318bf9 update Processing algorithms to use new enum values 2025-04-23 07:39:24 +10:00
Alexander Bruy
f186288b41 fix TIN and IDW interpolation algorithms and tests 2025-04-23 07:39:24 +10:00
Alexander Bruy
f2b9f60a44 port Check Validity algorithm to C++ 2025-04-21 12:15:13 +01:00
Alexander Bruy
c0491d6997
Merge pull request #61321 from alexbruy/harmonize-create-options-naming
Harmonize terminology related to create options
2025-04-15 08:06:44 +01:00
Alexander Bruy
b5019cbfb0
Merge pull request #60945 from alexbruy/processing-export-geometry-info-cpp
port Add geometry attributes algorithm to C++
2025-04-14 20:04:33 +01:00
Alexander Bruy
598233d881 fix test 2025-04-12 11:00:42 +01:00
Alexander Bruy
5bde6fec42 harmonize parameter name in Processing algorithms 2025-04-12 11:00:42 +01:00
Alexander Bruy
0cbfa928c6 more complete test for merge vector layers algorithm for the case when
fields have different length and precision (follow-up #60842)
2025-04-08 09:20:39 +10:00
Harrissou Sant-anna
60e684df77
Remove optional criteria on "Use logarithmic scale ..." boolean parameters
of vector layer scatterplot algorithm
2025-04-04 11:14:37 +02:00
Alexander Bruy
99b3a5064f
Merge pull request #60842 from ValentinBuira/fix-mergevectorlayer-field-length
Fix processing (unreported) : Merge vector layer algorithm fail in the case a field name already exists but with different length or precision
2025-03-31 08:21:43 +01:00
Valentin Buira
16757ebd40 Remove superfluous metadata from shapefiles 2025-03-26 21:56:06 +01:00
Juergen E. Fischer
d9b5d8c9c5 update_ts.sh: alternatively use pylupdate6 + python translation string fixes 2025-03-23 23:23:02 +01:00
Jan Caha
d981659ecb add types 2025-03-20 10:12:37 +10:00
pre-commit-ci[bot]
117ef4c7d5 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-03-20 10:12:37 +10:00
Jan Caha
b546ba43e4 update strings
Co-authored-by: Nyall Dawson <nyall.dawson@gmail.com>
2025-03-20 10:12:37 +10:00
Jan Caha
ea9ee4088e handle temporary output 2025-03-20 10:12:37 +10:00
Jan Caha
cb3ebba533 all temporary output on selection panel 2025-03-20 10:12:37 +10:00
Valentin Buira
8537bb4791 Fix test attempt 2 2025-03-18 23:43:48 +01:00
Valentin Buira
a9ffc0a455 Merge branch 'master' into fix-mergevectorlayer-field-length 2025-03-18 21:54:33 +01:00
Alexander Bruy
5577990fdc port Export geometry attributes algorithm to C++ 2025-03-13 07:41:31 +00:00
Jean Felder
8bc8941b1d processing/gdal: Ensure to flush the buffer once finished 2025-03-13 07:21:24 +10:00
Jean Felder
5ca6c217f3 processing: Fix voronoipolygons unit test for GEOS 3.12.1 2025-03-13 07:21:24 +10:00
Valentin Buira
c3b65efa20 attempt to fix test 2025-03-12 00:23:00 +01:00
Alexander Bruy
423a5f4245 port Define Projection algorithm to C++ 2025-03-08 11:03:40 +00:00
Valentin Buira
fa8bf9e6ba Add test for merging layers with different field length/precision 2025-03-07 23:54:41 +01:00
Mathieu Pellerin
1aeb8bbdd4 [processing] Fix alg. postprocessing regression failing to add all but one output to the project 2025-02-17 08:35:48 +10:00
pre-commit-ci[bot]
88383c3d16 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-02-15 08:36:08 +10:00
Harrissou Sant-anna
d5c1c6d168 Add help to GDAL raster Slope and Proximity algs parameters
and remove passive form text on labels
2025-02-15 08:36:08 +10:00
Benjamin Jakimow benjamin.jakimow@geo.hu-berlin.de
8054fd816f added test tp check truncation of WIDTh and HEIGHT float values
relates to #60533
2025-02-12 11:32:35 +01:00
pre-commit-ci[bot]
401f6d3844 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-02-12 11:32:35 +01:00
Benjamin Jakimow benjamin.jakimow@geo.hu-berlin.de
d4399cdc84 truncates double inputs to -ts WIDTH HEIGHT 2025-02-12 11:32:35 +01:00
Benjamin Jakimow benjamin.jakimow@geo.hu-berlin.de
d570f81db5 ensures that "gda:rasterize" uses integer numbers as input to -ts parameter
fixes #60524
2025-02-12 11:32:35 +01:00
Alexander Bruy
e5d1543a65
fix typo 2025-02-12 06:33:13 +00:00
Nyall Dawson
0180380076
[processing] Fix exception when algorithm has no output layers
Fixes regression caused by https://github.com/qgis/QGIS/pull/59850
2025-02-12 14:56:48 +10:00
Jean Felder
a46f3e9752 postprocessing: Use QgsLayerTreeRegistryBridge to add layers
When a profile tool is already opened, the output of a procssing is
not added to its layer tree. This is because it relies on a
`QgsLayerTreeRegistryBridge`. Indeed, `QgsLayerTreeRegistryBridge`
listens to the `QgsProject::legendLayersAdded()` signal in order to
update the elevation profile tree view. However this signal is not
triggered by the current logic in `Postprocessing.py`because
`QgsProject::addMaplayer` is called with `addToLegend` set to
False. Then, the layer is added to the tree by calling
`QgsLayerTreeGroup::insertChildNode`.

This issue is fixed by creating a
`QgsLayerTreeRegistryBridge::InsertionPoint` to set the insertion
point and then calling `QgsProject::addMaplayer` with `addToLegend`
set to True.
2025-02-07 10:22:53 +10:00
Alexander Bruy
b6d1d7e8d6 add missed import and fix getThemeIcon() call (follow-up #60261) 2025-02-06 09:54:48 +00:00
Andrea Giudiceandrea
cc53e8a6ef [processing][gui] Fix InterpolationDataWidget
Fix initialisation of "Use Z-coordinate for interpolation" checkbox
2025-02-05 09:30:15 +10:00