[processing][needs-docs] Hide variable distance buffer from toolbox

This algorithm has become a model-only algorithm, since it's
functionality is now present in the native c++ buffer algorithm
(which can now buffer by field or expression).

Ideally we'd remove this algorithm entirely, but data defined
parameters are not yet supported by the modeler gui, so we need
to keep it around for use in models for now.
This commit is contained in:
Nyall Dawson 2018-01-15 13:38:34 +10:00
parent ecd113de24
commit 17478ea51a

View File

@ -31,6 +31,7 @@ from qgis.PyQt.QtGui import QIcon
from qgis.core import (QgsWkbTypes,
QgsProcessing,
QgsProcessingAlgorithm,
QgsProcessingParameterFeatureSource,
QgsProcessingParameterField,
QgsProcessingParameterNumber,
@ -67,6 +68,9 @@ class VariableDistanceBuffer(QgisAlgorithm):
def __init__(self):
super().__init__()
def flags(self):
return QgsProcessingAlgorithm.FlagSupportsBatch | QgsProcessingAlgorithm.FlagCanCancel | QgsProcessingAlgorithm.FlagHideFromToolbox
def initAlgorithm(self, config=None):
self.addParameter(QgsProcessingParameterFeatureSource(self.INPUT,
self.tr('Input layer')))