Copy link to clipboard
Copied
Hello,
I have had some success in altering the generic SaveAsPDF scripts that come with Illustrator to suit my PDF workflow. I would now like to take one of these scripts and turn it into one that will save an AI file with all of the type outlined.
I am using the 2014 Java Scripting Guide, and have located this snippet, which is used to export to an Illustrator 8 file.
function exportFileToAI (dest) {
if ( app.documents.length > 0 ) {
var saveOptions = new IllustratorSaveOptions();
var ai8Doc = new File(dest);
saveOptions.compatibility = Compatibility.ILLUSTRATOR8;
saveOptions.flattenOutput = OutputFlattening.PRESERVEAPPEARANCE;
app.activeDocument.saveAs( ai8Doc, saveOptions );
}
}
Using this as a starting point, what would you suggest? I found convertTextToOutlines in PrintFlattenerOptions. Only thing is that I only want to outline the live type...
Would it be something like...
var flattenOptions = new PrintFlattenerOptions();
flattenOptions.convertTextToOutlines = true
Copy link to clipboard
Copied
I found this in another thread and wonder if using an action to outline the type would be better since I don't want to flatten the transparency... just want to convert the live type to outlines.
Copy link to clipboard
Copied
Are you just going to put someone's answer into your own snippet and mark it as correct? Technically, there's nothing wrong with that as long as the actual answer gets answered.
Use this:
app.executeMenuCommand("outline");
Copy link to clipboard
Copied
I did not mean to mark it as correct... If I did, it was by mistake. Thanks for your reply.