Class: QgsPlotAbstractMetadata

Stores metadata about a plot class.

Note

In C++ you can use QgsPlotAbstractMetadata convenience class.

Added in version 4.0.

Note

This is an abstract class, with methods which must be implemented by a subclass.

The following methods must be implemented: createPlot(), createPlotDataGatherer(), createPlotWidget()

Abstract Methods

createPlot

Creates a plot of this class.

createPlotDataGatherer

Creates a plot data gatherer of this class.

createPlotWidget

Creates a widget for configuring plot of this type.

Methods

type

Returns the unique type code for the plot class.

visibleName

Returns a translated, user visible name for the plot class.

class qgis.core.QgsPlotAbstractMetadata[source]

Bases: object

__init__(type: str | None, visibleName: str | None)

Constructor for QgsPlotAbstractMetadata with the specified class type.

Parameters:
  • type (Optional[str])

  • visibleName (Optional[str])

__init__(a0: QgsPlotAbstractMetadata)
Parameters:

a0 (QgsPlotAbstractMetadata)

abstract createPlot(self) QgsPlot | None[source]

Creates a plot of this class.

Return type:

Optional[QgsPlot]

abstract createPlotDataGatherer(self, plot: QgsPlot | None = None) QgsVectorLayerAbstractPlotDataGatherer | None[source]

Creates a plot data gatherer of this class.

Parameters:

plot (Optional[QgsPlot] = None)

Return type:

Optional[QgsVectorLayerAbstractPlotDataGatherer]

abstract createPlotWidget(self, parent: QWidget | None = None) QgsPlotWidget | None[source]

Creates a widget for configuring plot of this type. Can return None if there’s no GUI registered.

Ownership of the widget is transferred to the caller.

Parameters:

parent (Optional[QWidget] = None)

Return type:

Optional[QgsPlotWidget]

type(self) str[source]

Returns the unique type code for the plot class.

Return type:

str

visibleName(self) str[source]

Returns a translated, user visible name for the plot class.

Return type:

str