Class: QgsProcessingParameterDefinitionWidget¶
- class qgis.gui.QgsProcessingParameterDefinitionWidget¶
Bases:
PyQt5.QtWidgets.QWidget
A widget which allow users to specify the properties of a Processing parameter.
New in version 3.10.
QgsProcessingParameterDefinitionWidget(type: str, context:
QgsProcessingContext
, widgetContext:QgsProcessingParameterWidgetContext
, definition:QgsProcessingParameterDefinition
= None, algorithm:QgsProcessingAlgorithm
= None, parent: QWidget = None) Constructor forQgsProcessingParameterDefinitionWidget
, for a parameter of the specifiedtype
.The
context
argument must specify a Processing context, which will be used by the widget to evaluate existingdefinition
properties such as default values. Similarly, thewidgetContext
argument specifies the wider GUI context in which the widget will be used.The optional
definition
argument may be used to provide a parameter definition to use to initially populate the widget’s state.Additionally, the optional
algorithm
parameter may be used to specify the algorithm or model associated with the parameter.Methods
Returns a new instance of a parameter definition, using the current settings defined in the dialog.
Registers a Processing context
generator
class that will be used to retrieve a Processing context for the widget when required.- actionEvent(self, QActionEvent)¶
- changeEvent(self, QEvent)¶
- childEvent(self, QChildEvent)¶
- closeEvent(self, QCloseEvent)¶
- connectNotify(self, QMetaMethod)¶
- contextMenuEvent(self, QContextMenuEvent)¶
- create(self, window: PyQt5.sip.voidptr = 0, initializeWindow: bool = True, destroyOldWindow: bool = True)¶
- createParameter(self, name: str = '') QgsProcessingParameterDefinition ¶
Returns a new instance of a parameter definition, using the current settings defined in the dialog.
The
name
parameter specifies the name for the newly created parameter.- Parameters:
name (str = '') –
- Return type:
- customEvent(self, QEvent)¶
- destroy(self, destroyWindow: bool = True, destroySubWindows: bool = True)¶
- disconnectNotify(self, QMetaMethod)¶
- dragEnterEvent(self, QDragEnterEvent)¶
- dragLeaveEvent(self, QDragLeaveEvent)¶
- dragMoveEvent(self, QDragMoveEvent)¶
- dropEvent(self, QDropEvent)¶
- enterEvent(self, QEvent)¶
- event(self, QEvent) bool ¶
- focusInEvent(self, QFocusEvent)¶
- focusNextChild(self) bool ¶
- focusNextPrevChild(self, bool) bool ¶
- focusOutEvent(self, QFocusEvent)¶
- focusPreviousChild(self) bool ¶
- hideEvent(self, QHideEvent)¶
- initPainter(self, QPainter)¶
- inputMethodEvent(self, QInputMethodEvent)¶
- isSignalConnected(self, QMetaMethod) bool ¶
- keyPressEvent(self, QKeyEvent)¶
- keyReleaseEvent(self, QKeyEvent)¶
- leaveEvent(self, QEvent)¶
- metric(self, QPaintDevice.PaintDeviceMetric) int ¶
- mouseDoubleClickEvent(self, QMouseEvent)¶
- mouseMoveEvent(self, QMouseEvent)¶
- mousePressEvent(self, QMouseEvent)¶
- mouseReleaseEvent(self, QMouseEvent)¶
- moveEvent(self, QMoveEvent)¶
- nativeEvent(self, Union[QByteArray, bytes, bytearray], PyQt5.sip.voidptr) Tuple[bool, int] ¶
- paintEvent(self, QPaintEvent)¶
- receivers(self, PYQT_SIGNAL) int ¶
- registerProcessingContextGenerator(self, generator: QgsProcessingContextGenerator)¶
Registers a Processing context
generator
class that will be used to retrieve a Processing context for the widget when required.New in version 3.18.
- Parameters:
generator (QgsProcessingContextGenerator) –
- resizeEvent(self, QResizeEvent)¶
- sender(self) QObject ¶
- senderSignalIndex(self) int ¶
- showEvent(self, QShowEvent)¶
- tabletEvent(self, QTabletEvent)¶
- timerEvent(self, QTimerEvent)¶
- updateMicroFocus(self)¶
- wheelEvent(self, QWheelEvent)¶