Class: QgsAbstractRelationEditorWidgetFactory

class qgis.gui.QgsAbstractRelationEditorWidgetFactory

Bases: sip.wrapper

Factory class for creating relation widgets and their corresponding config widgets

New in version 3.18.

QgsAbstractRelationEditorWidgetFactory() Creates a new relation widget factory with given name

QgsAbstractRelationEditorWidgetFactory(QgsAbstractRelationEditorWidgetFactory)

Methods

configWidget

Override this in your implementation.

create

Override this in your implementation.

name

Returns the human readable identifier name of this widget type

type

Returns the machine readable identifier name of this widget type

configWidget(self, relation: QgsRelation, parent: QWidget)QgsAbstractRelationEditorConfigWidget

Override this in your implementation. Create a new configuration widget for this widget type.

Parameters
  • relation (QgsRelation) – The relation for which the widget will be created

  • parent (QWidget) – The parent widget of the created config widget

Return type

QgsAbstractRelationEditorConfigWidget

Returns

A configuration widget

create(self, config: Dict[str, Any], parent: QWidget = None)QgsAbstractRelationEditorWidget

Override this in your implementation. Create a new relation widget. Call QgsEditorWidgetRegistry.create() instead of calling this method directly.

Parameters
  • config (Dict[str) – The widget configuration to build the widget with

  • parent (QWidget = None) – The parent for the wrapper class and any created widget.

Return type

QgsAbstractRelationEditorWidget

Returns

A new widget wrapper

name(self)str

Returns the human readable identifier name of this widget type

Return type

str

type(self)str

Returns the machine readable identifier name of this widget type

Return type

str