Using Fireworks Api Functions - Adobe 65011817 - Fireworks CS4 - Mac Extended User Manual

Extending guide
Hide thumbs Also See for 65011817 - Fireworks CS4 - Mac:
Table of Contents

Advertisement

Last updated 12/8/2009
Matrix data type
The format for a matrix is
This guide assumes that you know how to use these nine values to construct a three-by-three transformation matrix;
discussion of the construction of transformation matrices is beyond the scope of this manual.
Point data type
The format for a point is
{
the following example:
fw.getDocumentDOM().addNewLine({x:64.5, y:279.5}, {x:393.5, y:421.5});
Rectangle data type
The format for a rectangle is
boundingRectangle
dom.addNewOval(
fw.getDocumentDOM().addNewOval({left:72, top:79, right:236, bottom:228});
Resolution data type
The format for resolution is
For instance,
dom.setDocumentResolution
fw.getDocumentDOM().setDocumentResolution({pixelsPerUnit:72, units:"inch"});

Using Fireworks API functions

Three categories of API functions are described in this book: Document functions, History panel functions, and
Fireworks functions. The following rules apply to all functions.
Zero-based indexes
Some functions take an index argument which is a zero-based, one-dimensional array. That means a value of
represents the first item in the array,
deletes the second layer of the active Fireworks document:
fw.getDocumentDOM().deleteLayer(2);
Functions that take a frameIndex argument can be passed –
take a layerIndex argument may be passed –
Passing null values
In general, passing a
null
argument; such cases are noted in the function descriptions.
Working with selected elements
Many API functions in this chapter refer to a "selection" or to "selected items." These terms refer to Fireworks
elements, such as text boxes or images, that are currently selected. In most cases, the functions work even if only one
item is selected. If a function requires more than one selected item, this is noted in the description of the function.
matrix:
{
[float, float, float, float, float, float, float, float, float]}
x:
, y:
. For instance,
float
float}
left:
top:
{
float,
float,
could look like the following example:
)
pixelsPerUnit:
{
float,
(resolution) could look like the following example:
represents the second item, and so on. For example, the following command
1
to indicate the current layer.
1
value to a function causes an exception to be thrown. A few functions do allow
dom.addNewLine(
right:
bottom:
float,
float}
units:
. Acceptable values for units are "
string}
to indicate the current frame. Similarly, functions that
1
EXTENDING FIREWORKS
The Fireworks Object Model
startPoint, endPoint
could look like
)
. For instance,
inch
8
.
" or "
".
cm
0
as an
null

Advertisement

Table of Contents
loading

This manual is also suitable for:

Fireworks cs4

Table of Contents