viewer
Viewer object
Section titled “Viewer object”app.activeViewer
Description
Section titled “Description”The Viewer object represents a Composition, Layer, or Footage panel.
Example
Section titled “Example”This maximizes the active viewer panel, and displays its type if it contains a composition.
var activeViewer = app.activeViewer;activeViewer.maximized = true;if (activeViewer.type === ViewerType.VIEWER_COMPOSITION) { alert("Composition panel is active.");}
Attributes
Section titled “Attributes”Viewer.active
Section titled “Viewer.active”viewer.active
Description
Section titled “Description”When true
, indicates if the viewer panel is focused, and thereby frontmost.
Boolean; read-only.
Viewer.activeViewIndex
Section titled “Viewer.activeViewIndex”viewer.activeViewIndex
Description
Section titled “Description”The index of the current active View object, in the Viewer.views array.
Integer; read/write.
Viewer.maximized
Section titled “Viewer.maximized”viewer.maximized
Description
Section titled “Description”When true
, indicates if the viewer panel is at its maximized size.
Boolean; read/write.
Viewer.views
Section titled “Viewer.views”viewer.views
Description
Section titled “Description”All of the Views associated with this viewer.
Array of View object objects; read-only.
Viewer.type
Section titled “Viewer.type”viewer.type
Description
Section titled “Description”The content in the viewer panel.
A ViewerType
enumerated value; read-only. One of:
ViewerType.VIEWER_COMPOSITION
ViewerType.VIEWER_LAYER
ViewerType.VIEWER_FOOTAGE
Methods
Section titled “Methods”Viewer.setActive()
Section titled “Viewer.setActive()”viewer.setActive()
Description
Section titled “Description”Moves the viewer panel to the front and places focus on it, making it active.
Calling this method will set the viewer’s active attribute to true
.
Parameters
Section titled “Parameters”None.
Returns
Section titled “Returns”Boolean indicating if the viewer panel was made active.