If this guide is distributed with software that includes an end-user agreement, this guide, as well as the software described in it, is furnished under license and
may be used or copied only in accordance with the terms of such license. Except as permitted by any such license, no part of this guide may be reproduced, stored
in a retrieval system, or transmitted, in any form or by any means, electronic, mechanical, recording, or otherwise, without the prior written permission of Adobe
Systems Incorporated. Please note that the content in this guide is protected under copyright law even if it is not distributed with software that includes an enduser license agreement.
The content of this guide is furnished for informational use only, is subject to change without notice, and should not be construed as a commitment by Adobe
Systems Incorporated. Adobe Systems Incorporated assumes no responsibility or liability for any errors or inaccuracies that may appear in the informational
content contained in this guide.
Please remember that existing artwork or images that you may want to include in your project may be protected under copyright law. The unauthorized
incorporation of such material into your new work could be a violation of the rights of the copyright owner. Please be sure to obtain any permission required
from the copyright owner.
Any references to company names in sample templates are for demonstration purposes only and are not intended to refer to any actual organization.
This work is licensed under the Creative Commons Attribution Non-Commercial 3.0 License. To view a copy of this license, visit
http://creativecommons.org/licenses/by-nc/3.0/us/
Adobe, the Adobe logo, Adobe AIR, Adobe Captivate, Adobe Type Manager, Acrobat, Distiller, Flash, FrameMaker, Illustrator, PageMaker, Photoshop,
PostScript, Reader, RoboHelp, and RoboScreenCapture are trademarks of Adobe Systems Incorporated in the United States and/or other countries.
Microsoft, Windows, and Windows Vista are either registered trademarks or trademarks of Microsoft Corporation in the United States and/or other countries.
SVG is a trademark of the World Wide Web Consortium; marks of the W3C are registered and held by its host institutions MIT, INRIA, and Keio. Helvetica is
a registered trademark of is a trademark of Heidelberger Druckmaschinen AG exclusively licensed through Linotype Library GmbH, and may be registered in
certain jurisdictions. ITC Zapf Dingbats is a trademark of International Typeface Corporation. Times New Roman is a registered trademark of The Monotype
Corporation registered in the U.S. Patent and Trademark Office and may be registered in certain other jurisdictions. All other trademarks are the property of
their respective owners.
This product contains either BSAFE and/or TIPEM software by RSA Data Security, Inc.
This product contains color data and/or the Licensed Trademark of The Focoltone Colour System.
PANTONE® Colors displayed in the software application or in the user documentation may not match PANTONE-identified standards. Consult current
PANTONE Color Publications for accurate color. PANTONE
Inc. is the copyright owner of color data and/or software which are licensed to Adobe Systems Incorporated to distribute for use only in combination with Adobe
FrameMaker. PANTONE Color Data and/or Software shall not be copied onto another disk or into memory unless as part of the execution of Adobe
FrameMaker software.
Portions of Adobe Acrobat include technology used under license from Autonomy, and are copyrighted.
Adobe Systems Incorporated, 345 Park Avenue, San Jose, California 95110, USA.
Notice to U.S. government end users. The software and documentation are “Commercial Items,” as that term is defined at 48 C.F.R. §2.101, consisting of
“Commercial Computer Software” and “Commercial Computer Software Documentation,” as such terms are used in 48 C.F.R. §12.212 or 48 C.F.R. §227.7202,
as applicable. Consistent with 48 C.F.R. §12.212 or 48 C.F.R. §§227.7202-1 through 227.7202-4, as applicable, the Commercial Computer Software and
Commercial Computer Software Documentation are being licensed to U.S. Government end users (a) only as Commercial items and (b) with only those rights
as are granted to all other end users pursuant to the terms and conditions herein. Unpublished-rights reserved under the copyright laws of the United States. For
U.S. Government End Users, Adobe agrees to comply with all applicable equal opportunity laws including, if appropriate, the provisions of Executive Order
11246, as amended, Section 402 of the Vietnam Era Veterans Readjustment Assistance Act of 1974 (38 USC 4212), and Section 503 of the Rehabilitation Act of
1973, as amended, and the regulations at 41 CFR Parts 60-1 through 60-60, 60-250, and 60-741. The affirmative action clause and regulations contained in the
preceding sentence shall be incorporated by reference.
A script is a series of commands that instructs Adobe® FrameMaker® to perform a set of specified actions. Scripts
automate repetitive tasks, such as counting the images in a book or adding an indent to all the para tags in a file. Use
scripts as a creative tool to streamline time-consuming tasks.
If you are new to scripting, you can acquaint yourself with the basic scripting concepts provided in the Introduction
to Scripting manual.
About this document
Naming conventions
To help you identify the structures, constants, and functions defined by the ESTK, this document adheres to the
following naming conventions:
Notice the use of different fonts to represent different types of information:
• What you type is shown in text like this.
• Function names, property names, structure names, returned values, constants, filter names, program names, paths,
and filenames are also shown in
text like this.
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Overview
Scripting support in FrameMaker
FrameMaker supports ExtendScript, which is an extended implementation of JavaScript. While JavaScript files have
.js extension, ExtendScript files have .jsx extension.
For more information on JavaScript modules, tools, utilities, and features that are available to all JavaScript-enabled
Adobe applications, see
Development and debugging tools in ExtendScript toolkit
For assistance in developing, debugging, and testing scripts, Adobe provides the ExtendScript Toolkit. ExtendScript
Toolkit is an interactive development and testing environment for ExtendScript, which is installed with FrameMaker
and all JavaScript-enabled applications. For details, see Chapter 2, “The ExtendScript Toolkit” and Chapter 8,
“ExtendScript Tools and Features ” in
ExtendScript capabilities
Using ExtendScript Toolkit, you can develop and debug ExtendScript. ExtendScript provides the following features
that make scripting easy:
• User interface development tools: The ScriptUI module defines Window objects that represent platform-specific
windows and various control elements, such as buttons and static text. Resource specification allows you to create
user-interface elements. Using the event-handling callback functions, you can define the behavior of your userinteraction controls. ScriptUI provides a rich set of containers (such as Group, Panel, and TabbedPanel) and user
interface controls (such as Button, Image, Scrollbar, Treeview, and FlashPlayer). ScriptUI works with the
ExtendScript JavaScript interpreter to provide JavaScript programs with the ability to create and interact with user
interface elements. The Graphic customization objects provide the ability to customize the appearance of userinterface controls before they are drawn. For details, see Chapter 4, “User-Interface Tools” in
Guide.
• Extensions:
• ExtendScript offers tools for communicating with other computers or the Internet using standard protocols.
The Socket object supports low-level TCP connections. For details, see Chapter 6, “External Communication
Tools” in
• Adobe ExtendScript defines classes that simplify cross-platform file-system access. These classes are available to
all applications that support a JavaScript interface. For details, see Chapter 3, “File System Access” in
Tools Guide.
• You can extend the JavaScript DOM for an application. To extend the JavaScript DOM, write a C or C++ shared
library, compile it for the relevant platform, and load it into JavaScript as an ExternalObject instance. A shared
library is implemented by a DLL in Windows, a bundle or framework in Mac OS, or a SharedObject in UNIX.
For details, see Chapter 7, “Integrating External Libraries” in
• Inter-application communication and messaging: ExtendScript provides a common scripting environment for
all Adobe JavaScript-enabled applications. The cross-DOM API allows implementation of functions, such as open
files and execute scripts, that are common across message-enabled applications. Using simple syntax you can
implement application-specific functionality for message-enabled application. The BridgeTalk class of the
messaging API has globally available static properties and functions that provide access to environmental
information relevant for communication between applications. The error codes defined by the interapplication
messaging protocol are compatible with the ExtendScript error codes. For details, see Chapter 5, “Interapplication
Communication with Scripts” in
JavaScript Tools Guide.
JavaScript Tools Guide.
JavaScript Tools Guide.
JavaScript Tools
JavaScript
JavaScript Tools Guide.
JavaScript Tools Guide
2
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Overview
Creating Scripts
Adobe provides ExtendScript Toolkit (ESTK) with its applications as a scripting utility. ESTK has many features that
make it easier to use than a text editor. ESTK has a built-in syntax checker that identifies where the problems are in
your script and tries to explain how to fix them. You can run your scripts right from the ESTK without saving the file.
Running scripts without saving them first saves you time, especially when you are learning to work with ESTK.
Accessing ESTK
Connect ESTK to FrameMaker
When you launch ExtendScript Toolkit from FrameMaker (File > Script ...), ExtendScript Toolkit is already connected
to FrameMaker. Only when you launch ExtendScript Toolkit from Windows (Start > Programs...), complete the
following steps to connect ESTK to FrameMaker.
1 In the ExtendScript Toolkit, select Adobe FrameMaker <Version#> in the pop-up menu.
2 Click .
If FrameMaker is not already running, a message appears: “Target Adobe FrameMaker <Version#> is not running. Do
you want to launch Adobe FrameMaker <Version#>?”
3
3 Click Yes.
FrameMaker is launched and connected to ESTK.
To write, edit, and run scripts
In FrameMaker, do the following:
1 Click File > Script > New Script.
The ESTK editor opens.
2 Write the script in the editor.
3 To run the script, click the Play button.
You can also start ExtendScript Toolkit from Windows (Start > Programs). When you start ExtendScript Toolkit from
Windows, connect ESTK to FrameMaker.
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Overview
Using script library
In FrameMaker, select File > Script > Catalog to display the script library.
4
Using the script catalog, you can manage your existing scripts:
• Favorites: Scripts you tag as your favorite appear here.
• Autorun: These scripts run when FrameMaker is launched.
• Registered: Scripts that run on certain triggers, such as on opening a file or saving a file.
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Overview
Using object model viewer
Object Model Viewer in ESTK helps you to get the information on different classes and the methods in ExtendScript.
Press F1 or click Help > Object Model Viewer to open Object Model Viewer.
5
In the Object Model Viewer, select an object model under Browse to you can do the following to locate information:
• Under Browser, select the object model for which you want the information. Object Model Viewer displays the
classes in the object model and details such as type, properties, method, and description of the class.
• Search for a class, method, or property.
• Bookmark a class, method, or property. It then appears under the Bookmarks section.
ExtendScript use cases
Some of the ExtendScript use cases can be:
• Scripts to automate repetitive tasks: You can write utilities to automate repetitive tasks, such as change alignment
of all the tables in a FrameMaker document.
• Notification-based scripts: You can write scripts that are triggered on FrameMaker events such as such as opening,
printing, or saving a document.
• Menu command scripts/scripts to extend FrameMaker functionality: Using these scripts, you can add menus
and commands in FrameMaker.
• Startup scripts: These scripts get executed when FrameMaker starts. You can set up scripts to run at startup by
copying them at the following location: <FMINSTALL_DIR>\startup. Alternatively, you can use the Script Library
dialog to register Autorun scripts.
Last updated 6/4/2015
Chapter 2: What’s new in ESTK 2015
release
Setting direction properties
ESTK now provides the following direction (right-to-left and left-to-right) properties:
DirectionSet or get the direction of the objects given in the following table. Possible values:
• Constants.FV_DIR_Inherit - Inherit the direction of the parent
• Constants.FV_DIR_LTR - Left-to-right
• Constants.FV_DIR_RTL - Right-to-left
ResolvedDirectionGet the inherited direction of the objects given in the following table. Possible values:
• Constants.FV_DIR_LTR - Left-to-right
6
• Constants.FV_DIR_RTL - Right-to-left
AsianComposerWhether the object will use the Asian Composer layout engine.
These direction properties can be applied to the following objects:
The new NewInlineComponentOfType method of the Doc object allows you to add inline components to a document.
Note: Currently only the mini-TOC inline component can exist in a document.
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
What’s new in ESTK 2015 release
Applying conditional text at the book level
Use the new set of APIs to apply conditional text at the book level
1 GetConditionalSettings: Get a PropVals object containing the conditional settings of the current book.
2 ApplyConditionalSettings: Apply conditional settings in the selected book based on the specified settings.
3 ManageConditionalExpressions: Add, edit, or delete conditional expression tags to the current book.
4 GetConditionalExpression: Returns the conditional expression definition for the given named expression.
7
Last updated 6/4/2015
Chapter 3: Sample ESTK scripts
ExtendScript is similar to JavaScript. You can easily develop ExtendScript for any of the applications in FrameMaker
if you are familiar with JavaScript.
Following are examples for scripts that automate specific activities in FrameMaker.
Note: Sample scripts shipped with FrameMaker are at the following location: <FMINSTALL_DIR>\samples
Adding text to a document and enabling change bars
The following script adds a sample text to a FrameMaker document and then enables the change bar. Open a
FrameMaker document before running the script.
Copy and paste the script to ESTK and select FrameMaker <Version#> as the target application. Click the Play button
to run the script.
var doc = app.ActiveDoc;
var firstPgf = doc.MainFlowInDoc.FirstTextFrameInFlow.FirstPgf;
var tl = new TextLoc(firstPgf, 0);
doc.AddText (tl, "Hello");
doc.AutoChangeBars = 1;
8
The script creates a text location using the new TextLoc()method. Assign the first page of the document as the text
location. Using the
AddText() method, add a sample text. Set the AutoChangeBars property to 1 to enable the change bar.
Changing the table properties in a document
The following script changes the left indentation of all the tables in a FrameMaker body page by 1 inch. It also changes
the width of the columns to 2 inches. Open a FrameMaker document that has tables with two columns before running
the script.
var doc = app.ActiveDoc;
var flow = doc.MainFlowInDoc;
var tbl = 0;
var textItems = flow.GetText(Constants.FTI_TblAnchor);
for (var i = 0; i < textItems.len; i += 1)
{
tbl = textItems[i].obj;
The script creates the document’s main flow using the MainFlowInDoc method. Use the GetText(FTI_TblAnchor)
method to list all tables in the main flow. Using a for loop, for each table, use the
the left indentation.
TblLeftIndent()method to change
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Sample ESTK scripts
Use the TblColWidths() method to change the width of the column. This method accepts the argument in a metric
form. So, create the arguments as a metric object using the
new Metrics()method.
Note: By convention, there are 72 points per inch. Multiply the inch value with 65536 to get the correct value. 1 inch is
equal to 1 * 72 * 65536 points.
9
Last updated 6/4/2015
Chapter 4: Differences between scripts and
FDK
If you are familiar with the FDK (FrameMaker Developer Kit) object model, this chapter will help you get quickly get
familiarized with ESTK. Adobe FrameMaker scripts are modeled closely on the FrameMaker FDK. These scripts act
as wrappers to the FDK and hide the complexity of using FDK functions from users.
This chapter documents the differences between using scripts and using FDK.
Naming differences between scripts and FDK
FDKScripts
Every FDK object is identified by an object ID. Every script entity is identified as an object.
10
Every property in FDK starts with FP_.
For example, FP_CharTag.
Properties are used directly, in scripts. Remove the FP_ prefix before using the
properties in scripts.
For example, FP_CharTag in FDK becomes just CharTag in scripts.
Every property has its own data type. The properties can either be read-only or readwrite.
Note: All FDK properties can be used in FrameMaker scripts.
Every API in FDK starts with F_APImethodname.Methods are used directly in scripts. Remove the F_API prefix before using the methods
Every object in FDK starts with FO_.
For example, FO_Doc.
in scripts.
For example, F_ApiSplitElement becomes just SplitElement in scripts.
Use objects directly in scripts. Remove the FO_ prefix before using the objects in scripts.
For example, FO_Doc in FDK becomes just Doc in scripts.
Note: FDK object FO_Session is mapped to app and not to Session. This
app script object is readily available for all FrameMaker scripts to use.
Every structure in FDK starts with F_ and ends with a
T.
For example, F_AttributeT.
FDK uses data types such as StrngT for strings and
IntT, UintT for numbers.
Structures are used directly in scripts. Remove the F_ prefix and the ending ‘T’ before
using the structures in scripts.
For example, F_AttributeT in FDK becomes just Attribute in scripts.
Some FDK structures contain other FDK structures within themselves. In a script, the
structures within a structure are treated as an object data type.
See the F_TextRangeT structure in Example 3 below.
Scripts map the FDK data types as follows:
StringT is mapped to Javascript String.
IntT and UinT are mapped to Javascript Number.
ObjHandleT is mapped to Javascript Object.
The following examples clearly highlight the differences between scripts and the FDK.
Example 1:
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Differences between scripts and FDK
The app property is readily available to all FrameMaker scripts and maps to the FO_Session object in FDK.
In this example, you query the ActiveDoc property that returns the Active Document Object(Doc) in the current
FrameMaker Session. The reference to this object is stored in the variable
As discussed in the table above, Example 1 demonstrates how FDK properties [FP_ActiveDoc, FP_MainFlowInDoc
FP_FlowIsSynchronized] are mapped to script properties [ActiveDoc, MainFlowInDoc and
and
FlowIsSynchronized].
Example 2:
Example 2 builds on Example 1 and shows how methods are called in scripts.
Every object has some methods of its own. These methods can be invoked in the same way as properties are invoked.
In Example 1, you created the doc object. To invoke a method, use doc.methodname(). For example,
doc.UpdateVariables();
This code calls the UpdateVariables method of the doc object.
FDK users can relate these methods to FDK APIs. The same code in FDK becomes:
F_ApiUpdateVariables(FV_SessionId, docId);
Notice how the FDK API F_ApiUpdateVariables becomes the method name UpdateVariables in scripts, as
mentioned in the table above.
Global Methods:
Not every method is accessible through a specific object. There are some methods that are not called through any
objects but are called directly. These methods are called Global Methods. Examples of Global Methods include
ChooseFile(), CallClent() and Sleep().
In addition to these methods, all FDK Variables and Macros are available as Global Methods. These Variables usually
start with
Every FDK Structure such as F_TextItemT, and F_TextLocT are also mapped to objects in scripts. All the fields of
these structures are mapped to the read or write properties of these objects.
Lines 6, 7, 8 can be combined and written by passing parameters in the constructor of the TextLoc object as:
textLoc = new TextLoc(pgf, 0);
Scripts have advanced features such as notifications and commands.
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Differences between scripts and FDK
Notifications
Notifications is the internal mechanism through which a script registered for a particular event is run when the event
is triggered.
As an example, consider the following script:
/*
Sample script to demonstrate how to use notification mechanism of FrameMaker though
ExtendScript
*/
/*
There are basically two parts to a notification script.
1. Registering for a desired notification. (This is done by calling 'Notification()' with
desired notifications as argument.)
2. Implement a handler for these notifications in your script. ( Implement 'Notify()' in
script)
*/
/*
Part 1. Registering for Notifications
Notification()' is a global function and is available readily in scripting. (Similar to
F_ApiNotification())
The Syntax for Notification() is: Notification(int, int,.....,int, bool);
it takes:
a.) list of notifications(FA_Note_PreOpenDoc, FA_Note_PostOpenDoc etc.) and
b.) param bool: true = register for provided notification list, false = unregister for provided
notification list.
(This parameter is optional and by default 'true')
Note: for more details please see F_ApiNotification() in FDK reference guide.
*/
/*
Notification(FA_Note_PreOpenDoc,true);
This is same as Notification(FA_Note_PreSaveDoc)
or you can register for more than one notification at once
Notification(FA_Note_PostOpenDoc,FA_Note_PreSaveDoc);
Here we register for the notification: FA_Note_PostOpenDoc - this notification is
triggered just after a document is opened.
Notification(FA_Note_PostOpenDoc,true);
*/
/*
Part 2: handler
This can be done by implementing function 'Notify()' that are called by FrameMaker when any
13
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Differences between scripts and FDK
desired even occurs.(Similar to F_ApiNotify())
Syntax for this callback function is:
@params
note: notification id to identify the event.
object: current document or book object which generated the event.
sparam: The string, if any, associated with the notification
(For example, if the notification is for an Open or Save operation, sparm specifies the
pathname of the affected file. If the notification is for text entry, sparm specifies the text the
user typed.)
iparam: The Integer, if any, associated with the notification. Probably the fcode or bit flags.
Notify(note, doc, sparam, iparam)
Note: for more details please see F_ApiNotify() in FDK reference guide.
*/
function Notify(note, object, sparam, iparam)
{
switch (note) {
case FA_Note_PostOpenDoc:
alert("Opened document " + sparam);
break;
}
14
The line of code:
Notification(FA_Note_PostOpenDoc,true);
registers this script for the FA_Note_PostOpenDoc notification. This notification is triggered just after any document
is opened in FrameMaker.
The lines of code:
function Notify(note, object, sparam, iparam)
{
switch (note) {
case FA_Note_PostOpenDoc:
alert("Opened document " + sparam);
break;
}
pops up an alert with the file name just after the file is opened.
Menus and Commands
Scripting allows you to add custom menus and associate commands with these menus. In addition, you can implement
your own handlers for commands in a similar way as the FDK.
The following script adds two menus and associated commands to the FrameMaker main menu.
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Differences between scripts and FDK
/*
In this script, we add two menu items to FrameMaker Session and associate two different
commands to these menu items
*/
// Main menu bar
/* First we get the object associated with Main menubar in FrameMaker*/
mMenu = app.GetNamedMenu("!MakerMainMenu") ;
// F_ApiGetNamedMenu(FV_SessionId, FO_Menu, (ConStringT)"!MakerMainMenu")
/*
Defining new menu items
DefineAndAddMenu(name, label)
FDK equivalent : F_ApiDefineAndAddMenu(F_ObjHandleT toMenuId, StringT name, StringT label)
*/
nMenu1 = mMenu.DefineAndAddMenu("Menu1", "Menu1");
nMenu2 = mMenu.DefineAndAddMenu("Menu2", "Menu2");
// Adding command to menus
/*
DefineAndAddCommand(cmdID, name, label, shortcut)
FDK equivalent: F_ApiDefineAndAddCommand(IntT cmdID, F_ObjHandleT toMenuId, StringT name,
StringT label, StringT shortcut)
cmdID is a integer that will be passed to Command() function defined in your script. It should
be unique to the script.
*/
nMenu1.DefineAndAddCommand(1,"cmd1","command1","");
nMenu2.DefineAndAddCommand(2,"cmd2","command2","");
// Another way for creating a command and adding it to menu items.
//cmd3 = DefineCommand(3, "cmd3", "cmd3", "");
// FDK equivalent : F_ApiDefineCommand(IntT cmdID, StringT name, StringT label, StringT shortcut)
// add the command to different menu items
//nMenu1.AddCommandToMenu(cmd3);
// FDK equivalent : ApiAddCommandToMenu(F_ObjHandleT toMenuId, F_ObjHandleT commandId)
//nMenu2.AddCommandToMenu(cmd3);
// must call if script has been run through ESTK, redundant otherwise.
UpdateMenus();
// Call back equivalent to F_ApiCommand(command)
function Command(cmd){
switch(cmd) {
case 1:
alert("Command1 executed");
break;
case 2:
alert("Command2 executed");
break;
}
}
15
Let us examine the script in detail:
1 The line: mMenu = app.GetNamedMenu("!MakerMainMenu") ; fetches the name of the FrameMaker main menu
The first value within the parenthesis is the menuID. This value is passed to the case statement.
The system pops up the relevant alert when the corresponding menu entry is clicked.
16
Last updated 6/4/2015
Chapter 5: Object Reference
AFrame
Property nameData TypeDescription
AFrameIsCroppedboolIndicates whether the anchored frame is cropped or not.
Possible values are:
0 - (Default) Indicates the frame is not cropped.
1 - Indicates the frame is cropped.
17
AFrameIsFloatingboolIndicates whether the anchored frame is set to be
AlignmentnumberIndicates how the anchored frame is aligned.
floatable or not.
Possible values are:
0 - (Default) Indicates the frame is not floatable.
1 - Indicates the frame is floatable.
Possible values are:
• Constants.FV_ALIGN_LEFT (0)
• Constants.FV_ALIGN_CENTER (1)
• Constants.FV_ALIGN_RIGHT (2)
• Constants.FV_ALIGN_INSIDE (3)
• Constants.FV_ALIGN_OUTSIDE (4)
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Object Reference
Property nameData TypeDescription
AnchorTypenumberIndicates the location where the frame is anchored.
Possible values are:
• Constants.FV_ANCHOR_INLINE (1)
• Constants.FV_ANCHOR_TOP (2)
• Constants.FV_ANCHOR_BELOW (3)
• Constants.FV_ANCHOR_BOTTOM (4)
• Constants.FV_ANCHOR_SUBCOL_LEFT (5)
• Constants.FV_ANCHOR_SUBCOL_RIGHT (6)
• Constants.FV_ANCHOR_SUBCOL_NEAREST (7)
• Constants.FV_ANCHOR_SUBCOL_FARTHEST (8)
• Constants.FV_ANCHOR_SUBCOL_INSIDE (9)
• Constants.FV_ANCHOR_SUBCOL_OUTSIDE (10)
• Constants.FV_ANCHOR_TEXTFRAME_LEFT (11)
18
• Constants.FV_ANCHOR_TEXTFRAME_RIGHT (12)
• Constants.FV_ANCHOR_TEXTFRAME_NEAREST (13)
• Constants.FV_ANCHOR_TEXTFRAME_FARTHEST (14)
• Constants.FV_ANCHOR_TEXTFRAME_INSIDE (15)
• Constants.FV_ANCHOR_TEXTFRAME_OUTSIDE (16)
• Constants.FV_ANCHOR_RUN_INTO_PARAGRAPH (17)
BaselineOffsetnumberBaseline Offset
ElementElementIf the anchored frame is in a structured flow in a
InTextFrameTextFrameIndicates the text frame in which the anchored frame is
InTextObjFMObjectIndicates the column or text frame in which the anchored
NextAFrameAFrameContains the next anchored frame in the text frame.
PrevAFrameAFrameContains the previous anchored frame in the text frame.
SideOffsetnumberDenotes the near side offset.
TextLocTextLocContains the location of the anchor symbol.
FirstGraphicInFrameFMObjectContains the first object in the anchored frame.
FrameMaker document, Element indicates the element
containing the anchored frame.
placed.
frame is placed.
LastGraphicInFrameFMObjectContains the last object in the anchored frame.
AnglenumberIndicates the angle of rotation of the graphic object.
ArrowBaseAnglenumberDenotes the arrowhead base angle in degrees.
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Object Reference
Property nameData TypeDescription
19
ArrowLengthnumberDenotes the arrowhead length (always rounded down to
ArrowScaleFactornumberIndicates the factor by which the arrowhead is scaled as
ArrowScaleHeadnumberSet to 1 if arrowhead is scaled as the line width changes.
ArrowTipAnglenumberDenotes the arrowhead tip angle in degrees.
ArrowTypenumberDenotes the style of the arrowhead. Possible values are:
the nearest 1/256 point).
line width changes (always rounded down to nearest
1/16 point). It is not used if the ArrowScaleHead property
False.
is
0, otherwise.
Set to
• Constants.FV_ARROW_STICK (0x1)
• Constants.FV_ARROW_HOLLOW (0x2)
• Constants.FV_ARROW_FILLED (0x3)
BorderWidthnumberIndicates the border width specified in points. The
ColorColorDenotes the spot color.
DashMetricsSpecifies a dash pattern that is repeated for the length of
permissible range is 0.015 pt to 360 points.
an object's border. The pattern is stored in a MetricsT
structure. The 0th element of the MetricsT.MetricsT_val
array stores the length of the first dash; the 1st element
stores the following space; the 2nd element stores the
next dash; and so on for an even number of elements.
FillnumberDenotes the fill pattern (numbers between 0 and 15).
Constants are provided for fill patterns 0, 7 and 15, as
follows:
• Constants.FV_FILL_BLACK (0)
• Constants.FV_FILL_WHITE (7)
• Constants.FV_FILL_CLEAR (15)
FrameParentFMObjectDenotes the frame containing the graphic object.
GraphicCantBeSelectednumberSet to 1 if the graphic object cannot be selected. Set to 0,
GraphicIsSelectednumberSet to 1, if the graphic object is selected. Else, set to 0.
GroupParentGroupSpecifies the group to which the object belongs.
HeadArrownumberSet to 1 if the line has an arrow head. Set to 0, otherwise.
HeightnumberDenotes the height of the object denoted in points. The
HotspotCmdStrStringTThe command string for a hotspot. Thismust be a valid
HotspotTitleStringTThe tooltip text for the hotspot in the outputs that
otherwise.
Note: Anchored frames do NOT have this property.
permissible range is from 0.125 points to 3600 points.
hypertext command string.
support it (for example HTML). This property is 0ptional.
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Object Reference
Property nameData TypeDescription
20
IsHotspotBoolWhether the object is a hotspot or not. If this property is
LineCapnumberSpecifies the type of the end of the line. The possible
turned off, the object is no longer a hotspot even if
command string is non-empty.
values are:
• Constants.FV_CAP_BUTT (0x00)
• Constants.FV_CAP_ROUND (0x01)
• Constants.FV_CAP_SQUARE (0x02)
LocXnumberSpecifies the distance of the object from the left side of
LocYnumberDistance of the object from the top of the parent frame (in
NextGraphicInDocFMObjectDenotes the next graphic object in the document.
NextGraphicInFrameFMObjectDenotes the next graphic object in the frame.
the parent frame (in inches). The permissible range is –
216 inches to 216 inches.
If the graphic object is an anchored frame, the distance is
automatically calculated from the left side of the page
frame. You cannot set this value manually for anchored
frames.
inches) The permissible range is –216 inches to 216
inches.
If the graphic object is an anchored frame, the distance is
automatically calculated from the top of the page frame.
You cannot set this value manually for anchored frames.
NextGraphicInGroupFMObjectDenotes the next graphic object in the group.
NextSelectedGraphicInDocFMObjectDenotes the next selected graphic object in the
ObjectAttributesStringsA list of strings. Each string expresses an attribute that is
OverprintnumberSpecifies the overprint settings for the object. The
document.
specified for an anchored frame in the Object Properties
> Object Attributes dialog box. Each string is in the form
of string_text.You can use the backslash to escape
characters such as \n, \r, or \t for newline, carriage return,
and tab, respectively. For a backslash character in the
string text, type \\.
possible values are:
• Constants.FV_KNOCKOUT (0x00)
• Constants.FV_OVERPRINT (0x01)
• Constants.FV_FROMCOLOR (0x02)
PennumberSpecifies the pen pattern (numbers between 0 and 7).
Constants are provided for pen patterns 0, 7 and 15, as
follows:
• Constants.FV_FILL_BLACK (0)
• Constants. FV_FILL_WHITE (7)
• Constants.FV_FILL_CLEAR (15)
Last updated 6/4/2015
ADOBE FRAMEMAKER SCRIPTING GUIDE
Object Reference
Property nameData TypeDescription
PrevGraphicInFrameFMObjectDenotes the previous graphic object in the frame.
PrevGraphicInGroupFMObjectDenotes the previous graphic object in the group.
21
RunaroundnumberSpecifies whether text can flow around the object and, if
so, whether the text follows the contour of the object or a
box shape surrounding the object. The possible values
are:
• Constants.FV_TR_NONE (0x01)
• Constants.FV_TR_CONTOUR (0x02)
• Constants.FV_TR_BBOX (0x03)
RunaroundGapnumberDenotes the width of the runaround gap, if the object is a
TailArrownumberSet to 1 if the arrowhead is enabled at the begining of the
TintPercentnumberSpecifies the tint percentage.
UniquenumberIndicates the graphic object's internal unique number.
WidthnumberDenotes the width of the object. The permissible range is
FirstGraphicInFrameFMObjectContains the first object in the anchored frame.
LastGraphicInFrameFMObjectContains the last object in the anchored frame.
runaround object.
line; Set to
from 0.125 points to 3600 points.
0 otherwise.
AFrame methods
Delete, GetProps, SetProps, ObjectValid.
Arc
Property nameData TypeDescription
DThetanumberDenotes the arc angle length in degrees. The permissible
ThetanumberSpecifies the start angle in degrees. The permissible
AnglenumberSpecifies the angle of the object's rotation.
ArrowBaseAnglenumberIndicates the arrowhead base angle in degrees.
ArrowLengthnumberDenotes the arrowhead length (always rounded down to
ArrowScaleHeadnumberSet to 1 if the arrowhead is scaled as the line width
ArrowScaleFactornumberSpecifies the factor by which arrowhead is scaled as line
Last updated 6/4/2015
range is –360 degrees to +360 degrees.
range is 0 degrees to 360 degrees.
the nearest 1/256 point).
changes. Set to
width changes (always rounded down to nearest 1/16
point). It is not used if the ArrowScaleHead property is set
False.
to
0, otherwise.
Loading...
+ 755 hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.