Subgroup: Layout
Class: QgsLayoutSerializableObject¶
-
class
qgis.core.
QgsLayoutSerializableObject
¶ Bases:
qgis._core.QgsLayoutUndoObjectInterface
An interface for layout objects which can be stored and read from DOM elements.
New in version 3.0: Methods
createCommand
layout
Returns the layout the object belongs to. readXml
Sets the objects’s state from a DOM element. stringType
Return the object type as a string. writeXml
Stores the objects’s state in a DOM element. Signals
Attributes
-
createCommand
(self, text: str, id: int, parent: QUndoCommand = None) → QgsAbstractLayoutUndoCommand¶
-
layout
(self) → QgsLayout¶ Returns the layout the object belongs to.
-
readXml
(self, element: QDomElement, document: QDomDocument, context: QgsReadWriteContext) → bool¶ Sets the objects’s state from a DOM element.
element
is the DOM node corresponding to the object.See also
-
stringType
(self) → str¶ Return the object type as a string.
This string must be a unique, single word, character only representation of the item type, eg “LayoutScaleBar”
-