Adobe Illustrator CS4 Type Library JS: Documents

Illustrator CS4

Class

Documents

 A collection of documents.

QuickLinks

[], add, addDocument, getByName

Hierarchy

Object
Documents

Properties

PropertyTypeAccessDescription
lengthint readonlyNumber of elements in the collection.
parentObject readonlyThe object's container.
typenamestring readonlyThe class name of the object.

Methods

Instances

Document [] (index: uint)
Get an element in the collection with the provided index.

ParameterTypeDescription
indexuint

Document add ([documentColorSpace: DocumentColorSpace=DocumentColorSpace.CMYK][, width: number=612.0][, height: number=792.0][, numArtboards: int=1][, artboardLayout: DocumentArtboardLayout=DocumentArtboardLayout.GridByRow][, artboardSpacing: number=20.0][, artboardRowsOrCols: int=1])
A document.

ParameterTypeDescription
documentColorSpaceDocumentColorSpace:
DocumentColorSpace.RGB
DocumentColorSpace.CMYK
The color model used for the document. (default: DocumentColorSpace.CMYK) (Optional)
widthnumberWidth of the artboard. (default: 612.0) (Optional)
heightnumberHeight of the artboard. (default: 792.0) (Optional)
numArtboardsintNumber of artboards for new document.Range (1:100). (default: 1) (Optional)
artboardLayoutDocumentArtboardLayout:
DocumentArtboardLayout.GridByRow
DocumentArtboardLayout.GridByCol
DocumentArtboardLayout.Row
DocumentArtboardLayout.Column
DocumentArtboardLayout.RLGridByRow
DocumentArtboardLayout.RLGridByCol
DocumentArtboardLayout.RLRow
Layout of artboards for new document. (default: DocumentArtboardLayout.GridByRow) (Optional)
artboardSpacingnumberSpacing between artboards for new document. (default: 20.0) (Optional)
artboardRowsOrColsintNumber of rows (for rows layout) OR column(for column layouts)of artboards.Range is 1 to (docNumArtboards - 1) or 1 for single row or column layouts. (default: 1) (Optional)

Document addDocument (startupPreset: string, presetSettings: DocumentPreset)
Create a document from the preset.

ParameterTypeDescription
startupPresetstringThe name of startup document preset.
presetSettingsDocumentPresetThe custom document preset settings.

Document getByName (name: string)
Get the first element in the collection with the provided name.

ParameterTypeDescription
namestring

Element of

Application.documents

Jongware, 27-Jun-2010 v3.0.3dContents :: Index