Professional Documents
Culture Documents
ExtendScript Toolkit ReadMe
ExtendScript Toolkit ReadMe
8)
Adobe Systems Incorporated 1 of 17
ExtendScript Toolkit CS6 ReadMe
1. Overview
This document contains a list of new features, changes, and known issues in this ExtendScript Toolkit
CS6 (ESTK) release. It also describes a few hidden gems, like additional Preferences settings.
2. Updates in CS6
The ExtendScript Toolkit comes with a number of improvements related to its usability:
- Added Reveal in Explorer menu option for documents open in ESTK.
- Added app.clc() to clear the console while executing a script with ExtendScript Toolkit CS6 as
target.
- Theme and UI changes
- Bug fixes.
2.1. Document backup preference
The ESTK provides the ability to automatically back up documents whenever you modify them in any
way. The Documents section of the Preferences dialog now provides the option Backup documents
automatically. By default, the option is off.
When you select this option, you must also set a value for After __ seconds. This is the number of
seconds to wait after making a change before creating the backup. The delay period begins when you
modify a document; if you open a document and do not modify it, no backup is created. If you make
another modification after the backup is created, the backup file is updated.
When you start a debug session, all open documents are backed up, regardless of their modification state.
2.1.1. Backup files
Backup files are created in the backup/ folder, which is a subfolder of Pr ef er ences/ :
- In Windows: User Folder\ Appl i cat i on Dat a\ Adobe\ Ext endScr i pt Tool ki t \ 3. 6\ backup
- In Mac OS: User Folder/ Li br ar y/ Pr ef er ences/ Ext endScr i pt Tool ki t / 3. 6/ backup
The backup file names concatenate the marker BK, a unique identifier and the actual document name,
separated by #. For example: BK#12345#chr omel ess Fl ashPl ayer . j sx
If backup files are available, they are listed in the Files > Recent Files menu with their complete name.
When you save a modified document, the backup file for that document is removed. When you quit the
ESTK normally, all backup files are removed.
If the ESTK exits abnormally, the backup files cannot be removed automatically, and remain in the
backup/ folder. When the ESTK is started again, they are listed in the Files > Recent Files menu, and
you can open them to recover the content and save it properly.
Jan 11, 2012 (ESTK version 3.8)
Adobe Systems Incorporated 2 of 17
2.2. Hidden preferences
The ESTK contains a few hidden settings. These settings can be edited manually by editing the
Preferences template file def s. xml . The file is located here:
- In Windows: {Pr ogr amFi l es}\ Adobe\ Adobe Ut i l i t i es CS6\ Ext endScr i pt Tool ki t
CS6\ Requi r ed\ def s. xml
- In Mac OS: In / Appl i cat i ons/ Ut i l i t i es/ Adobe Ut i l i t i es CS6/ Ext endScr i pt Tool ki t
CS6. app, control-click the application icon and select "Show Package Contents" to open the
package. The file is located here:
Cont ent s/ Shar edSuppor t / Requi r ed/ def s. xml
After editing the file, start the ESTK while holding the Shift key down. This reverts to the default
preferences by loading this file. Note that this also removes any keyboard shortcuts, favorites, and so on,
that you have set.
Note: As in previous releases, you can press and hold the Shift key during startup to avoid loading
preferences, and during shutdown to avoid saving preferences.
2.2.1. Enable a confirmation dialog before debugging
To enable a confirmation dialog asking to "Save this file?" before debugging, set this tag in the def s. xml
file to true:
<debug><saveBef or eDebug>false</ saveBef or eDebug></ debug>
2.2.2. Results in status bar
By default, the ESTK displays the result of the execution of a script in both the status bar and the
Consoler. To display the result only in the status bar, set this tag in the def s. xml file to false:
<pr i nt Resul t >false</ pr i nt Resul t >
3. Known Issues: ESTK
This section explains a few limitations in this version of the ESTK which may be addressed in a future
release.
3.1. Cross-Suite Script Debugging Not Supported
Although it is possible to target a non-CS6 application and run it from the ESTK CS6, such a cross-suite
scripting workflow is not supported. The script may or may not execute as expected within the target
application.
3.2. UTF-8 signature saved in files
By default, the ESTK writes a UTF-8 signature at the beginning of all saved documents. This can cause
issues for editors other than the ESTK (such as Word Pad) if that signature cannot be properly interpreted
when the file is read into one of those editors. To change this default behavior, change the setting in the
Jan 11, 2012 (ESTK version 3.8)
Adobe Systems Incorporated 3 of 17
UTF-8 Signature section of the Documents page of the Preferences dialog to the Never write signature
option.
3.3. Favorites
Aliases are displayed as files in the Scripts pane if the J SX file filter is not used. Aliases to files must also
have the same extension in order to display in the Scripts pane.
3.4. Window placement
The ESTK attempts to adjust itself to the current layout of the desktop, including multiple screens. It
cannot detect that a screen has been added or removed without the user having notified the operating
system first by using the Desktop Properties (Windows) or System Preferences (Mac OS). Also, it
attempts to adjust its window size to a new desktop size when it detects that the desktop has changed
between program runs. There are circumstances, however, where manual adjustment of the ESTK's
windows is necessary.
3.5. Windows font support
The Preferences panels cannot display East Asian characters if East Asian language support is not
installed in Windows. Also, it cannot display files containing East Asian characters correctly if that
package is not installed.
3.6. Comments in preprocessor directives
The ESTK does not allow comments after a preprocessor directive such as #target. The comment
causes an "... undefined!" error message.
3.7. Unrepaired link to target application
When the ESTK is launched and a target application is selected from the drop-down list, if the application
is not already running, the ESTK asks whether the target application should be launched. After answering
yes, even if the target application is successfully launched, the link next to the target application name in
the ESTK remains broken. Click the green "Run" button to fix the link.
3.8. Viewing scripting document in non-English OS
If you run the ESTK on one of the supported non-English OSs (French, German, Italian, J apanese, and
Spanish) and the ESTK Language preference is set to Default, the Adobe Intro to Scripting document
on the Help menu is shown in English. To view the document in the appropriate language, set the
Language from the Edit > Preferences menu to the OS language.
3.9. Application missing from target list
In rare circumstances due to some unlikely product installation scenarios, the name of an installed target
application may not show up in the ESTK dropdown list. If the name of the desired target application is
Jan 11, 2012 (ESTK version 3.8)
Adobe Systems Incorporated 4 of 17
not shown in the list, the script to be executed must contain a #t ar get directive that specifies the target
application.
3.10. Extended input
The ESTK does not fully support Extended Input to enter non-Roman characters (such as J apanese).
Reconversion is not supported.
3.11. Compiled scripts
If a script is compiled to a . j sxbi n file, the #t ar get directive is ignored. Double-clicking a . j sxbi n file
does not execute the script in the application that the #t ar get directive defines.
4. Known Issues: ScriptUI Programming
This section explains known problems encountered in ScriptUI programming, which may be addressed in
a future release.
4.1. Nested modal dialogs
The following sequence of operations using dialog (modal) windows is illegal, and will result in an
application crash (assuming the script created two separate dialog windows - wi n1 and wi n2) :
var r esul t 1 = wi n1. show( ) ;
wi n1. hi de( ) ;
/ * Cr eat e and show a nest ed di al og */
var r esul t 2 = wi n2. show( ) ;
wi n2. cl ose( ) ;
wi n1. show( ) ;
wi n1. cl ose( ) ;
As noted in the J avaScript Tools Guide document, calling hi de( ) for a dialog window does not only
change the window's visibility; it is equivalent to calling cl ose( 0) , which removes the window from its
modal state. If the script calls show( ) a second time for this window to make it visible again, the
application is likely to crash when the window is finally closed. If your script requires the use of "nested"
modal dialogs, use a sequence like this instead:
var r esul t 1 = wi n1. show( ) ;
/ * Cr eat e and show a nest ed di al og */
var r esul t 2 = wi n2. show( ) ;
wi n2. cl ose( ) ;
wi n1. cl ose( ) ;
4.2. Application-specific appearance and behavior
When using the ESTK to develop scripts targeted at Adobe Photoshop
CS6, you will notice differences in the appearance of ScriptUI content created by running a script directly
in the ESTK, and content created by running the script in the application.
The ESTK uses a different version of ScriptUI than Photoshop and After Effects.
Jan 11, 2012 (ESTK version 3.8)
Adobe Systems Incorporated 5 of 17
- In the ESTK, user interface elements are created and managed by the operating system; a
ScriptUI Button element looks like (and is) a Mac OS X button, or Windows OS button,
depending on the platform.
- In the ScriptUI version used by Photoshop and After Effects, user-interface elements are created
and managed by the Adobe Flash