: Efficient use of Illustrator's export File Dialogue When I File > Export using Artboards from Illustrator the (OSX)file dialogue is always pointing at the directory where the Illustrator document
When I File > Export using Artboards from Illustrator the (OSX)file dialogue is always pointing at the directory where the Illustrator document is located. If I need to export to a different directory I have to navigate through the filesystem to find it.
The next time I export Illustrator has forgotten this directory and I have to do this all over again. When I am exporting, previewing a webpage that uses the artwork, tweaking and re-exporting repeatedly this is a massive speed bump. I'm sure the answer is painfully simple but what is it?
More posts by @Kevin459
2 Comments
Sorted by latest first Latest Oldest Best
There is a shortcut in OSX that presents the last few folders in the save dialog,
In the save dialog window, directly under the filename area is a dropdown that reveals the folder structure for the current folder AND below that list is one called 'recent places' which list your most recent folders.
Not automated but very handy, so to is the 'save for web' option remembers last folder.
I use a js to export artboards. It remembers the last directory. For a repetitious cycle like you describe, this would probably be a faster solution for you.
Any artboard you want exported should be appended with the correct file extension. Compression and type can be included after the extension:
/*
Artboard1.jpg60 <-- without the compression it picks up Adobe's default (30!)
Artboard2.png <-- exports to 24 by default
Artboard3.png8
*/
#target illustrator
var i, il, j, jl, m, doc, filepath, filetype, filetypes, filename;
doc = app.activeDocument;
/*filepath = doc.fullName.path;*/
filepath = Folder.selectDialog("Pick your destination")
// Build Export Options
filetypes = [
{ pattern: /.png(24)?$/i, rename: ".png", type: ExportType.PNG24, options: new ExportOptionsPNG24() },
{ pattern: /.png8$/i, rename: ".png", type: ExportType.PNG8 , options: new ExportOptionsPNG8() },
{ pattern: /.jpg(d+)?$/i, rename: ".jpg", type: ExportType.JPEG, options: new ExportOptionsJPEG() },
{ pattern: /.gif$/i, type: ExportType.GIF, options: new ExportOptionsGIF() }
];
for (j=0, jl=filetypes.length; j<jl; j++) {
filetypes[j].options.artBoardClipping = true;
}
// Export Artboards
for (i=0, il=doc.artboards.length; i<il; i++) {
doc.artboards.setActiveArtboardIndex(i);
filename = doc.artboards[i].name;
if (filename) {
for (j=0, jl=filetypes.length; j<jl; j++) {
filetype = filetypes[j];
m = filetype.pattern.exec(filename);
if (m) {
if (filetype.rename) { filename = filename.replace(filetype.pattern, filetype.rename); }
if (filetype.type === ExportType.JPEG) {
if (m[1]) {
filetype.options.qualitySetting = parseInt(m[1], 10);
} else {
filetype.options.qualitySetting = 72;
}
}
doc.exportFile (File(filepath + "/" + filename), filetype.type, filetype.options);
}
}
}
}
Terms of Use Create Support ticket Your support tickets Stock Market News! © vmapp.org2024 All Rights reserved.