KDStateMachineEditor API Documentation 2.1
Loading...
Searching...
No Matches
Public Member Functions | List of all members
KDSME::LayoutSnapshotCommand Class Reference

Creates a snapshot of the current layout of the state chart. More...

#include <layoutsnapshotcommand_p.h>

Inheritance diagram for KDSME::LayoutSnapshotCommand:
Inheritance graph
[legend]
Collaboration diagram for KDSME::LayoutSnapshotCommand:
Collaboration graph
[legend]

Public Member Functions

 LayoutSnapshotCommand (StateMachineScene *scene, const QString &text, QUndoCommand *parent=nullptr)
 
 LayoutSnapshotCommand (StateMachineScene *scene, QUndoCommand *parent=nullptr)
 
int id () const override
 
void redo () override
 
void undo () override
 
- Public Member Functions inherited from KDSME::Command
 Command (const QString &text=QString(), QUndoCommand *parent=nullptr)
 
 Command (StateModel *model, QUndoCommand *parent=nullptr)
 
StateModelmodel () const
 

Additional Inherited Members

- Public Types inherited from KDSME::Command
enum  Id {
  CreateElement = 0 , DeleteElement , ReparentElement , LayoutSnapshot ,
  ModifyProperty , ModifyInitialState , ModifyDefaultState , ModifyElement ,
  ModifyTransition , ChangeStateMachine
}
 

Detailed Description

Creates a snapshot of the current layout of the state chart.

This is useful when a user requested an automatic layout manually. This command should be used before the automatic layout happens, so the user can restore the initial layout when undoing the command.

Definition at line 34 of file layoutsnapshotcommand_p.h.

Constructor & Destructor Documentation

◆ LayoutSnapshotCommand() [1/2]

LayoutSnapshotCommand::LayoutSnapshotCommand ( StateMachineScene scene,
QUndoCommand *  parent = nullptr 
)
explicit

Definition at line 22 of file layoutsnapshotcommand.cpp.

◆ LayoutSnapshotCommand() [2/2]

LayoutSnapshotCommand::LayoutSnapshotCommand ( StateMachineScene scene,
const QString &  text,
QUndoCommand *  parent = nullptr 
)

Definition at line 28 of file layoutsnapshotcommand.cpp.

Member Function Documentation

◆ id()

int KDSME::LayoutSnapshotCommand::id ( ) const
inlineoverride

Definition at line 42 of file layoutsnapshotcommand_p.h.

◆ redo()

void LayoutSnapshotCommand::redo ( )
override

Definition at line 34 of file layoutsnapshotcommand.cpp.

◆ undo()

void LayoutSnapshotCommand::undo ( )
override

Definition at line 39 of file layoutsnapshotcommand.cpp.


The documentation for this class was generated from the following files:

© Klarälvdalens Datakonsult AB (KDAB)
"The Qt, C++ and OpenGL Experts"
https://www.kdab.com/
KDStateMachineEditor
Create Qt State Machine metacode using a graphical user interface
https://github.com/KDAB/KDStateMachineEditor
Generated on Tue Jul 15 2025 15:21:47 for KDStateMachineEditor API Documentation by doxygen 1.9.8