Class: QgsReport¶
- class qgis.core.QgsReport¶
Bases:
PyQt5.QtCore.QObject
,QgsAbstractReportSection
,QgsMasterLayoutInterface
Represents a report for use with the
QgsLayout
engine.Reports consist of multiple sections, represented by
QgsAbstractReportSection
subclasses.Warning
This is not considered stable API, and may change in future QGIS releases. It is exposed to the Python bindings for unit testing purposes only.
New in version 3.0.
QgsReport(project:
QgsProject
) Constructor forQgsReport
, associated with the specifiedproject
.Note that ownership is not transferred to
project
.Methods
- rtype:
QgsReport
Copies the common properties of a report section to a
destination
section.- rtype:
str
- rtype:
QIcon
- param visitor:
- rtype:
QgsProject
- rtype:
QgsMasterLayoutInterface.Type
- rtype:
str
- param layoutElement:
Sets section state from a DOM element.
- param name:
Sets the
parent
report section.- rtype:
str
- param document:
Stores section state within an XML DOM element.
Signals
pyqtSignal(*types, name: str = ..., revision: int = ..., arguments: Sequence = ...) -> PYQT_SIGNAL
- childEvent(self, QChildEvent)¶
- connectNotify(self, QMetaMethod)¶
- copyCommonProperties(self, destination: QgsAbstractReportSection)¶
Copies the common properties of a report section to a
destination
section. This method should be called fromclone()
implementations.
- customEvent(self, QEvent)¶
- description(self) str ¶
- Return type:
str
- disconnectNotify(self, QMetaMethod)¶
- icon(self) QIcon ¶
- Return type:
QIcon
- isSignalConnected(self, QMetaMethod) bool ¶
- layoutAccept(self, visitor: QgsStyleEntityVisitorInterface) bool ¶
- Parameters:
visitor (QgsStyleEntityVisitorInterface) –
- Return type:
bool
- layoutProject(self) QgsProject ¶
- Return type:
- layoutType(self) QgsMasterLayoutInterface.Type ¶
- Return type:
- name(self) str ¶
- Return type:
str
- nameChanged¶
pyqtSignal(*types, name: str = …, revision: int = …, arguments: Sequence = …) -> PYQT_SIGNAL
types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.
- Parameters:
name (str = ...) –
revision (int = ...) –
arguments (Sequence = ...) –
- Return type:
PYQT_SIGNAL
- readLayoutXml(self, layoutElement: QDomElement, document: QDomDocument, context: QgsReadWriteContext) bool ¶
- Parameters:
layoutElement (QDomElement) –
document (QDomDocument) –
context (QgsReadWriteContext) –
- Return type:
bool
- readPropertiesFromElement(self, element: QDomElement, document: QDomDocument, context: QgsReadWriteContext) bool ¶
Sets section state from a DOM element.
See also
See also
readXml()
- receivers(self, PYQT_SIGNAL) int ¶
- sender(self) QObject ¶
- senderSignalIndex(self) int ¶
- setName(self, name: str)¶
- Parameters:
name (str) –
- setParentSection(self, parent: QgsAbstractReportSection)¶
Sets the
parent
report section.
- timerEvent(self, QTimerEvent)¶
- type(self) str ¶
- Return type:
str
- updateSettings(self)¶
- writeLayoutXml(self, document: QDomDocument, context: QgsReadWriteContext) QDomElement ¶
- Parameters:
document (QDomDocument) –
context (QgsReadWriteContext) –
- Return type:
QDomElement
- writePropertiesToElement(self, element: QDomElement, document: QDomDocument, context: QgsReadWriteContext) bool ¶
Stores section state within an XML DOM element.
See also
writeXml()
See also