Scripting Resources


Adobe is nice enough to include extensive scripting documentation and tools with Photoshop, which means you already have them on your hard disk. In addition, many script-oriented Web sites provide free scripts and forums where you can ask questions and exchange ideas and code.

Scripting Documentation

In the Scripting Guide folder inside the Adobe Photoshop CS2 application folder, you'll find the following documentation for scripting:

  • Photoshop Scripting Guide

  • AppleScript Reference Guide

  • JavaScript Reference Guide

  • VisualBasic Reference Guide

The first PDF you'll probably want to read is the Photoshop Scripting Guide, because that document gives you an overview of scripting in Photoshop. After you read that, refer to one of the other three documents for the specific scripting language you want to use.

Loading Scripts

Photoshop loads scripts from the Scripts folder, located inside the Presets folder in the Adobe Photoshop CS2 application folder. You'll find a number of sample scripts already stored there, and it's where you should store scripts that you want to see in the File > Scripts submenu in Photoshop. The scripts in the Scripts folder also appear in Bridge, in the Tools menu.

In Photoshop, you can also load scripts from any disk or mounted volume by choosing File > Scripts > Browse.

Scripting Utilities

Photoshop installs a few utilities that help you create and use scripts, which are all located inside the Adobe Photoshop CS2 application folder. You can also use other utilities that are included with your operating system. Here's an overview of what you already have:

  • ExtendScript Toolkit. Use this utility to write, edit, and debug JavaScripts. It's documented in the JavaScript Reference Guide. On Mac OS X< ExtendScript Toolkit is installed in your Utilities folder, which is inside your Applcations folder. On Windows XP, ExtendScript Toolkit is installed in:

       c:\Program Files\Adobe\Adobe Utilities\ExtendScript Toolkit\ 

  • Script Listener. You'll find it in the folder Adobe Photoshop CS2/Scripting Guide/Utilities. You do need to install it; do that by dragging it into the folder Adobe Photoshop CS2/Plug-Ins/Adobe Photoshop Only/Automate. Then restart Photoshop. As long as it's installed, everything you do in Photoshop is recorded as JavaScript in the file ScriptingListenerJS.log which appears on the desktop (Mac OS X) or at c:\(Windows XP). I show you how to use it in the example later in the chapter.

  • Script Events Manager. This is the utility I mentioned earlier that runs a script when something specific happens in Photoshop. You run it by choosing File > Scripts > Script Events Manager.

  • A text editor or log reader. You can use a text editor to write or edit the scripts you create or want to modify. Both Mac OS X and Windows come with text editors. On Mac OS X, you can use TextEdit. On Windows XP, you can use Notepad or WordPad. You can also use a text editor to examine script log files such as ScriptingListenerJS.log, but it's usually better to use a log reader such as Console on Mac OS X, because a log reader can continually update the log.

Web Sites About Scripting

There are many Web sites where you can find scripting tutorials, information, discussions, and examples. Here are just a few to get you started; a search engine will turn up many more:

The Adobe Design Center, which contains scripts for Photoshop

   share.studio.adobe.com/axBrowseSubmit.asp?t=74 


Adobe Design Center scripts for Bridge

   share.studio.adobe.com/axBrowseSubmit.asp?c=222 


JavaScript Reference for Bridge

   www.adobe.com/products/creativesuite/pdfs/bridge_javascript_ref.pdf 


The Adobe User-to-User Forum for Photoshop Scripting

Go to www.adobeforums.com/, then click Adobe Photoshop and ImageReady, then click Photoshop Scripting.

Jeff Tranberry's Photoshop scripting page

   www.tranberry.com/photoshop/photoshop_scripting/index.html 


The Fotofects scripting tutorial

   fotofects.com/articles/362/1/Photoshop-Scripting-Basics 





Working Smart in Adobe Photoshop CS2
Working Smart in Adobe Photoshop CS2
ISBN: 0321335392
EAN: 2147483647
Year: N/A
Pages: 161
Authors: Conrad Chavez

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net