All DzScripts are executed in the context of a DzScriptContext instance - therefore, all the properties and methods on DzScriptContext are accessible to a script as global functions and variables. It will usually not be necessary for a script to create or use this class directly.
void : acceptUndo( String caption )
Accepts and finishes a hold on the undo stack started by calling beginUndo().
Parameter(s):
See Also:
Boolean : backgroundProgressIsActive()
Return Value:
true
if one or more background progress operations are currently being tracked, otherwise false
.See Also:
Boolean : backgroundProgressIsCancelled()
Return Value:
true
if the user has cancelled the current operation by pressing the 'Cancel' button on the background progress, otherwise false
.See Also:
void : beginNodeSelectionHold()
Captures a view of scene selection.
See Also:
Since:
void : beginUndo()
Starts a hold on the undo stack.
See Also:
void : cancelBackgroundProgress()
Cancels the current background progress tracking operation and closes the background progress if no other progress tracking operations are active. If the current operation can not be cancelled, this has no effect.
Attention:
See Also:
Since:
void : cancelProgress()
Cancels the current script progress tracking operation and closes the progress dialog if no other progress tracking operations are active. If the current operation can not be cancelled, this has no effect.
Attention:
See Also:
Since:
void : cancelUndo()
Accepts the hold on the undo stack but immediately calls undo to restore the state of the stack to what it was before the matching beginUndo() call.
See Also:
void : clearBusyCursor()
Clears the application-standard busy cursor and returns the mouse cursor to the previous cursor. Match every call to setBusyCursor() with a call to this function.
See Also:
void : clearNodeSelectionHolds()
Clears all selection holds without restoring the selection.
See Also:
Since:
void : clearOverrideCursor()
Clears the override cursor stack.
See Also:
Since:
void : clearUndoStack()
Clears the undo stack.
See Also:
void : dropNodeSelectionHold()
Removes a scene node selection hold on scene selection without restoring the selection.
See Also:
Since:
void : dropUndo()
Accepts the actions performed since calling beginUndo() and removes the current hold on the undo stack without adding the items to the undo stack - the memory associated with the items is freed.
See Also:
void : finishBackgroundProgress()
Ends the current background progress tracking operation and closes the background progress if no other background progress tracking operations are active.
See Also:
Object : finishBackgroundProgressWithDetail()
Ends the current background progress tracking operation and closes the background progress if no other background progress tracking operations are active.
Return Value:
See Also:
Since:
void : finishProgress()
Ends the current script progress tracking operation and closes the progress dialog if no other progress tracking operations are active.
See Also:
Object : finishProgressWithDetail()
Ends the current script progress tracking operation and closes the progress dialog if no other progress tracking operations are active.
Return Value:
See Also:
Since:
Array : getArguments()
Return Value:
See Also:
String : getErrorMessage( Number errCode )
This function converts an error code into a string message.
Parameter(s):
Return Value:
See Also:
QObject : getObjectParent( QObject obj )
Parameter(s):
Return Value:
obj
.See Also:
Return Value:
See Also:
Return Value:
See Also:
String : getScriptType()
Return Value:
See Also:
String : getScriptVersionString()
Return Value:
See Also:
Boolean : pointersAreEqual( QObject ptr1, QObject ptr2 )
This function allows a script to test if two QObject-derived variables point to the same instance.
Return Value:
true
if the pointers point to the same object, otherwise false
.See Also:
void : processEvents()
Pauses execution of the script and allows the GUI thread time to process events.
See Also:
Return Value:
true
if one or more script progress operations are currently being tracked, otherwise false
.See Also:
Boolean : progressIsCancelled()
Return Value:
true
if the user has cancelled the current operation by pressing the 'Cancel' button on the script progress dialog, otherwise false
.See Also:
void : restoreNodeSelectionHold()
Restores the scene selection to the view at last call to beginNodeSelectionHold().
See Also:
Since:
void : setBackgroundProgressInfo( String info )
Sets the string to display in the status bar.
Parameter(s):
See Also:
Since:
void : setBusyCursor()
Sets the application-standard busy cursor - increments the count of busy cursors set in the context of the current script execution. Match every call to this function with a call to clearBusyCursor() to restore the previous cursor.
Attention:
See Also:
void : setProgressInfo( String info )
Sets the string to display in the progress dialog.
Parameter(s):
See Also:
Since:
void : sleep( Number milliseconds )
Pauses the script for the specified number of milliseconds
without blocking the application event loop.
Parameter(s):
See Also:
Since:
void : startBackgroundProgress( String info, Number totalSteps=0, Boolean isCancellable=false )
Displays a background progress bar to the user if one is not already being displayed and starts a progress tracking operation.
Parameter(s):
true
, the user is given the option to cancel the operation.See Also:
void : startProgress( String info, Number totalSteps=0, Boolean isCancellable=false, Boolean showTimeElapsed=false )
Displays a script progress dialog to the user if one is not already being displayed and starts a progress tracking operation.
Parameter(s):
true
, the user is given the option to cancel the operation.true
, the amount of time since the progress operation was started will be displayed in the dialog.See Also:
void : stepBackgroundProgress( Number numSteps=1 )
Steps the current background progress forward the specified number of steps.
Parameter(s):
See Also:
void : stepProgress( Number numSteps=1 )
Steps the current script progress dialog forward the specified number of steps.
Parameter(s):
See Also:
void : updateBackgroundProgress( Number position )
Sets the current background progress to the specified number of steps.
Parameter(s):
See Also:
void : updateProgress( Number position )
Sets the current script progress dialog to the specified number of steps.
Parameter(s):
See Also:
Boolean : shiftPressed()
Deprecated
Exists only to keep old code working. Do not use in new code. Use DzApp::modifierKeyState() instead.
var bShiftPressed = App.modifierKeyState() & 0x02000000;
Boolean : ctrlPressed()
Deprecated
Exists only to keep old code working. Do not use in new code. Use DzApp::modifierKeyState() instead.
var bControlPressed = App.modifierKeyState() & 0x04000000;
QDesktopWidget (deprecated) : getDesktop()
Deprecated
Exists only to keep old code working. Do not use in new code. Use DzDesktopWidget instead.
var wDesktop = new DzDesktopWidget();