Go to: Synopsis. Return value. Related. Flags. MEL examples.
undoInfo [-closeChunk] [-infinity boolean] [-length uint] [-openChunk] [-printQueue] [-redoName string] [-redoQueueEmpty] [-state boolean] [-stateWithoutFlush boolean] [-undoName string] [-undoQueueEmpty]
undoInfo is undoable, queryable, and NOT editable.
This command controls the undo/redo parameters.
string | If querying undoName or redoName |
int | If querying state, infinity, or length |
In query mode, return type is based on queried flag.
flushUndo, redo, undo
closeChunk, infinity, length, openChunk, printQueue, redoName, redoQueueEmpty, state, stateWithoutFlush, undoName, undoQueueEmpty
Long name (short name) |
Argument types |
Properties |
-state(-st)
|
boolean
|
|
|
Turns undo/redo on or off.
|
|
-infinity(-in)
|
boolean
|
|
|
Set the queue length to infinity.
|
|
-length(-l)
|
uint
|
|
|
Specifies the number of items in the undo queue.
The infinity flag overrides this one.
|
|
-undoName(-un)
|
string
|
|
|
Returns what will be undone (if anything)
|
|
-redoName(-rn)
|
string
|
|
|
Returns what will be redone (if anything)
|
|
-undoQueueEmpty(-uqe)
|
|
|
|
Return true if the undo queue is empty. Return false if
there is at least one command in the queue to be undone.
|
|
-redoQueueEmpty(-rqe)
|
|
|
|
Return true if the redo queue is empty. Return false if
there is at least one command in the queue to be redone.
|
|
-printQueue(-pq)
|
|
|
|
Prints to the Script Editor the contents of the undo queue.
|
|
-openChunk(-ock)
|
|
|
|
Opens a chunk so that all undoable operations after this call
will fall into the newly opened chunk, until close chunk is called.
Once close chunk is called, all undoable operations in the chunk
will undo as a single undo operation.
Use with CAUTION!! Improper use of this command can leave the
undo queue in a bad state.
|
|
-closeChunk(-cck)
|
|
|
|
Closes the chunk that was opened earlier by openChunk.
Once close chunk is called, all undoable operations in the chunk
will undo as a single undo operation.
Use with CAUTION!! Improper use of this command can leave the
undo queue in a bad state.
|
|
-stateWithoutFlush(-swf)
|
boolean
|
|
|
Turns undo/redo on or off without flushing the queue.
|
|
Flag can appear in Create mode of command
|
Flag can appear in Edit mode of command
|
Flag can appear in Query mode of command
|
Flag can be used more than once in a command.
|
// Turn undo on, with an infinite queue length
undoInfo -state on -infinity on;
// Turn undo on, with a queue length of 200
undoInfo -state on -infinity off -length 200;
// Turn undo off
undoInfo -state off;
// Query the queue length
undoInfo -q -length;
// Print the contents of the undo queue.
undoInfo -q -pq;