UndoRedoService
Canonical path: NemAll_Python_IFW_Input.UndoRedoService
Implementation of the undo/redo service
Methods:
-
ActivateCollectedElementsForFinishUpdate
–activate collected elements from undo step, important for next
-
CollectElementsForMultipleTransactions
–Collect the elements for adding multiple transactions to one undo step
-
CreateUndoStep
–Overloaded function. See individual overloads.
-
IsInUndoService
–Check if an active undo service is present
-
ResetTransactionError
–Reset the transaction error
-
SetUndoDescription
–Set the undo step description independent from menu event text
-
SetUndoStepEvent
–Set the undo step event
-
__init__
–Overloaded function. See individual overloads.
ActivateCollectedElementsForFinishUpdate
activate collected elements from undo step, important for next finish update
CollectElementsForMultipleTransactions
Collect the elements for adding multiple transactions to one undo step
CreateUndoStep
overloaded
Create an undo step
Parameters:
-
eventID
(int
) –Event ID of the undo step
Create an undo step
IsInUndoService
staticmethod
Check if an active undo service is present
Returns:
-
bool
–Active undo service is present
SetUndoDescription
Set the undo step description independent from menu event text
Parameters:
-
textID
(int
) –Text ID of the undo step
SetUndoStepEvent
Set the undo step event
Parameters:
-
eventID
(int
) –Event ID of the undo step
__init__
overloaded
__init__(
doc: DocumentAdapter,
isPassivateAll: bool = False,
isLockPreviewDraw: bool = False,
collectEleForMultipleTransactions: bool = False,
)
Constructor
Parameters:
-
doc
(DocumentAdapter
) –Current document
-
isPassivateAll
(bool
, default:False
) –if true passivate all, default is false
-
isLockPreviewDraw
(bool
, default:False
) –Lock the preview drawing during the undo step creation
-
collectEleForMultipleTransactions
(bool
, default:False
) –Collect the elements, if the UndoRedoService is included in multiple transactions
__init__(element: UndoRedoService)