Document
QuickLinks
Hierarchy
Properties
Property | Type | Access | Description |
---|---|---|---|
afterBlendingIntent | RenderingIntent: RenderingIntent.USE_COLOR_SETTINGS RenderingIntent.PERCEPTUAL RenderingIntent.SATURATION RenderingIntent.RELATIVE_COLORIMETRIC RenderingIntent.ABSOLUTE_COLORIMETRIC |
r/w | The rendering intent for colors that result from transparency interactions on the page after blending. |
allGraphics | Array of Graphic | readonly | Lists all graphics contained by the Document. |
allPageItems | Array of PageItem | readonly | Lists all page items contained by the Document. |
associatedXMLElement | XMLElement | readonly | Returns the associated XML element |
bookmarks | Bookmarks | readonly | A collection of bookmarks. |
buttonPreferences | ButtonPreference | readonly | Button preference settings. |
buttons | Buttons | readonly | A collection of buttons. |
characterStyles | CharacterStyles | readonly | A collection of character styles. |
cmykProfile | string | r/w | The current CMYK profile. |
cmykProfileList | Array of string | readonly | A list of valid CMYK profiles. |
colors | Colors | readonly | A collection of colors. |
dashedStrokeStyles | DashedStrokeStyles | readonly | A collection of dashed stroke styles. |
dataMergeProperties | DataMerge | readonly | Data merge properties that define data merge fields and preferences. |
defaultImageIntent | RenderingIntent: RenderingIntent.USE_COLOR_SETTINGS RenderingIntent.PERCEPTUAL RenderingIntent.SATURATION RenderingIntent.RELATIVE_COLORIMETRIC RenderingIntent.ABSOLUTE_COLORIMETRIC |
r/w | The rendering intent for bitmap images. |
dictionaryPreferences | DictionaryPreference | readonly | User dictionary preference settings. |
documentPreferences | DocumentPreference | readonly | Document preference settings. |
dottedStrokeStyles | DottedStrokeStyles | readonly | A collection of dotted stroke styles. |
dtds | DTDs | readonly | A collection of DTDs. |
filePath | File | readonly | The full path to the file. |
fonts | Fonts | readonly | A collection of fonts. |
formFields | FormFields | readonly | A collection of form fields. |
fullName | File | readonly | The full path to the Document, including the name of the Document. |
galleyPreferences | GalleyPreference | readonly | Galley preference settings. |
gradients | Gradients | readonly | A collection of gradients. |
graphicLines | GraphicLines | readonly | A collection of graphic lines. |
gridPreferences | GridPreference | readonly | Grid preference settings. |
groups | Groups | readonly | A collection of groups. |
guidePreferences | GuidePreference | readonly | Guide preference settings. |
guides | Guides | readonly | A collection of guides. |
hyperlinkExternalPageDestinations | HyperlinkExternalPageDestinations | readonly | A collection of hyperlink external page destinations. |
hyperlinkPageDestinations | HyperlinkPageDestinations | readonly | A collection of hyperlink page destinations. |
hyperlinkPageItemSources | HyperlinkPageItemSources | readonly | A collection of hyperlink page item sources. |
hyperlinkTextDestinations | HyperlinkTextDestinations | readonly | A collection of hyperlink text destinations. |
hyperlinkTextSources | HyperlinkTextSources | readonly | A collection of hyperlink text sources. |
hyperlinkURLDestinations | HyperlinkURLDestinations | readonly | A collection of hyperlink URL destinations. |
hyperlinks | Hyperlinks | readonly | A collection of hyperlinks. |
hyphenationExceptions | HyphenationExceptions | readonly | A collection of hyphenation exceptions lists. |
index | number | readonly | The index of the Document within its containing object. |
indexGenerationOptions | IndexOptions | readonly | The index options properties that define how an index is formatted. |
indexes | Indexes | readonly | A collection of indexes. |
inks | Inks | readonly | A collection of inks. |
label | string | r/w | A property that can be set to any string. |
languages | Languages | readonly | A collection of languages. |
layers | Layers | readonly | A collection of layers. |
layoutAdjustmentPreferences | LayoutAdjustmentPreference | readonly | Layout sdjustment preference settings. |
layoutWindows | LayoutWindows | readonly | A collection of layout windows. |
links | Links | readonly | A collection of links. |
marginPreferences | MarginPreference | readonly | Margin preference settings. |
masterSpreads | MasterSpreads | readonly | A collection of master spreads. |
metadataPreferences | MetadataPreference | readonly | Metadata preference settings. |
mixedInkGroups | MixedInkGroups | readonly | A collection of mixed ink groups. |
mixedInks | MixedInks | readonly | A collection of mixed inks. |
modified | bool | readonly | If true, the Document has been modified since it was last saved. |
name | string | readonly | The name of the Document. |
ovals | Ovals | readonly | A collection of ellipses. |
packageForGoLivePreferences | PackageForGoLivePreference | readonly | The Package For GoLive preference properties that define how a document is packaged for GoLive. |
pageItems | PageItems | readonly | The page items collection, which can be used to process all page items in a container (such as a document, page, or group), regardless of type. |
pages | Pages | readonly | A collection of pages. |
paragraphStyles | ParagraphStyles | readonly | A collection of paragraph styles. |
parent | Application | readonly | The parent of the Document (a Application). |
pasteboardPreferences | PasteboardPreference | readonly | Pasteboard preference settings. |
polygonPreferences | PolygonPreference | readonly | Polygon preference properties to use to define default settings for creating a polygon. |
polygons | Polygons | readonly | A collection of polygons. |
printPreferences | PrintPreference | readonly | Print preference settings. |
properties | Object | r/w | A property that allows setting of several properties at the same time. |
rectangles | Rectangles | readonly | A collection of rectangles. |
redoName | string | readonly | The name of the action on the top of the redo stack. |
rgbProfile | string | r/w | The current RGB profile. |
rgbProfileList | Array of string | readonly | A list of valid RGB profiles. |
saved | bool | readonly | If true, the Document has been saved since it was created. |
sections | Sections | readonly | A collection of sections. |
selection |
Array
of Objects NothingEnum Object |
r/w | The selection. Can return: Object, Array of Objects or NothingEnum enumerator. |
solidColorIntent | RenderingIntent: RenderingIntent.USE_COLOR_SETTINGS RenderingIntent.PERCEPTUAL RenderingIntent.SATURATION RenderingIntent.RELATIVE_COLORIMETRIC RenderingIntent.ABSOLUTE_COLORIMETRIC |
r/w | The rendering intent for all vector art (areas of solid color) in native objects. |
spreads | Spreads | readonly | A collection of spreads. |
stories | Stories | readonly | A collection of stories. |
storyPreferences | StoryPreference | readonly | Story preference settings. |
storyWindows | StoryWindows | readonly | A collection of story windows. |
stripedStrokeStyles | StripedStrokeStyles | readonly | A collection of striped stroke styles. |
strokeStyles | StrokeStyles | readonly | A collection of stroke styles. |
swatches | Swatches | readonly | A collection of swatches. |
textDefaults | TextDefault | readonly | Text default settings. |
textFramePreferences | TextFramePreference | readonly | Text frame preference settings. |
textFrames | TextFrames | readonly | A collection of text frames. |
textPreferences | TextPreference | readonly | Text preference settings. |
tints | Tints | readonly | A collection of tints. |
tocStyles | TOCStyles | readonly | A collection of TOC styles. |
transparencyPreferences | TransparencyPreference | readonly | Transparency preference settings. |
trapPresets | TrapPresets | readonly | A collection of trap presets. |
undoName | string | readonly | The name of the action on the top of the undo stack. |
unusedSwatches | Array of Swatch | readonly | The swatches that are not being used. |
validationErrors | ValidationErrors | readonly | A collection of XML validation errors. |
viewPreferences | ViewPreference | readonly | View preference settings. |
visible | bool | readonly | If true, the Document is visible. |
windows | Windows | readonly | A collection of windows. |
xmlComments | XMLComments | readonly | A collection of XML comments. |
xmlElements | XMLElements | readonly | A collection of XML elements. |
xmlExportMaps | XMLExportMaps | readonly | A collection of XML export maps. |
xmlExportPreferences | XMLExportPreference | readonly | XML export preference settings. |
xmlImportMaps | XMLImportMaps | readonly | A collection of XML import maps. |
xmlImportPreferences | XMLImportPreference | readonly | XML import preference settings. |
xmlInstructions | XMLInstructions | readonly | A collection of XML instructions. |
xmlItems | XMLItems | readonly | A collection of XML items. |
xmlTags | XMLTags | readonly | A collection of XML tags. |
xmlViewPreferences | XMLViewPreference | readonly | XML view preference settings. |
zeroPoint | Array of Measurement Unit (Number or String) | r/w | The ruler origin, specified as page coordinates in the format [x, y]. |
Methods
Instances
void autoStyle ()
Auto styles the document based on the tag-to-style map.
void autoTag ()
Auto tags the document based on the style-to-tag map.
void close ([saving:
SaveOptions=SaveOptions.ASK][, savingIn:
File])
Closes the Document.
Parameter | Type | Description |
---|---|---|
saving | SaveOptions: SaveOptions.NO SaveOptions.ASK SaveOptions.YES | The option for saving changes. (Optional) (default: SaveOptions.ASK) |
savingIn | File | The file path of the saved document. Note: Required only when saving the document for the first time. If the document has previously been saved, specifying a path saves a copy and closes the original document. (Optional) |
TextFrame createTOC (using:
TOCStyle[, replacing:
bool=false][, fromBook:
Book][, placePoint:
Array
of Measurement Unit (Number or String)][, includeOverset:
bool=false][, destinationLayer:
Layer])
Create a table of contents for a document or book
Parameter | Type | Description |
---|---|---|
using | TOCStyle | The table of content style to use |
replacing | bool | Whether to replace the existing TOC (Optional) (default: false) |
fromBook | Book | The book from which to create the TOC (Optional) |
placePoint | Array of Measurement Unit (Number or String) | The point at which to place the TOC (Optional) |
includeOverset | bool | Whether to include overset text in the TOC (Optional) (default: false) |
destinationLayer | Layer | The layer on which to place the TOC (Optional) |
void deleteUnusedTags ()
Deletes unused XML markup tags.
void exportFile (format:
any, to:
File[, showingOptions:
bool=false][, using:
PDFExportPreset])
Exports the object(s) to a file.
Parameter | Type | Description |
---|---|---|
format | ExportFormat String | The export format. Can accept: ExportFormat enumerator or String. |
to | File | The path of the export file. |
showingOptions | bool | If true, prompts the user to select export options. (Optional) (default: false) |
using | PDFExportPreset | The export style to use. (Optional) |
string extractLabel (key:
string)
Gets the label value associated with the specified key.
Parameter | Type | Description |
---|---|---|
key | string | The key. |
void importDtd (from:
File)
Imports a DTD to use for validation.
Parameter | Type | Description |
---|---|---|
from | File | The path to the DTD file. |
void importStyles (format:
ImportFormat, from:
File)
Import styles.
Parameter | Type | Description |
---|---|---|
format | ImportFormat: ImportFormat.CHARACTER_STYLES_FORMAT ImportFormat.PARAGRAPH_STYLES_FORMAT ImportFormat.TEXT_STYLES_FORMAT ImportFormat.TOC_STYLES_FORMAT | The type of styles to import. |
from | File | an InDesign file to import from |
void importXML (from:
File)
Imports an XML file.
Parameter | Type | Description |
---|---|---|
from | File | The path to the XML file. |
void insertLabel (key:
string, value:
string)
Sets the label to the value associated with the specified key.
Parameter | Type | Description |
---|---|---|
key | string | The key. |
value | string | The value. |
void loadXMLTags (from:
File)
Loads a set of XML markup tags from the specified file.
Parameter | Type | Description |
---|---|---|
from | File | The path to the file that contains the tags. |
bool packageForGoLive (location:
File)
Packages for GoLive
Parameter | Type | Description |
---|---|---|
location | File | File location for package |
bool packageForPrint (to:
File, copyingFonts:
bool, copyingLinkedGraphics:
bool, copyingProfiles:
bool, updatingGraphics:
bool, includingHiddenLayers:
bool, ignorePreflightErrors:
bool, creatingReport:
bool)
Packages the document for handoff to a service provider.
Parameter | Type | Description |
---|---|---|
to | File | The folder, alias, or path in which to place the packaged files. |
copyingFonts | bool | If true, copies fonts used in the document to the package folder. |
copyingLinkedGraphics | bool | If true, copies linked graphics files to the package folder. |
copyingProfiles | bool | If true, copies color profiles to the package folder. |
updatingGraphics | bool | If true, updates graphics links to the package folder. |
includingHiddenLayers | bool | If true, copies fonts and links from hidden layers to the package. |
ignorePreflightErrors | bool | If true, ignores preflight errors and proceeds with the packaging. If false, cancels the packaging when errors exist. |
creatingReport | bool | If true, creates a package report that includes printing instructions, print settings, lists of fonts, links and required inks, and other information. |
void print ([printDialog:
bool][, using:
any])
Prints the Document(s).
Parameter | Type | Description |
---|---|---|
printDialog | bool | Whether to invoke the print dialog (Optional) |
using | PrinterPreset PrinterPresetTypes | Printer preset to use. Can accept: PrinterPresetTypes enumerator or PrinterPreset. (Optional) |
void redo ()
Redoes the last action.
void save ([to:
File][, stationery:
bool=false])
Save the document
Parameter | Type | Description |
---|---|---|
to | File | The file path. Note: Required only if the document has not been previously saved. If the document has previously been saved, specifying a path saves a copy and closes the original document. (Optional) |
stationery | bool | If true, saves the file as stationery (Mac OS) or as a template (Windows). Note: The file extension for stationery and templates is different than the extension for regular files. (Optional) (default: false) |
void saveXMLTags (to:
File)
Saves the XML markup tags as an XML file.
Parameter | Type | Description |
---|---|---|
to | File | The name and location of the XML file. |
Array
of Text search ([for:
string][, wholeWord:
bool][, caseSensitive:
bool][, replacingWith:
string][, withFindAttributes:
Object][, withChangeAttributes:
Object])
Look for occurrences of text that matches specific criteria
Parameter | Type | Description |
---|---|---|
for | string | What to look for (Optional) |
wholeWord | bool | If true, then disregard text embedded within a larger word (Optional) |
caseSensitive | bool | If true, then search only for text that matches case (Optional) |
replacingWith | string | What to replace the found text with, either a string or a special character (Optional) |
withFindAttributes | Object | A record of find preference settings to use (Optional) |
withChangeAttributes | Object | A record of change preference settings to use (Optional) |
void select (selectableItems:
any[, existingSelection:
SelectionOptions=SelectionOptions.REPLACE])
Select one or more objects.
Parameter | Type | Description |
---|---|---|
selectableItems |
Array
of Objects NothingEnum Object | The object(s) to select. Can accept: Object, Array of Objects or NothingEnum enumerator. |
existingSelection | SelectionOptions: SelectionOptions.ADD_TO SelectionOptions.REMOVE_FROM SelectionOptions.REPLACE | How to handle the existing selection (Optional) (default: SelectionOptions.REPLACE) |
Element of
Application.activeDocument
Book.styleSourceDocument
Bookmark.parent
ButtonPreference.parent
CharacterStyle.parent
Color.parent
DashedStrokeStyle.parent
DataMerge.parent
DictionaryPreference.parent
DocumentPreference.parent
DottedStrokeStyle.parent
Font.parent
GalleyPreference.parent
Gradient.parent
GridPreference.parent
GuidePreference.parent
Hyperlink.parent
HyperlinkExternalPageDestination.parent
HyperlinkPageDestination.parent
HyperlinkPageItemSource.parent
HyperlinkTextDestination.parent
HyperlinkTextSource.parent
HyperlinkURLDestination.parent
HyphenationException.parent
Index.parent
IndexOptions.parent
Ink.parent
Language.parent
Layer.parent
LayoutAdjustmentPreference.parent
LayoutWindow.parent
MarginPreference.parent
MasterSpread.parent
MetadataPreference.parent
MixedInk.parent
MixedInkGroup.parent
PackageForGoLivePreference.parent
Page.parent
ParagraphStyle.parent
PasteboardPreference.parent
PolygonPreference.parent
PrintPreference.parent
Section.parent
Spread.parent
Story.parent
StoryPreference.parent
StoryWindow.parent
StripedStrokeStyle.parent
StrokeStyle.parent
Swatch.parent
TOCStyle.parent
TextDefault.parent
TextFramePreference.parent
TextPreference.parent
Tint.parent
TransparencyPreference.parent
TrapPreset.parent
ValidationError.parent
ViewPreference.parent
Window.parent
XMLExportMap.parent
XMLExportPreference.parent
XMLImportMap.parent
XMLImportPreference.parent
XMLTag.parent
XMLViewPreference.parent
Used in:
array of any Asset.placeAsset (on: Document)
Bookmark Bookmark.move ([to: LocationOptions=LocationOptions.AT_END][, reference: any])
Button Buttons.add ([layer: Layer][, at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
GraphicLine GraphicLines.add ([layer: Layer][, at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
Group Groups.add (groupItems: Array of PageItem[, layer: Layer][, at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
Movie Movies.add ([layer: Layer][, at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
Oval Ovals.add ([layer: Layer][, at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
Page Pages.add ([at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
Polygon Polygons.add ([layer: Layer][, numberOfSides: number][, insetPercentage: number][, at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
Rectangle Rectangles.add ([layer: Layer][, at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
Section Sections.add ([at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
Sound Sounds.add ([layer: Layer][, at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
Spread Spread.duplicate ([to: LocationOptions=LocationOptions.AT_END][, reference: any])
Spread Spread.move ([to: LocationOptions=LocationOptions.AT_END][, reference: any])
Spread Spreads.add ([at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
TextFrame TextFrames.add ([layer: Layer][, at: LocationOptions=LocationOptions.UNKNOWN][, reference: any][, withProperties: Object])
Return
Document Documents.add ([showingWindow: bool=true][, documentPreset: DocumentPreset][, withProperties: Object])
Jongware, 27-Jun-2010 v3.0.3d | Contents :: Index |