Class: QgsAggregateToolButton¶
Offers a toolbutton to choose between different aggregate functions.
Functions are filtered based on the type.
Class Hierarchy¶
Base classes¶
Methods
When this flag is |
|
The function name of the selected aggregate or a Null String if none is chosen. |
|
When this flag is |
|
The function name of the selected aggregate or a Null String if none is chosen. |
|
Based on the type of underlying data, some aggregates will be available or not. |
|
Based on the type of underlying data, some aggregates will be available or not. |
Signals
A function has been selected or deselected. |
|
The function name of the selected aggregate has changed. |
- class qgis.gui.QgsAggregateToolButton[source]¶
Bases:
QToolButton
- __init__()
Constructor
- active(self) bool [source]¶
When this flag is
False
, the aggregate will be deactivated. I.e. no aggregate is chosen.- Return type:
bool
- aggregate(self) str [source]¶
The function name of the selected aggregate or a Null String if none is chosen.
- Return type:
str
- setActive(self, active: bool)[source]¶
When this flag is
False
, the aggregate will be deactivated. I.e. no aggregate is chosen.- Parameters:
active (bool)
- setAggregate(self, aggregate: str | None)[source]¶
The function name of the selected aggregate or a Null String if none is chosen.
- Parameters:
aggregate (Optional[str])
- setType(self, type: QMetaType.Type)[source]¶
Based on the
type
of underlying data, some aggregates will be available or not.- Parameters:
type (QMetaType.Type)
- setType(self, type: QVariant.Type)[source]
Based on the
type
of underlying data, some aggregates will be available or not.Deprecated since version 3.38: Use the method with a QMetaType.Type argument instead.
- Parameters:
type (QVariant.Type)