LayoutSpread

A spread.

Instance Properties

Name Description Access
allGraphics Graphic Lists all graphics contained by the Spread. read-only
allPageItems PageItem Lists all page items contained by the Spread. read-only
allowPageShuffle bool If true, guarantees that when pages are added to a spread it will contain a maximum of two pages. If false, allows pages to be added or moved into existing spreads. For override information, see preserve layout when shuffling. read-write
appliedMaster MasterSpread The master spread applied to the Spread. Can also accept: NothingEnum enumerator. read-write
buttons Buttons A collection of buttons. read-only
checkBoxes CheckBoxes A collection of checkboxes. read-only
comboBoxes ComboBoxes A collection of comboboxes. read-only
endnoteTextFrames EndnoteTextFrames A collection of endnote text frames. read-only
epstexts EPSTexts EPSTexts read-only
eventListeners EventListeners A collection of event listeners. read-only
events Events A collection of events. read-only
flattenerOverride SpreadFlattenerLevel The transparency flattener preferences override for the spread. read-write
flattenerPreferences FlattenerPreference Flattener preference settings. read-only
formFields FormFields A collection of form fields. read-only
graphicLines GraphicLines A collection of graphic lines. read-only
groups Groups A collection of groups. read-only
guides Guides A collection of guides. read-only
id number The unique ID of the Spread. read-only
idmlComponentName string The IDML component name of the Spread. read-write
index number The index of the Spread within its containing object. read-only
isValid bool Returns true if the object specifier resolves to valid objects. read-only
label string A property that can be set to any string. read-write
listBoxes ListBoxes A collection of listboxes. read-only
multiStateObjects MultiStateObjects A collection of multi-state objects. read-only
name string The name of the Spread; this is an alias to the Spread's label property. read-write
ovals Ovals A collection of ellipses. read-only
pageItems PageItems 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. read-only
pageTransitionDirection PageTransitionDirectionOptions The direction of the page transition. read-write
pageTransitionDuration PageTransitionDurationOptions The duration of the page transition. read-write
pageTransitionType PageTransitionTypeOptions The type of page transition. read-write
pages Pages A collection of pages. read-only
parent Document The parent of the Spread (a Document). read-only
polygons Polygons A collection of polygons. read-only
preferences Preferences A collection of preferences objects. read-only
properties Object A property that allows setting of several properties at the same time. read-write
radioButtons RadioButtons A collection of radio buttons. read-only
rectangles Rectangles A collection of rectangles. read-only
showMasterItems bool If true, displays master page items on document pages in the spread. read-write
signatureFields SignatureFields A collection of signature fields. read-only
splineItems SplineItems The spline items collection. read-only
textBoxes TextBoxes A collection of text boxes. read-only
textFrames TextFrames A collection of text frames. read-only
timingSettings TimingSetting The object timing settings. read-only

Methods

addEventListener(
eventType, handler ​[, captures])
 → EventListener
contentPlace(
pageItems ​[, linkPageItems] ​[, linkStories] ​[, mapStyles] ​[, placePoint] ​[, destinationLayer] ​[, showingOptions])
createGuides(
[numberOfRows] ​[, numberOfColumns] ​[, rowGutter] ​[, columnGutter], guideColor ​[, fitMargins] ​[, removeExisting] ​[, layer])
detach(
)
duplicate(
[to], reference)
extractLabel(
key)
 → string
getElements(
)
 → Spread
insertLabel(
key, value)
move(
[to], reference)
 → Spread
place(
fileName ​[, placePoint] ​[, destinationLayer] ​[, showingOptions] ​[, autoflowing] ​[, withProperties])
placeAndLink(
parentStory ​[, placePoint] ​[, destinationLayer] ​[, showingOptions])
 → Story
placeXML(
using, placePoint ​[, autoflowing])
 → PageItem
remove(
)
removeEventListener(
eventType, handler ​[, captures])
 → bool
resolve(
location, in ​[, consideringRulerUnits])
select(
[existingSelection])
setContent(
using ​[, relativeBasePath])
 → PageItem
toSource(
)
 → string
toSpecifier(
)
 → string
transform(
in, from, withMatrix, replacingCurrent ​[, consideringRulerUnits])
addEventListener(
eventType, handler ​[, captures=false])
 → EventListener
Adds an event listener.
eventType string The event type.
handler The event handler. Can accept: File or JavaScript Function.
captures bool This parameter is obsolete. (Optional)
contentPlace(
pageItems ​[, linkPageItems=false] ​[, linkStories=false] ​[, mapStyles=false] ​[, placePoint] ​[, destinationLayer] ​[, showingOptions=false])
Duplicate an object and place it into the target.
pageItems Array<PageItem> One or more page items to place or load
linkPageItems bool Whether to link pageItems in content placer (if true it will override link stories value) (Optional)
linkStories bool Whether to link stories in content placer (only applicable for single story, pageItem links will also be created in case of more than one item) (Optional)
mapStyles bool Whether to map styles in content placer (Optional)
placePoint Array<Measurement Unit (Number or String)=any> The point at which to place (Optional)
destinationLayer Layer The layer on which to place (Optional)
showingOptions bool Whether to display the link options dialog (Optional)
createGuides(
[numberOfRows=0] ​[, numberOfColumns=0] ​[, rowGutter=0] ​[, columnGutter=0], guideColor ​[, fitMargins=false] ​[, removeExisting=false] ​[, layer])
Creates multiple guides on all pages of the spread.
numberOfRows number The number of rows to create on each page. (Optional)
numberOfColumns number The number of columns to create on each page. (Optional)
rowGutter Measurement Unit (Number or String)=any The height of the gutter between rows. (Optional)
columnGutter Measurement Unit (Number or String)=any The width of the gutter between columns. (Optional)
guideColor The color to make the guides, specified either as an array of three doubles, each in the range 0 to 255 and representing R, G, and B values, or as a UI color. Can accept: Array of 3 Reals (0 - 255) or UIColors enumerator. (Optional)
fitMargins bool If true, the row height and column width are calculated based on the space within the page margins. If false, row height and column width are calculated based on the full page. (Optional)
removeExisting bool If true, removes existing guides when creating new ones. (Optional)
layer Layer The layer on which to create the guides. (Optional)
detach(
)
Detaches an overridden master page item from the master page.
duplicate(
[to=LocationOptions.AT_END], reference)
Duplicates the spread.
to LocationOptions The location of the spread relative to the reference object or within the document. (Optional)
reference The reference object. Note: Required only when the to parameter specifies before or after. Can accept: Spread, Document or MasterSpread. (Optional)
extractLabel(
key)
 → string
Gets the label value associated with the specified key.
key string The key.
getElements(
)
 → Spread
Resolves the object specifier, creating an array of object references.
insertLabel(
key, value)
Sets the label to the value associated with the specified key.
key string The key.
value string The value.
move(
[to=LocationOptions.AT_END], reference)
 → Spread
Moves the spread.
to LocationOptions The location of the spread relative to the reference object or within the document. (Optional)
reference The reference object. Note: Required when the to parameter specifies before or after. Can accept: Spread, Page or Document. (Optional)
place(
fileName ​[, placePoint] ​[, destinationLayer] ​[, showingOptions=false] ​[, autoflowing=false] ​[, withProperties])
Places the file.
fileName File The file to place
placePoint Array<Measurement Unit (Number or String)=any> The point at which to place (Optional)
destinationLayer Layer The layer on which to place (Optional)
showingOptions bool Whether to display the import options dialog (Optional)
autoflowing bool Whether to autoflow placed text (Optional)
withProperties Object Initial values for properties of the placed object(s) (Optional)
placeAndLink(
parentStory ​[, placePoint] ​[, destinationLayer] ​[, showingOptions=false])
 → Story
Deprecated: Use contentPlace method. Original Description: Create a linked story and place it into the target.
parentStory Story The story to place and link from.
placePoint Array<Measurement Unit (Number or String)=any> The point at which to place (Optional)
destinationLayer Layer The layer on which to place (Optional)
showingOptions bool Whether to display the link options dialog (Optional)
placeXML(
using, placePoint ​[, autoflowing=false])
 → PageItem
Places the XML element onto a page. If the place point is above an existing page item, place the XML element into the page item.
using XMLElement The XML element to place.
placePoint Array<Measurement Unit (Number or String)=any> The point at which to place the object, specified in the format [x, y].
autoflowing bool If true, autoflows placed text. (Optional)
remove(
)
Deletes the Spread.
removeEventListener(
eventType, handler ​[, captures=false])
 → bool
Removes the event listener.
eventType string The registered event type.
handler The registered event handler. Can accept: File or JavaScript Function.
captures bool This parameter is obsolete. (Optional)
removeOverride(
)
Removes the override from a previously overridden master page item.
resolve(
location, in ​[, consideringRulerUnits=false])
Get the coordinates of the given location in the specified coordinate system.
location The location requested. Can accept: Array of 2 Reals, AnchorPoint enumerator or Array of Arrays of 2 Reals, CoordinateSpaces enumerators, AnchorPoint enumerators, BoundingBoxLimits enumerators or Long Integers.
in CoordinateSpaces The coordinate space to use.
consideringRulerUnits bool If true then a ruler location is interpreted using ruler units rather than points. The default value is false. This parameter has no effect unless the reference point is specified relative to a page. (Optional)
select(
[existingSelection=SelectionOptions.REPLACE_WITH])
Selects the object.
existingSelection SelectionOptions The selection status of the Spread in relation to previously selected objects. (Optional)
setContent(
using ​[, relativeBasePath])
 → PageItem
Replaces the content of XML element with content imported from a file.
using string The file path to the import file.
relativeBasePath string Base path used to resolve relative paths. (Optional)
toSource(
)
 → string
Generates a string which, if executed, will return the Spread.
toSpecifier(
)
 → string
Retrieves the object specifier.
transform(
in, from, withMatrix, replacingCurrent ​[, consideringRulerUnits=false])
Transform the page item.
in CoordinateSpaces The coordinate space to use
from The temporary origin during the transformation. Can accept: Array of 2 Reals, AnchorPoint enumerator or Array of Arrays of 2 Reals, CoordinateSpaces enumerators, AnchorPoint enumerators, BoundingBoxLimits enumerators or Long Integers.
withMatrix Transform matrix. Can accept: Array of 6 Reals or TransformationMatrix.
replacingCurrent Transform components to consider; providing this optional parameter causes the target's existing transform components to be replaced with new values. Without this parameter, the given matrix is concatenated onto the target's existing transform combining the effect of the two. Can accept: MatrixContent enumerator, Array of MatrixContent enumerators or Long Integer. (Optional)
consideringRulerUnits bool If true then a ruler based origin is interpreted using ruler units rather than points. The default value is false. This parameter has no effect unless the reference point is specified relative to a page. (Optional)
transformValuesOf(
in)
 → TransformationMatrix
Get the transformation values of the page item.
in CoordinateSpaces The coordinate space to use