18#ifndef QGSLAYOUTMULTIFRAMEUNDOCOMMAND_H
19#define QGSLAYOUTMULTIFRAMEUNDOCOMMAND_H
51 QgsLayoutMultiFrameUndoCommand( QgsLayoutMultiFrame *frame,
const QString &text,
int id = 0, QUndoCommand *parent
SIP_TRANSFERTHIS =
nullptr );
53 bool mergeWith(
const QUndoCommand *command )
override;
58 QgsLayout *layout()
const;
64 QString multiFrameUuid()
const;
67 void saveState( QDomDocument &stateDoc )
const override;
70 virtual QgsLayoutMultiFrame *recreateItem(
int itemType, QgsLayout *layout )
SIP_FACTORY;
74 QgsLayout *mLayout =
nullptr;
87class CORE_EXPORT QgsLayoutMultiFrameDeleteUndoCommand :
public QgsLayoutMultiFrameUndoCommand
97 QgsLayoutMultiFrameDeleteUndoCommand( QgsLayoutMultiFrame *frame,
const QString &text,
int id = 0, QUndoCommand *parent
SIP_TRANSFERTHIS =
nullptr );
98 bool mergeWith(
const QUndoCommand *command )
override;
112class CORE_EXPORT QgsLayoutMultiFrameAddItemCommand :
public QgsLayoutMultiFrameUndoCommand
122 QgsLayoutMultiFrameAddItemCommand( QgsLayoutMultiFrame *frame,
const QString &text,
int id = 0, QUndoCommand *parent
SIP_TRANSFERTHIS =
nullptr );
124 bool mergeWith(
const QUndoCommand *command )
override;
125 void undo()
override;
Base class for commands to undo/redo layout and layout object changes.
virtual bool containsChange() const
Returns true if both the before and after states are valid and different.
virtual void saveState(QDomDocument &stateDoc) const =0
Saves the state of the object to the specified stateDoc.
virtual void restoreState(QDomDocument &stateDoc)=0
Restores the state of the object from the specified stateDoc.
Abstract base class for layout items with the ability to distribute the content to several frames (Qg...
Base class for layouts, which can contain items such as maps, labels, scalebars, etc.