PlaceGun

Represents the place gun.

Methods:

abortPlaceGun, addEventListener, getElements, loadPlaceGun, removeEventListener, rotate, toSource, toSpecifier

Objects:

Boolean, Buttons, CheckBoxes, ComboBoxes, EPSTexts, EPSs, EventListeners, Events, FormFields, GraphicLines, Graphics, Groups, Images, ImportedPages, ListBoxes, MultiStateObjects, Object, Ovals, PDFs, PICTs, PageItems, Polygons, RadioButtons, Rectangles, SVGs, SignatureFields, Snippets, SplineItems, TextBoxes, TextFrames, WMFs

Hierarchy:

Superclass: Preference

Class: PlaceGun

Property Listing

Property

Type

Access

Description

buttons

Buttons Button

readonly

A collection of buttons.

checkBoxes

CheckBoxes

readonly

A collection of checkboxes.

comboBoxes

ComboBoxes

readonly

A collection of comboboxes.

epss

EPSs EPS

readonly

A collection of EPS files.

epstexts

EPSTexts EPSText

readonly

EPSTexts

eventListeners

EventListeners EventListener

readonly

A collection of event listeners.

events

Events Event

readonly

A collection of events.

formFields

FormFields FormField

readonly

A collection of form fields.

graphicLines

GraphicLines GraphicLine

readonly

A collection of graphic lines.

graphics

Graphics Graphic

readonly

A collection of imported graphics in any graphic file format (vector, metafile, or bitmap).

groups

Groups Group

readonly

A collection of groups.

images

Images Image

readonly

A collection of bitmap images in any bitmap file format (including TIFF, JPEG, or GIF).

importedPages

ImportedPages ImportedPage

readonly

Imported InDesign pages.

isValid

Boolean

readonly

Returns true if the object specifier resolves to valid objects.

listBoxes

ListBoxes

readonly

A collection of listboxes.

loaded

Boolean

readonly

Whether the place gun is currently loaded with content for placing.

multiStateObjects

MultiStateObjects MultiStateObject

readonly

A collection of multi-state objects.

ovals

Ovals Oval

readonly

A collection of ellipses.

pageItems

PageItems PageItem

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.

parent

Document

readonly

The parent of the PlaceGun (a Document).

pdfs

PDFs PDF

readonly

A collection of PDF files.

picts

PICTs PICT

readonly

A collection of PICT graphics.

polygons

Polygons Polygon

readonly

A collection of polygons.

properties

Object

read/write

A property that allows setting of several properties at the same time.

radioButtons

RadioButtons RadioButton

readonly

A collection of radio buttons.

rectangles

Rectangles Rectangle

readonly

A collection of rectangles.

signatureFields

SignatureFields SignatureField

readonly

A collection of signature fields.

snippets

Snippets Snippet

readonly

A collection of IDML snippets.

splineItems

SplineItems SplineItem

readonly

The spline items collection.

svgs

SVGs SVG

readonly

A collection of SVG files.

textBoxes

TextBoxes

readonly

A collection of text boxes.

textFrames

TextFrames TextFrame

readonly

A collection of text frames.

wmfs

WMFs WMF

readonly

A collection of WMF graphics.

Method Listing

undefined abortPlaceGun ()

Delete the contents of the place gun.

EventListener addEventListener (eventType:String, handler:Varies File JavaScriptFunction, [captures:Boolean=Boolean])

Adds an event listener.

Parameter

Type

Description

eventType

String

The event type.

handler

File

JavaScriptFunction

The event handler. Can accept: File or JavaScript Function.

captures

Boolean

This parameter is obsolete. (Optional)

(default: false)

PlaceGun getElements ()

Resolves the object specifier, creating an array of object references.

undefined loadPlaceGun (fileName:Array of Varies File Files., [showingOptions:Boolean=Boolean], withProperties:Object)

Load the place gun with one or more files.

Parameter

Type

Description

fileName

File

Array of Files.

One or more files to place. Can accept: File or Array of Files.

showingOptions

Boolean

Whether to display the import options dialog (Optional)

(default: false)

withProperties

Object

Initial values for properties of the placed object(s) (Optional)

Boolean removeEventListener (eventType:String, handler:Varies File JavaScriptFunction, [captures:Boolean=Boolean])

Removes the event listener.

Parameter

Type

Description

eventType

String

The registered event type.

handler

File

JavaScriptFunction

The registered event handler. Can accept: File or JavaScript Function.

captures

Boolean

This parameter is obsolete. (Optional)

(default: false)

undefined rotate ([direction:RotationDirection=RotationDirection])

Rotate the contents of the place gun.

Parameter

Type

Description

direction

RotationDirection

RotationDirection.BACKWARD

RotationDirection.FORWARD

Which direction to rotate the contents (Optional)

(default: RotationDirection.FORWARD)

String toSource ()

Generates a string which, if executed, will return the PlaceGun.

String toSpecifier ()

Retrieves the object specifier.

Object of

Button.parent

CheckBox.parent

ComboBox.parent

EPS.parent

EPSText.parent

Event.parent

EventListener.parent

FormField.parent

Graphic.parent

GraphicLine.parent

Group.parent

Image.parent

ImportedPage.parent

ListBox.parent

MultiStateObject.parent

MutationEvent.parent

Oval.parent

PDF.parent

PICT.parent

PageItem.parent

Polygon.parent

RadioButton.parent

Rectangle.parent

SVG.parent

SignatureField.parent

Snippet.parent

SplineItem.parent

TextBox.parent

TextFrame.parent

WMF.parent

Document.placeGuns

Return

PlaceGun.getElements()