The DOpus object is one of the two global script objects provided by Opus, and is available to all scripts. It provides various helper methods, and collections that let you access things like Listers and toolbars.
Property Name |
Return Type |
Description |
---|---|---|
aliases |
object:Aliases |
The Aliases object gives the script
access to the defined folder
aliases. |
language |
string |
Returns a string representing the current user interface language. |
listers |
collection:Lister |
Returns a collection of Lister objects representing
all currently open Listers. |
toolbars |
collection:Toolbar |
Returns a collection of Toolbar objects representing all defined toolbars (whether they are currently open or not). |
vars |
object:Vars |
This Vars object represents all defined variables with global scope. |
version |
object:Version |
The Version object provides information about the current Opus program version. |
Method Name |
Arguments |
Return Type |
Description |
---|---|---|---|
ClearOutput |
none |
none |
Clears the script output log. |
Create |
none |
object:DOpusFactory |
Creates and returns a new DOpusFactory object, which can be used to create various lightweight helper objects like Blob, Map and Vector. |
Delay |
<int:time> |
none |
Delays for the specified number of milliseconds before returning. |
Dlg |
none |
object:Dialog |
Creates a new Dialog object, that lets you display dialogs and popup menus. |
FSUtil |
none |
object:FSUtil |
Creates a new FSUtil object, that provides helper methods for accessing the file system. |
GetClip |
none or <string:type> |
string |
Retrieves the current contents of the system clipboard, if it contains
either text or files. |
GetClipFormat |
none |
string |
Returns a string indicating the native format of the clipboard contents - "text", "files" or an empty string in any other case. |
Output |
<string:text> |
none |
Prints the specified text string to the script output log (found either
in the Utility Panel
or in the CLI in script
mode). |
ReloadScript |
<string:file> |
none |
Causes Opus to reload and reinitialize the specified script. You must provide the full pathname of the script on disk (if a script add-in wants to reload itself you can pass the value of the Script.file property). |
SetClip |
<string:text> |
none |
Places the specified text, or Item collection (or Vector of Item objects) on the system clipboard. If called with no arguments the clipboard will be cleared. |