Class: QgsCalloutPanelWidget¶
A panel widget for configuration of callouts.
Added in version 3.40.
QgsCalloutPanelWidget¶
Class Hierarchy¶
Base classes¶
Base class for any widget that can be shown as an inline panel. |
|
Methods
Returns a new callout, respecting the configuration from the widget. |
|
Returns the context in which the widget is shown, e.g., the associated map canvas and expression contexts. |
|
Returns the geometry type for the objects associated with the callouts. |
|
Sets the widget state to match the specified callout. |
|
Sets the context in which the widget is shown, e.g., the associated map canvas and expression contexts. |
|
Sets the geometry type for the objects associated with the callouts. |
Signals
Emitted when the callout defined by the widget changes |
- class qgis.gui.QgsCalloutPanelWidget[source]¶
Bases:
QgsPanelWidget- __init__(parent: QWidget | None = None, layer: QgsMapLayer | None = None)
Constructor for QgsCalloutPanelWidget, with the specified
parentwidgetThe optional
layerargument can be set to an associated map layer.- Parameters:
parent (Optional[QWidget] = None)
layer (Optional[QgsMapLayer] = None)
- callout(self) QgsCallout | None[source]¶
Returns a new callout, respecting the configuration from the widget.
See also
- Return type:
Optional[QgsCallout]
- context(self) QgsSymbolWidgetContext[source]¶
Returns the context in which the widget is shown, e.g., the associated map canvas and expression contexts.
See also
- Return type:
- geometryType(self) Qgis.GeometryType[source]¶
Returns the geometry type for the objects associated with the callouts.
If the type is
Qgis.GeometryType.Unknown then an attempt will be made to deduce the type from the associated map layer.See also
- Return type:
- setCallout(self, callout: QgsCallout | None)[source]¶
Sets the widget state to match the specified
callout.Ownership is not transferred.
See also
- Parameters:
callout (Optional[QgsCallout])
- setContext(self, context: QgsSymbolWidgetContext)[source]¶
Sets the
contextin which the widget is shown, e.g., the associated map canvas and expression contexts.See also
- Parameters:
context (QgsSymbolWidgetContext)
- setGeometryType(self, type: Qgis.GeometryType)[source]¶
Sets the geometry
typefor the objects associated with the callouts.If
typeisQgis.GeometryType.Unknown then an attempt will be made to deduce the type from the associated map layer.See also
- Parameters:
type (Qgis.GeometryType)