![MACROMEDIA FIREWORKS 8-EXTENDING FIREWORKS Manual Download Page 158](http://html1.mh-extra.com/html/macromedia/fireworks-8-extending-fireworks/fireworks-8-extending-fireworks_manual_3339145158.webp)
158
Fireworks JavaScript API
dom.changeSliceGuide()
Availability
Fireworks MX.
Usage
dom.changeSliceGuide(
currentPosition
,
newPosition
,
guidekind
,
isMagneticDrag, isSingleDrag
)
Arguments
currentPosition
A floating-point value that specifies the current position of the slice
guide to be moved.
newPosition
A floating-point value that specifies the new position of the slice guide.
guidekind
Acceptable values are
"horizontal"
and
"vertical"
. If the value of
guidekind
is
“horizontal”
, Fireworks assumes that the specified positions are
y
coordinates; if
"vertical"
, the specified positions are
x
coordinates.
isMagneticDrag
A Boolean value that determines whether to move other slice guides
between the old and new positions. If
isMagneticDrag
is
true
, Fireworks also moves slice
guides between the old guide position and the new position. This action resizes and possibly
deletes rectangular slices that do not abut the slice guide at
currentPosition
.
isSingleDrag
A Boolean value that determines whether the operation is performed only on
the selected slice or on all slices that are affected by the slice guide. If
isSingleDrag
is
true
,
Fireworks performs only the
changeSliceGuide()
action on the selected slice.
Returns
Nothing.
Description
Moves a slice guide’s position to a new location, which resizes any rectangular slices that abut
the guide. An argument controls whether slice guides that exist between the old position and
the new one are also moved.
If a slice is resized so that it has zero width or height, the slice is deleted.
This function does not change slices that are not rectangular.
Example
The following command moves a vertical slice guide from position 135 to position 275, and
moves all vertical slice guides between 135 and 275 to 275:
fw.getDocumentDOM().changeGuide(135, 275, "vertical", true);
Summary of Contents for FIREWORKS 8-EXTENDING FIREWORKS
Page 1: ...Extending Fireworks ...
Page 4: ...4 Contents ...
Page 358: ...358 Fireworks JavaScript API ...
Page 372: ...372 Index ...