![MACROMEDIA FIREWORKS 8-EXTENDING FIREWORKS Скачать руководство пользователя страница 12](http://html1.mh-extra.com/html/macromedia/fireworks-8-extending-fireworks/fireworks-8-extending-fireworks_manual_3339145012.webp)
12
The Fireworks Object Model
Matrix data type
The format for a matrix is
{
matrix
:
[float, float, float, float, float, float,
float, float, float]}
. 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
{
x:
float
,
y:
float}
. For instance,
dom.addNewLine(
startPoint
,
endPoint
)
could look like 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
{
left:
float,
top:
float,
right:
float,
bottom:
float}
. For instance,
dom.addNewOval(
boundingRectangle
)
could look like the following
example:
fw.getDocumentDOM().addNewOval({left:72, top:79, right:236, bottom:228});
Resolution data type
The format for resolution is
{
pixelsPerUnit:
float,
units:
string}
. Acceptable values
for units are "
inch
" or "
cm
". For instance,
dom.setDocumentResolution
(
resolution
)
could
look like the following example:
fw.getDocumentDOM().setDocumentResolution({pixelsPerUnit:72, units:"inch"})
;
Global methods
The following table lists the global Fireworks methods, along with their argument data types
and, where appropriate, acceptable values and notes.
Method
Data type
Notes
alert(message)
string
Displays a string in a modal alert box, along
with an OK button. Returns nothing.
confirm(message)
string
Displays a string in a modal alert box, along
with OK and Cancel buttons. Returns
true
if OK is clicked,
false
if Cancel is clicked.
Содержание FIREWORKS 8-EXTENDING FIREWORKS
Страница 1: ...Extending Fireworks ...
Страница 4: ...4 Contents ...
Страница 358: ...358 Fireworks JavaScript API ...
Страница 372: ...372 Index ...