ExportOptionsPhotoshop
ExportOptionsPhotoshop
Section titled “ExportOptionsPhotoshop”exportOptionsPhotoshop
Description
Section titled “Description”Options for exporting a document as a Photoshop file, used with the Document.exportFile() method. All properties are optional.
When you export a document, the appropriate file extension is appended automatically. You should not include any file extension in the file specification.
Properties
Section titled “Properties”ExportOptionsPhotoshop.antiAliasing
Section titled “ExportOptionsPhotoshop.antiAliasing”exportOptionsPhotoshop.antiAliasing
Description
Section titled “Description”If true
, the exported image should be anti-aliased.
Default: true
.
Boolean.
ExportOptionsPhotoshop.artboardRange
Section titled “ExportOptionsPhotoshop.artboardRange”exportOptionsPhotoshop.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.
ExportOptionsPhotoshop.editableText
Section titled “ExportOptionsPhotoshop.editableText”exportOptionsPhotoshop.editableText
Description
Section titled “Description”If true
, text objects should be exported as editable text layers.
Default: true
.
Boolean.
ExportOptionsPhotoshop.embedICCProfile
Section titled “ExportOptionsPhotoshop.embedICCProfile”exportOptionsPhotoshop.embedICCProfile
Description
Section titled “Description”If true
, an ICC profile should be embedded in the exported file.
Default: false
.
Boolean.
ExportOptionsPhotoshop.imageColorSpace
Section titled “ExportOptionsPhotoshop.imageColorSpace”exportOptionsPhotoshop.imageColorSpace
Description
Section titled “Description”The color space of the exported file.
Default: ImageColorSpace.RGB
.
ExportOptionsPhotoshop.maximumEditability
Section titled “ExportOptionsPhotoshop.maximumEditability”exportOptionsPhotoshop.maximumEditability
Description
Section titled “Description”Preserve as much of the original document’s structure as possible when exporting.
Default: true
.
Boolean.
ExportOptionsPhotoshop.resolution
Section titled “ExportOptionsPhotoshop.resolution”exportOptionsPhotoshop.resolution
Description
Section titled “Description”Resolution of the exported file in dots per inch (dpi).
Range: 72.0 to 2400.0.
Default: 150.0.
Number (double).
ExportOptionsPhotoshop.saveMultipleArtboards
Section titled “ExportOptionsPhotoshop.saveMultipleArtboards”exportOptionsPhotoshop.saveMultipleArtboards
Description
Section titled “Description”If true
, all artboards or range of artboards are saved.
Default: false
.
Boolean.
ExportOptionsPhotoshop.typename
Section titled “ExportOptionsPhotoshop.typename”exportOptionsPhotoshop.typename
Description
Section titled “Description”The class name of the referenced object.
String; read-only.
ExportOptionsPhotoshop.warnings
Section titled “ExportOptionsPhotoshop.warnings”exportOptionsPhotoshop.warnings
Description
Section titled “Description”If true
, a warning dialog should be displayed in case of conflicts in the export settings.
Default: true
.
Boolean.
ExportOptionsPhotoshop.writeLayers
Section titled “ExportOptionsPhotoshop.writeLayers”exportOptionsPhotoshop.writeLayers
Description
Section titled “Description”If true
, the document layers should be presented in the exported document.
Default: true
.
Boolean.
Example
Section titled “Example”Exporting to Photoshop format
Section titled “Exporting to Photoshop format”// Exports current document to dest as a PSD file with specified options,// dest contains the full path including the file name
function exportFileToPSD(dest) { if (app.documents.length > 0) { var exportOptions = new ExportOptionsPhotoshop(); exportOptions.resolution = 150;
var type = ExportType.PHOTOSHOP; var fileSpec = new File(dest);
app.activeDocument.exportFile(fileSpec, type, exportOptions); }}