For example, if the first open document is the current document, the first code fragment has
the same effect as the second and third code fragments. The
references the current document (for more information, see
document" on page
10).
fw.getDocumentDOM().setDocumentResolution({pixelsPerUnit:72, units:"inch"})
;
fw.documents[0].resolution =72;
fw.documents[0].resolutionUnits ="inch";
Formatting nonstandard data types
In addition to the standard data types that can be passed to functions as arguments, or used as
properties, such as integer, string, and so on, Fireworks accepts other data types.
Some functions accept values that are Fireworks objects. For more information, see
Fireworks Object Model" on page
Some functions accept a string in a specific format. Others accept value types that are not
Fireworks objects but are JavaScript object types that are specific to Fireworks. These types
of arguments are described next, in alphabetical order.
Color string data type
Functions that accept colors as arguments use the HTML syntax
specify a color with an alpha (transparency) component by passing a longer string of the
form
.
"#rrggbbaa"
Mask data type
The format for a mask is
,
string
featherAmount: int
specifies the bounding rectangle of the mask area.
maskBounds
Acceptable values for
"rle compressed"
If the value of
maskKind
mask of the right shape is constructed that fills
specified by
maskEdgeMode
If the value of
maskKind
"
uncompressed"
hexadecimal format that precisely matches the
9.
{maskBounds: rectangle
,
maskData: hex-string}
are
maskKind
"rectangle"
, or
"uncompressed"
is
"rectangle"
and
featherAmount
is "
zlib compressed
, the
string is presumed to contain 8-bit mask data in
maskData
fw.getDocumentDOM()
"Accessing a Fireworks
"#rrggbb"
,
maskKind: string
.
,
,
"oval"
"zlib compressed"
.
or
, the
"oval"
maskData
and that has the edge
maskBounds
.
", "
rle compressed"
to define the mask.
maskBounds
Using the Fireworks Object Model
function
"The
. You can
,
maskEdgeMode:
,
string is ignored, and a
, or
11
Need help?
Do you have a question about the FIREWORKS 8-EXTENDING FIREWORKS and is the answer not in the manual?
Questions and answers