Skip to content

ExportOptionsPhotoshop

exportOptionsPhotoshop

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.


exportOptionsPhotoshop.antiAliasing

If true, the exported image should be anti-aliased.

Default: true.

Boolean.


exportOptionsPhotoshop.artboardRange

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

If true, text objects should be exported as editable text layers.

Default: true.

Boolean.


exportOptionsPhotoshop.embedICCProfile

If true, an ICC profile should be embedded in the exported file.

Default: false.

Boolean.


exportOptionsPhotoshop.imageColorSpace

The color space of the exported file.

Default: ImageColorSpace.RGB.

ImageColorSpace


exportOptionsPhotoshop.maximumEditability

Preserve as much of the original document’s structure as possible when exporting.

Default: true.

Boolean.


exportOptionsPhotoshop.resolution

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

If true, all artboards or range of artboards are saved.

Default: false.

Boolean.


exportOptionsPhotoshop.typename

The class name of the referenced object.

String; read-only.


exportOptionsPhotoshop.warnings

If true, a warning dialog should be displayed in case of conflicts in the export settings.

Default: true.

Boolean.


exportOptionsPhotoshop.writeLayers

If true, the document layers should be presented in the exported document.

Default: true.

Boolean.


// 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);
}
}