Post Archive
› June 24, 2004
Adobe Illustrator Scripting
Do you use Adobe Illustrator as a regular part of your workflow? It might make sense to look into the scripting options available to optimize some of your tasks. Naturally the first place you might go is to the Adobe Studio Exchange, but the choices there seem paltry. I found another place for such scripts that seemed worth noting. This 2002 book (Adobe Illustrator Scripting) on the subject has a big download file with tons of scripts, find Mac and Win versions linked here. If it's time to craft your own script, you might appreciate this big PDF tutorial (direct PDF link) found via googling. Do you have any tips or sites worth checking out on the subject?
Comments
1. June 24, 2004 05:46 PM
2. June 24, 2004 08:41 PM
3. February 4, 2005 03:12 PM
matt Posted…
Ever do any scripting in Illustrator with javascript? I'm working on my first script in Illustrator, but have come to a stopping point, since I'm convinced that I've found a bug in Illustrator. What's happening is no matter what I have tried, the matte color on gif output always defaults to black even though the documented default is white. Found two identical posts on adobe's forum but nobody has replied to those, i can't ask them if they have found the solution since the two posts are archives, and I can't find where to post a new message, not too happy with the Adobe forum. I have setup a color object for the matte, but it doesn't apply when the image is outputted.
Here's how I've setup for GIF output:
var exportOptions = new ExportOptionsGIF();
var type = ExportType.GIF;
exportOptions.transparency = true;
exportOptions.matte = true;
var myColor = new RGBColor();
myColor.red = 255;
myColor.green = 255;
myColor.blue = 255;
exportOptions.matteColor = myColor;
exportOptions.interlaced = true;
exportOptions.colorCount = 128;
exportOptions.colorDither = ColorDitherMethod.NOREDUCTION;
var fileSpec = new File("/x/test.gif");
app.activeDocument.exportFile( fileSpec, type );
And ideas on why matte is always changing to black?
Iolaire McFadden Posted…
I work with some maps that I've automated in VB to change layer colors, icons, and text boxes in Illustrator for quarterly real estate market reports. The rest is done in InDesign.
Illustrator is a little harder to find help with than InDesign. There are some postings at: http://www.adobeforums.com/cgi-bin/webx?14@@.eea5b36 for Illustrator, unfortunately nothing like the 20 - 30 per day in the InDesign Folder. For the Mac there are some postings at http://macscripter.net/
I will say that if you follow the examples in the Scripting Guide you should be off to a good start. Also one plus for the Illustrator Scripting Guide is it was more complete than InDesign - at least at the 2.0 version (we are at CS now).
If anyone has specific questions I'd be happy to try to help they work through solutions. Primarily I script in VB on the PC, but I have a Mac (only) a home and desire to work more in Apple Script so I'm willing to try to help on both platforms - just Mac will take longer. Feel free to contact me at iolaire ... usa.net for Apple Script stuff or imfadden ... costar.com for VB.
Good luck, iolaire PS: Main scripting documentation site is: http://partners.adobe.com/asn/illustrator/scripting.jsp Also to note that you can now program in Java also! But I can not help with that - yet.