EPSSaveOptions
EPSSaveOptions
Section titled “EPSSaveOptions”epsSaveOptions
Description
Section titled “Description”Options for saving a document as an Illustrator EPS file, used with the Document.saveAs() method.
All properties are optional.
Properties
Section titled “Properties”EPSSaveOptions.artboardRange
Section titled “EPSSaveOptions.artboardRange”epsSaveOptions.artboardRange
Description
Section titled “Description”If saveMultipleArtboards is true, this is considered for multi-asset extraction, which specifies the artboard range. An empty string extracts all the artboards.
Default: empty string
String.
EPSSaveOptions.cmykPostScript
Section titled “EPSSaveOptions.cmykPostScript”epsSaveOptions.cmykPostScript
Description
Section titled “Description”If true, use CMYK PostScript.
Boolean.
EPSSaveOptions.compatibility
Section titled “EPSSaveOptions.compatibility”epsSaveOptions.compatibility
Description
Section titled “Description”Specifies the version of the EPS file format to save.
Default: Compatibility.ILLUSTRATOR1719.
EPSSaveOptions.compatibleGradientPrinting
Section titled “EPSSaveOptions.compatibleGradientPrinting”epsSaveOptions.compatibleGradientPrinting
Description
Section titled “Description”If true, create a raster item of the gradient or gradient mesh so that PostScript Level 2 printers can print the object.
Default: false.
Boolean.
EPSSaveOptions.embedAllFonts
Section titled “EPSSaveOptions.embedAllFonts”epsSaveOptions.embedAllFonts
Description
Section titled “Description”If true, all fonts used by the document should be embedded in the saved file (version 7 or later).
Default: false.
Boolean.
EPSSaveOptions.embedLinkedFiles
Section titled “EPSSaveOptions.embedLinkedFiles”epsSaveOptions.embedLinkedFiles
Description
Section titled “Description”If true, linked image files are to be included in the saved document.
Boolean.
EPSSaveOptions.flattenOuput
Section titled “EPSSaveOptions.flattenOuput”epsSaveOptions.flattenOuput
Description
Section titled “Description”How should transparency be flattened for file formats older than Illustrator 9.
EPSSaveOptions.includeDocumentThumbnails
Section titled “EPSSaveOptions.includeDocumentThumbnails”epsSaveOptions.includeDocumentThumbnails
Description
Section titled “Description”If true, thumbnail image of the EPS artwork should be included.
Boolean.
EPSSaveOptions.overprint
Section titled “EPSSaveOptions.overprint”epsSaveOptions.overprint
Description
Section titled “Description”Whether to preserve, discard, or simulate the overprint.
Default: PDFOverprint.PRESERVEPDFOVERPRINT.
EPSSaveOptions.postScript
Section titled “EPSSaveOptions.postScript”epsSaveOptions.postScript
Description
Section titled “Description”PostScript Language Level to use (Level 1 valid for file format version 8 or older).
Default: EPSPostScriptLevelEnum.LEVEL2.
EPSSaveOptions.preview
Section titled “EPSSaveOptions.preview”epsSaveOptions.preview
Description
Section titled “Description”The format for the EPS preview image.
EPSSaveOptions.saveMultipleArtboards
Section titled “EPSSaveOptions.saveMultipleArtboards”epsSaveOptions.saveMultipleArtboards
Description
Section titled “Description”If true, all artboards or range of artboards are saved.
Default: false.
Boolean.
EPSSaveOptions.typename
Section titled “EPSSaveOptions.typename”epsSaveOptions.typename
Description
Section titled “Description”The class name of the referenced object.
String; read-only.
Example
Section titled “Example”Exporting to EPS format
Section titled “Exporting to EPS format”// Exports current document to destFile as an EPS file with specified options,// destFile contains the full path including the file name
function exportFileAsEPS(destFile) { var newFile = new File(destFile); var saveDoc; if (app.documents.length == 0) { saveDoc = app.documents.add(); } else { saveDoc = app.activeDocument; }
var saveOpts = new ePSSaveOptions(); saveOpts.cmykPostScript = true; saveOpts.embedAllFonts = true;
saveDoc.saveAs(newFile, saveOpts);}