Methods related to ScriptUI
Members
-
staticDuScriptUI.defaultColumnAlignmentArray.<String>
-
The default alignment of children of containers with "column" orientation
- Default Value:
- ["fill","top"]
-
staticDuScriptUI.defaultMarginsint
-
The default margins of containers
- Default Value:
- 2
-
staticDuScriptUI.defaultRowAlignmentArray.<String>
-
The default alignment of children of containers with "row" orientation
- Default Value:
- ["left","center"]
-
staticDuScriptUI.defaultSpacingint
-
The default spacing of containers
- Default Value:
- 2
-
staticDuScriptUI.defaultStackAlignmentArray.<String>
-
The default alignment of children of containers with "stack" orientation
- Default Value:
- ["fill","top"]
-
staticDuScriptUI.fundingBar
-
A bar used to show current funding status.
-
staticDuScriptUI.fundingLabelStaticText
-
A label used to show current funding status.
-
staticDuScriptUI.IconDuBinary
-
The list of available icons.
Properties:
Name Type Default Description ADD
DuBinary w12_add AE_BLUE
DuBinary w8_ae_blue AE_ORANGE
DuBinary w8_ae_orange BACK
DuBinary w12_back BOX_CHECKED
DuBinary w12_box_checked BOX_UNCHECKED
DuBinary w12_box_unchecked BUG
DuBinary w16_bug BUG_REPORT
DuBinary w12_bugreport CHECK
DuBinary w12_check CLOSE
DuBinary w12_close DOWNLOAD
DuBinary w16_download EDIT
DuBinary w12_edit EXPERT
DuBinary w16_expert EYE_DROPPER
DuBinary w12_eye_dropper EYE_DROPPER_BIG
DuBinary w16_eye_dropper FEATURE
DuBinary w12_feature FILE
DuBinary w12_file FOLDER
DuBinary w12_folder FOLDER_CLOSED
DuBinary w12_folder_closed GO_TO
DuBinary w12_goto HEART
DuBinary w12_heart HELP
DuBinary w12_help LANGUAGE
DuBinary w16_language LANGUAGE_FILE
DuBinary w16_language_file LIST
DuBinary w16_list MENU
DuBinary w12_menu MORE
DuBinary w12_more NEXT
DuBinary w12_next OPTIONS
DuBinary w12_options PARENT
DuBinary w12_parent PIN
DuBinary w12_pin PINNED
DuBinary w12_pinned PLACEHOLDER
DuBinary w16_placeholder PROGRESS
DuBinary w320_progress RAINBOX_RED
DuBinary w8_rx_red RANDOM
DuBinary w16_random REMOVE
DuBinary w12_remove RESET
DuBinary w12_reset ROOKIE
DuBinary w16_rookie RUN
DuBinary w12_run RX_PURPLE
DuBinary w8_rx_purple SETTINGS
DuBinary w12_settings SETTINGS_FILE
DuBinary w16_settings_file STANDARD
DuBinary w16_standard UPDATE
DuBinary w12_update USER
DuBinary w16_user SEARCH
DuBinary w12_search SORT
DuBinary w12_sort SORT_UP
DuBinary w12_sort_up SORT_DOWN
DuBinary w12_sort_down -
staticDuScriptUI.progressBar
-
Show this progress bar before long operations with
DuProgressBar.show
and DuESF will update it. -
staticDuScriptUI.Stringstring
-
The list of strings used by the UI.
Properties:
Name Type Default Description ABOVE
string Above ABOVE_SHORT
string Ab ADD_ITEM_OR_CAT
string Add new item or category AE_BLUE
string After Effects Blue AE_BLUE_TIP
string The After Effects highlighting blue AE_ORANGE
string After Effects Orange (CS6) AE_ORANGE_TIP
string The After Effects highlighting orange from good ol'CS6 APPLY
string Apply APPLY_ALL
string Apply all APPLY_SETTINGS
string Apply changes to the settings. APPLY_SETTINGS_ALERT
string You may need to restart the script for all changes to take effect. ARM
string Arm ARTHROPOD
string Arthropod AUDIO
string Audio AXIS
string Axis BACK_PREVIOUS
string Back BACK_LOCATION
string Back BACK_LOCATION_SHORT
string Bk BIRD
string Bird BODY
string Body BONE
string Bone BUG_REPORT
string Bug report BUG_REPORT_TIP
string Bug report Feature request Tell us what's wrong or request a new feature. CAM
string Cam CAMERA
string Camera CANCEL
string Cancel CALF
string Calf CATEGORY
string Category CHARACTER
string Character CHANNEL
string Channel CHECK_UPDATE
string Check for updates CIRCLE
string Circle CLAWS
string Claws CLEAR_LIB_TIP
string Clears the current search and category CLOSE
string Close COLOR
string Color COLOR_HIGHLIGHT_TIP
string Set the highlight color. COPY
string Copy CREATE
string Create CUSTOM
string Custom CUSTOM_COLOR_TIP
string Select a custom color. CLOSE_SETTINGS
string Close settings DEFAULT
string Default DEV_MODE
string Dev and Debug mode DEV_MODE_TIP
string Use at your own risk! DIGITIGRADE
string Digitigrade EAR
string Ear EDIT
string Edit EDIT_ITEM_OR_CAT
string Edit selected item or category EDIT_SETTINGS
string Edit settings EFFECTS
string Effects EXPERT
string Expert EXPERT_UI_TIP
string The smallest UI, for expert users. EXPORT_TRANSLATION
string Export translation file EXPORT_TRANSLATION_TIP
string Export a translation file to be edited with DuTranslator. EYE
string Eye EYES
string Eyes EYEBROW
string Eye FEATHER
string Feather FEATHERS
string Feathers FEATURE_REQUEST
string Feature request FEATURE_REQUEST_TIP
string Feature request Request something new. FILE
string File FIN
string Fin FINGERS
string Fingers FISH
string Fish FISHBONE
string Fishbone FISHBONES
string Fishbones FISH_SPINE
string Fish spine FOOT
string Foot FOREARM
string Forearm FRAME
string Frame FRAMES
string Frames FRONT
string Front FRONT_LEG
string Front leg FRONT_SHORT
string Fr FUNDING_BAR_TIP
string Thank you for your donations! FUNDING_BAR_TIP_DETAILS
string This month, the {#} fund is ${#}. That's {#}% of our monthly goal ( ${#} ). GROUPS
string Groups HAIR
string Hair HAND
string Hand HEAD
string Head HEEL
string Heel HELP
string Help HELP_TIP
string Get help. HIPS
string Hips HOMINOID
string Hominoid HOOF
string Hoof INVERT
string Invert INVERTED
string Inverted ISOLATE
string Isolate ITEM
string Item LANGUAGE_TIP
string Set the language of the interface. LAYER
string Layer LAYERS
string Layers LEFT
string Left LEFT_SHORT
string L LEG
string Leg LIMB
string Limb LOCATION
string Location LOCATION_SHORT
string Loc MAGIC
string Magic is happening MAIN
string Main MASKS
string Masks MAXIMUM
string Maximum MIDDLE
string Middle MIDDLE_SHORT
string Md MINIMUM
string Minimum MORE_OPTIONS_TIP
string [Shift]: More options... MOUTH
string Mouth NAME
string Name NECK
string Neck NEXT
string Next NONE
string None NORMAL_MODE
string Normal mode NOSE
string Normal mode NULL_OBJECT
string Null OK
string OK OPACITY
string Opacity OPEN
string Open OPEN_FOLDER
string Open folder ORIGINAL
string Original PATH
string Path PAW
string Paw PENIS
string Penis PINCER
string Pincer PIN_TIP
string Keeps this panel open PLANTIGRADE
string Plantigrade PREVIOUS
string Previous POLYGON
string Polygon POSITION
string Position PROPERTIES
string Properties RANDOM_TIP
string Set a random value. RECTANGLE
string Rectangle REFRESH_LIB
string Refresh library REMOVE
string Remove REMOVE_ITEM_OR_CAT
string Remove selected item or category RESET_SETTINGS
string Reset the settings to their default values. RIGHT
string Right RIGHT_SHORT
string R ROOKIE
string Rookie ROOKIE_UI_TIP
string The easiest-to-use mode, but also the biggest UI. ROTATION
string Rotation ROUNDED_RECTANGLE
string Rounded rectangle RUN_EXECUTE
string Run RX_PURPLE
string RxLab Purple RX_PURPLE_TIP
string The RxLaboratory Purple RX_RED
string Rainbox Red RX_RED_TIP
string The Rainbox Productions Red SAVE_AS
string Save as SCALE
string Scale SCRIPTING
string Scripting SELECT_LAYERS
string Select layers SELECT_GROUPS
string Select groups SET_QUALITY
string Set quality SETTINGS
string Settings SETTINGS_FILE
string Settings file SETTINGS_FILE_TIP
string Set the location of the settings file. SHOULDER
string Shoulder SHOULDERS
string Shoulders SHOULDERS_AND_NECK
string Shoulders & neck SIDE
string Side SIZE
string Size SNAKE
string Snake SPINE
string Spine STANDARD
string Standard STANDARD_UI_TIP
string The standard not-too-big UI. START_TYPING_CMD
string Start typing something... TAIL
string Tail TAIL_SHORT
string Tl TARGET
string Target TEXT
string Text TEXTURE
string Texture THIGH
string Thigh TIMELINE
string Timeline TIP_BONE
string Tip TRANSFORM
string Transform TOES
string Toes TORSO
string Torso TYPE
string Type UI_MODE_TIP
string Select the UI mode. UNDER
string Under UNDER_SHORT
string Un UNGULATE
string Ungulate VERTEBRAE
string Vertebrae VULVA
string Vulva WING
string Wing WORKING
string Working... X_POSITION
string X Position Y_POSITION
string Y Position
Methods
-
staticDuScriptUI.addBugButton(container, showLabel){DuButton}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10272 -
Creates a button opening the bug report url.
Name Type Default Description container
Panel | Window | Group The ScriptUI Object which will contain and display the button. showLabel
bool false optional When true, the button includes a "Bug Report" label. Returns:
Type Description DuButton The bug button created. -
staticDuScriptUI.addDonateButton(container, showLabel){DuButton}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10338 -
Creates a button opening the link for like/follow/donation
Name Type Default Description container
Panel | Window | Group The ScriptUI Object which will contain and display the button. showLabel
bool false optional When true, the button includes a "I ♥ " + DuESF.scriptName
label.Returns:
Type Description DuButton The like button created. -
staticDuScriptUI.addEvent(func, timeOut){int}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 13858 -
Adds a function to be run periodically, which will be connected to several UI events, fired when the user interacts with the UI.
Name Type Default Description func
function The function to connect to the UI timeOut
int 3000 optional A timeOut in milliseconds which prevents the function to be run too often Returns:
Type Description int a unique identifier to be used to remove the function later, with DuScriptUI.removeEvent
. -
staticDuScriptUI.addHelpButton(container, showLabel){DuButton}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10304 -
Creates a button opening the help panel.
Name Type Default Description container
Panel | Window | Group The ScriptUI Object which will contain and display the button. showLabel
bool false optional When true, the button includes a "Help" label. Returns:
Type Description DuButton The help button created. -
staticDuScriptUI.askLanguage(callback, ui)
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10378 -
Displays a prompt to select the language of the script.
Won't do nothing if the script already has a language set in the settings.
Use this method before launching the script.Name Type Description callback
function The function to execute when the user has chosen the language.
This function should be the one which loads the script.ui
Panel | Window optional A container to display the UI. A modal Dialog is created if omitted -
staticDuScriptUI.buildAllTabs()
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 12656 -
Builds all the tabs from all the tab panels
-
staticDuScriptUI.button(container, text, image, helpTip, addOptionsPanel, orientation, alignment, localize, ignoreUIMode, optionsWithoutButton, optionsButtonText, optionsWithoutPanel){DuButton}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 9839 -
Creates a button with an optionnal icon. Must have at least an icon or a text, or both.
Name Type Default Description container
Panel | Window | Group The ScriptUI Object which will contain and display the button. text
string optional The label of the button. Default: empty string image
string | DuBInary optional The path to the icon (or a PNG as a string representation). Default: empty string helpTip
string optional The helptip. Default: empty string addOptionsPanel
Boolean false optional Adds a panel for options and a button to access it. orientation
Boolean 'row' optional The orientation of the button (icon, text, options button). Default will be changed to 'column' if there's no text. alignment
Boolean 'left' optional The alignment of the button content ('center', 'right' or 'left' for 'row', 'top' 'bottom', 'center' for column). localize
Boolean true optional Set to false if the text must not be translated. ignoreUIMode
Boolean false optional Will show texte even if the ui mode is set to > 1 in the script settings optionsWithoutButton
Boolean false optional Don't add an "ok" button to the options popup optionsButtonText
string optional Change the displayed text of the bottom button of the options optionsWithoutPanel
Boolean false optional Don't create the options popup panel (use DuButton.onOptions
to add your own callback when the options are requested)Returns:
Type Description DuButton The image button created. -
staticDuScriptUI.checkBox(container, text, image, helpTip, textChecked, imageChecked, orientation){DuCheckBox}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10865 -
Creates a checkbox with an optionnal icon. Must have at least an icon or a text, or both.
Name Type Default Description container
Panel | Window | Group The ScriptUI Object which will contain and display the button. text
string The label of the button. Default: empty string image
string | DuBinary optional The path to the icon. Default: empty string helpTip
string '' optional The helptip. Default: empty string textChecked
string text optional The label of the button displayed when it is checked. imageChecked
string | DuBinary optional The image to show when it is checked orientation
string 'row' optional The orientation Returns:
Type Description DuCheckBox The checkbox created. -
staticDuScriptUI.checkUpdate(callback, ui, showAlert)
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10452 -
Checks if the script can be updated
Name Type Description callback
function optional The function to execute when the user has clicked on the "dismiss" button. ui
Panel | Window optional A container to display the UI. A modal Dialog is created if omitted showAlert
Boolean optional Whether to show an alert if the check failed or if the version is up-to-date. -
staticDuScriptUI.colorSelector(container, helpTip){DuColorSelector}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 12730 -
Creates a new color selector and adds it to the container
Name Type Description container
Window | Panel | Group helpTip
string optional The help tip to show on the selector Returns:
Type Description DuColorSelector -
staticDuScriptUI.compSelector(container, helpTip){DuAECompSelector}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 16124 -
Creates a drop down selector for compositions
Name Type Default Description container
Window | Panel | Group The ScriptUI Object which will contain and display the selector. helpTip
string "" optional The help tip. Returns:
Type Description DuAECompSelector - The selector -
staticDuScriptUI.editText(container, text, prefix, suffix, placeHolder, helpTip, translatable){DuEditText}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 11699 -
Creates a nice edittext where the edit text is shown only on click.
Name Type Default Description container
Window | Panel | Group The ScriptUI Object which will contain and display the nice edit text. text
string The initial text in the edit. prefix
string "" optional A text prefix to display. suffix
string "" optional A text suffix to display. placeHolder
string "" optional A place holder default text. helpTip
string "" optional The helpTip of this control translatable
bool true optional Whether to translate the texts of this control Returns:
Type Description DuEditText The custom Group containing the edit text. -
staticDuScriptUI.fileSelector(container, text, textField, helpTip, image, mode, orientation){DuFileSelector}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 12054 -
Creates a file selector with a field for the path and a browse button.
Name Type Default Description container
Window | Panel | Group The ScriptUI Object which will contain and display the panel. text
string "Browse..." optional The text to display on the button. textField
boolean true optional Whether to show the text field for the path. helpTip
string '' optional The helptip for this control. image
string | DuBinary optional The image to use as an icon; a "file" icon by default. mode
string 'open' optional The open mode, either 'open' or 'save'. orientation
string 'row' optional The orientation of the control (button+edittext). Returns:
Type Description DuFileSelector The control. -
staticDuScriptUI.folderSelector(container, text, textField, helpTip, orientation){DuFolderSelector}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 11956 -
Creates a folder selector with a field for the path and a browse button
Name Type Default Description container
Window | Panel | Group The ScriptUI Object which will contain and display the panel. text
string "Browse..." optional The text to display on the button. textField
boolean true optional Whether to show the text field for the path. helpTip
string '' optional The helptip for this control. orientation
string 'row' optional The orientation of the control (button+edittext). Returns:
Type Description DuFolderSelector The control. -
staticDuScriptUI.form(container){DuForm}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 12384 -
Creates a layout to add forms to a UI, using ScriptUI groups.
You can easily add controls/fields to this form using DuScriptUI.addFieldName Type Description container
Window | Panel | Group The ScriptUI Object which will contain and display the form. Returns:
Type Description DuForm The custom Group containing the form. -
staticDuScriptUI.getClosestScreen(location){Object}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 11251 -
Gets the corners of the screen the closest to (or containing) the location
Name Type Description location
Array.<int> The coordinates Returns:
Type Description Object The screen object with a top, left, right and bottom property. -
staticDuScriptUI.group(container, orientation){Group}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10729 -
Adds a group in a container, using DuScriptUI default alignments, and DuScriptUI.defaultSpacing. Margins are set to 0.
Name Type Description container
Panel | Window | Group Where to create the group orientation
string optional The orientation to use. One of "column", "row" or "stack". By default, "column" if added in a row, "row" if added in a column. Returns:
Type Description Group The group created -
staticDuScriptUI.layerPicker(container){DuAELayerPicker}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 16374 -
Creates a two-column group to allow the user to pick layers
Name Type Description container
Window | Panel | Group The ScriptUI Object which will contain and display the selector. Returns:
Type Description DuAELayerPicker The picker. -
staticDuScriptUI.layerPickerDialog(title){DuAELayerPickerDialog}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 16478 -
Creates a dialog with a DuAELayerPicker
UseDuScriptUI.showUI
to show it after creation.Name Type Description title
string The title of the dialog. Returns:
Type Description DuAELayerPickerDialog The dialog window. -
staticDuScriptUI.layerSelector(container, helpTip){DuAELayerSelector}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 15826 -
Creates a drop down selector for layers
Name Type Default Description container
Window | Panel | Group The ScriptUI Object which will contain and display the selector. helpTip
string "" optional The help tip. Returns:
Type Description DuAELayerSelector - The selector -
staticDuScriptUI.layout(item, force)
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10674 -
Resets the layout of the whole ui containing a scriptUI item.
Name Type Description item
ScriptUI The ScriptUI element which needs to be resized force
Boolean optional Needs to be true if you need to layout before DuESF.state
isDuESF.State.RUNTIME
.
That should be the case only for the main UI; Note that you should not need it anyway,DuScriptUI.showUI
does that for you. -
staticDuScriptUI.library(container, library, options)
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 13365 -
Adds a new
DuLibrary
to the container.Name Type Description container
Panel | Window | Group The ScriptUI Object which will contain and display the library. library
DuLibraryItem A library object. Key/value pairs, values being DuLibraryItem
objects, keys being their display name.options
object optional Options and other values. -
staticDuScriptUI.mainPanel(container, scriptName, contentAlignment, borderless){DuPanel}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 8732 -
Creates the main panel for a script
Name Type Default Description container
Panel | null The container ('this' in the root of the calling script), either a Panel (when launched from the 'Window' menu) or null (when launched from 'file/scripts/run...') scriptName
string DuESF.scriptName optional A name for this UI contentAlignment
Array.<string> DuScriptUI.defaultColumnAlignment optional The alignment of the content in the panel borderless
string false optional When true, creates a borderless window if container is not a panel Returns:
Type Description DuPanel The panel created, either a ScriptUI Panel or a ScriptUI Window. Example
var ui = DuScriptUI.mainPanel(this,"Test Script"); var refreshButton = ui.content.add('button',undefined,"Refresh"); refreshButton.onClick = function() { ui.refreshUI( new File($.fileName) ); }; //reloads the current script DuScriptUI.showUI(ui);
-
staticDuScriptUI.moveInsideScreen(location, size){Array.<int>}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 11229 -
Moves the coordinates so that the size completely fits inside an existing screen
Name Type Description location
Array.<int> The coordinates [top, left] size
Dimension The rectangle size, an object which has two properties: width and height Returns:
Type Description Array.<int> the new location -
staticDuScriptUI.multiButton(container, text, image, helpTip, ignoreUIMode){DuSelector}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 12822 -
Creates a multi button popup
Name Type Default Description container
Window | Panel | Group The ScriptUI Object which will contain and display the multi button. text
string optional The text. image
string | DuBInary optional The path to the icon (or a PNG as a string representation). Default: empty string helpTip
string optional The help tip to show on the multi button ignoreUIMode
Boolean false optional Will show texte even if the ui mode is set to > 1 in the script settings Returns:
Type Description DuSelector - The multiButton -
staticDuScriptUI.popUp(title, alignment, modal){DuPopup}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 8879 -
Creates a borderless popup
Name Type Default Description title
string The title of the popup alignment
Array.<string> [ "fill", "top" ] optional The alignement of this window modal
boolean false optional Set the popup to a modal dialog Returns:
Type Description DuPopup The popup, a ScriptUI Window which is borderless, with a 'tieTo(control)' method. Example
var popup = DuScriptUI.popUp( ); var popupButton = DuScriptUI.button( myUI, "My Buttton for the popup" ); popup.tieTo( popupButton ); // will show the popup when the button is clicked, just above it.
-
staticDuScriptUI.removeEvent(id)
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 13872 -
Removes a function previously added with
DuScriptUI.addEvent
.Name Type Description id
int The id of the function -
staticDuScriptUI.scriptPanel(container, addSettingsButton, addHelpButton, scriptFile){DuScriptPanel}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 9219 -
Creates the main panel of a script
Name Type Default Description container
Panel | null The container ('this' in the root of the calling script), either a Panel (when launched from the 'Window' menu) or null (when launched from 'file/scripts/run...') addSettingsButton
bool true optional Whether to create a button to open the settings or not addHelpButton
bool false optional Whether to create a button to open the help panel or not scriptFile
File optional The main script file, needed for the refresh button in debug mode Returns:
Type Description DuScriptPanel The panel created, either a ScriptUI Panel or a ScriptUI Window. Example
var ui = DuScriptUI.mainPanel(this,"Test Script"); var refreshButton = ui.content.add('button',undefined,"Refresh"); refreshButton.onClick = function() { ui.refreshUI( new File($.fileName) ); }; //reloads the current script DuScriptUI.showUI(ui);
-
staticDuScriptUI.selectionModeSelector(minimalMode){DuSelector}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 16548 -
Creates a selector to choose a selection mode
Name Type Default Description minimalMode
DuAE.SelectionMode DuAE.SelectionMode.SELECTED_PROPERTIES optional The lowest mode to use Returns:
Type Description DuSelector The selector -
staticDuScriptUI.selector(container, helpTip){DuSelector}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 11364 -
Creates a drop down selector, using image buttons
Name Type Description container
Window | Panel | Group The ScriptUI Object which will contain and display the selector. helpTip
string optional The help tip to show on the selector Returns:
Type Description DuSelector - The selector -
staticDuScriptUI.separator(container, name, checkable, drawLine, translatable){DuSeparator}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10775 -
Adds separator with an optionnal name in the group
Name Type Default Description container
Panel | Window | Group Where to create the separator name
string optional The name displayed checkable
boolean false optional When true, adds a checkbox to the separator drawLine
boolean true optional Draws a line when there is no name. When false, the separator is an empty space translatable
boolean true optional If false, the name won't be translated Returns:
Type Description DuSeparator The separator -
staticDuScriptUI.setBackgroundColor(uiItem, color, adjusted)
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10707 -
Changes the color of the background of a ScriptUI Object
Name Type Default Description uiItem
ScriptUI The ScriptUI Object color
Array The new color [R,V,B,A] Array adjusted
Boolean true optional lightens the color if the brightness setting of Ae is not set on the darkest one -
staticDuScriptUI.setTextColor(text, color, adjusted)
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10688 -
Changes the color of the text of a ScriptUI Object
Name Type Default Description text
ScriptUI The ScriptUI Object color
DuColor The new color adjusted
Boolean false optional lightens the color if the brightness setting of Ae is not set on the darkest one -
staticDuScriptUI.setupScript(callback, ui, scriptName, reInit, reInitMethod)
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 15774 -
Runs the installation wizard for the script (asks for files and network access, asks the language...).
Name Type Default Description callback
function The function to execute when ready.
This function should be the one which loads the script.ui
Panel | Window optional A container to display the UI. A modal Dialog is created if omitted scriptName
string DuESF.scriptName optional The name of the script, used in the UI. reInit
boolean false optional Set to true to display to prompt to reinit/reinstall the script below the button to ask for file access. reInitMethod
function optional A function to run in order to reinit/reinstall the script as soon as we get file access, before running the callback -
staticDuScriptUI.showUI(ui, enterRunTime)
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 9129 -
Resizes and shows the main panel of a script
Name Type Default Description ui
Panel | Window The UI created by Duik.ui.createUI enterRunTime
boolean false optional Set to true to automatically set DuESF to runtime state
Set this to false if the ui shown is not the actual main panel of the script and it is shown before the main panel has been loaded. -
staticDuScriptUI.slider(container, defaultValue, min, max, orientation, invertedAppearance, prefix, suffix, textAlignment, valueButtons){DuSlider}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 12214 -
Creates a slider.
Name Type Default Description container
Window | Panel | Group The ScriptUI Object which will contain and display the nice edit text. defaultValue
int 0 optional The initial value. min
int 0 optional The minimal value. max
int 100 optional The maximal value. orientation
string 'column' optional Either 'row' or 'column' invertedAppearance
boolean optional Revert the slider with max value on the left prefix
string optional A text prefix to display. suffix
string optional A text suffix to display. textAlignment
string 'center' optional The alignment of the text.
One of 'left', 'center', 'right' for column orientation,
And 'top', 'center', 'bottom' for row orientation.valueButtons
Array.<int> [] optional A list of predefined values to add as buttons. - TODO
-
- implement helpTip
Returns:
Type Description DuSlider The custom Group containing the slider. -
staticDuScriptUI.smallbutton(container, text, helpTip, value){DuButton}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10155 -
Creates a small button.
Name Type Description container
Panel | Window | Group The ScriptUI Object which will contain and display the button. text
string The label of the button. Default: empty string helpTip
string optional The helptip. Default: empty string value
any optional A user value stored in the button, which is passed to the onClick method Returns:
Type Description DuButton The image button created. -
staticDuScriptUI.staticText(container, text, color, translatable, multiline){StaticText}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 11901 -
Creates a statictext (with an optionnal color).
Name Type Default Description container
Window | Panel | Group The ScriptUI Object which will contain and display the nice edit text. text
string The initial text in the edit. color
DuColor optional The color of the text. By default, uses a slightly darker text than the Host App text color translatable
bool true optional Set this to false to never translate this text. multiline
bool optional Set this to true to add a multiline text. Auto detected by default if the text contains the newline character. Returns:
Type Description StaticText The ScriptUI StaticText created. -
staticDuScriptUI.stringPrompt(title, defaultString){DuPopup}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 9699 -
Creates a popup to ask for a simple string
Name Type Description title
string The title of the popup defaultString
string The placeholder for the edit text Returns:
Type Description DuPopup The popup, with an onAccept( str )
callback. -
staticDuScriptUI.tabPanel(container, tabOrientation){DuTabPanel}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 12524 -
Creates a panel with tabs
Name Type Description container
Window | Panel | Group The ScriptUI Object which will contain and display the panel. tabOrientation
string The orientation to use for tab buttons. Returns:
Type Description DuTabPanel The panel. -
staticDuScriptUI.titleBar(container, title, closeButton, pinButton){DuTitleBar}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 8646 -
Creates a titlebar
Name Type Default Description container
Panel | Window | Group The ScriptUI Object which will contain and display the titlebar. title
string "" optional The title. closeButton
Boolean true optional Wether to add a close button pinButton
Boolean true optional Wether to add a pin button Returns:
Type Description DuTitleBar The titlebar -
staticDuScriptUI.toolBar(container, numCols){Group}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 13147 -
Creates a toolbar with a lighter background
Name Type Description container
Panel | Window | Group The ScriptUI Object which will contain and display the toolbar. numCols
int optional The number of columns to use when adding the buttons. Returns:
Type Description Group The toolbar, a ScriptUI Group -
staticDuScriptUI.versionButton(container, image){DuButton}
D:/RxLab/src/RxOT/DuAEF/Duik/Duik_API/DuAEF_Duik_api.jsxinc, line 10241 -
Creates a button displaying the version of the script and redirecting to the about url.
Name Type Default Description container
Panel | Window | Group The ScriptUI Object which will contain and display the button. image
string | DuBinary DuESF.scriptIcon optional The path to the icon or a png binstring. Default: empty string Returns:
Type Description DuButton The version button created.