In article , Sybil wrote:
> I've gone through that reference guide and there is a class for the "web
> gallery" and all the options for that but none for the batch process.
> I suppose I could make a short cut key for the batch process and execute
> that but then how could I set all the options in that window? Or would I
> just have to take a longer route and program my own batch process... And for
> programs that don't have a shortcut key option how would you get to the menu
> options?
I'm not sure if the batch process is scriptable. I usually just use a
repeat loop with a list of files. You could also record a new action
and then call that...
Some things in PShop are scriptable with JavaScript and not AS... But
PShop will generate the javascript code for you. Make sure the
"ScriptingListener" plugin is in "Applications:Adobe Photoshop
CS:Plug-Ins:Adobe Photoshop Only:Automate:" It will create a file on
your desktop called "ScriptingListenerJS.log"
Any actions you do in PShop will be recorded to that file. The code at
the end of the file is the last thing you did.
You can then add it to your Applescript with the "do javascript"
operator.
For instance, here's a script I use to batch "autocorrect" images .
Watch the line breaks...
-----
on open fileList
tell application "Adobe Photoshop CS"
activate
set i to count of fileList
repeat i times
set thefile to (item i of fileList)
open thefile showing dialogs never
tell current document
do javascript "{var id110 = charIDToTypeID( \"Lvls\" );var
desc33 = new ActionDescriptor();var id111 = stringIDToTypeID
( \"autoBlackWhite\" ); desc33.putBoolean( id111, true ); var id112 =
stringIDToTypeID( \"autoNeutrals\" );desc33.putBoolean( id112, true
);executeAction( id110, desc33, DialogModes.NO );}"
if (characters -1 thru -3 of thefile = "JPG") then
save as JPEG with options {embed color profile:false,
matte:none, quality:12} without copying
close without saving
else
save
close without saving
end if
end tell
end repeat
end tell
end open
-----
>> Stay informed about: Photoshop Applescript