Navigation Menu

Skip to content

Commit

Permalink
Fix QgsProcessingParameterNumber docstring example
Browse files Browse the repository at this point in the history
(cherry picked from commit 66011b2)
  • Loading branch information
SrNetoChan authored and nyalldawson committed Sep 25, 2020
1 parent c763387 commit 279c499
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Expand Up @@ -1954,7 +1954,7 @@ shown in the parameter's widget can be specified by setting the parameter's meta

.. code-block:: python

param = QgsProcessingParameterNumber( 'VAL', 'Threshold', type=QgsProcessingParameter.Double)
param = QgsProcessingParameterNumber( 'VAL', 'Threshold', type=QgsProcessingParameterNumber.Double)
# only show two decimal places in parameter's widgets, not 6:
param.setMetadata( {'widget_wrapper':
{ 'decimals': 2 }
Expand Down
2 changes: 1 addition & 1 deletion src/core/processing/qgsprocessingparameters.h
Expand Up @@ -1947,7 +1947,7 @@ class CORE_EXPORT QgsProcessingParameterMultipleLayers : public QgsProcessingPar
* shown in the parameter's widget can be specified by setting the parameter's metadata. For example:
*
* \code{.py}
* param = QgsProcessingParameterNumber( 'VAL', 'Threshold', type=QgsProcessingParameter.Double)
* param = QgsProcessingParameterNumber( 'VAL', 'Threshold', type=QgsProcessingParameterNumber.Double)
* # only show two decimal places in parameter's widgets, not 6:
* param.setMetadata( {'widget_wrapper':
* { 'decimals': 2 }
Expand Down

0 comments on commit 279c499

Please sign in to comment.