User Guide

438 Design
Example
The following example checks the value of the margin and padding color; if either isnt white,
it sets them both to white:
var boxColors = dreamweaver.getBlockVisBoxModelColors();
if ((boxColors[0] != "#FFFFFF") || (boxColors[1] != "#FFFFFF)){
currentDOM.setBlockVisBoxModelColors("#FFFFFF", "#FFFFFF");
}
dreamweaver.getBlockVisOutlineProperties()
Availability
Dreamweaver 8.
Description
This function gets the outline properties for the block visualization visual aids.
Arguments
forWhat
The forWhat argument, which is required, is a string. Possible values are "divs",
"selectedDiv", or "layers". If the forWhat argument is "divs", the function returns
the properties used for the visual aid that outlines all layout blocks. If
forWhat is
"selectedDiv", the function returns the property used for the visual aid that outlines
selected layout blocks. The
layers value specifies layers.
Returns
An array of strings that contains three strings:
color, which is the hexadecimal value of the RGB color, in the form #RRGGBB
width, which indicates the width in pixels
style, which is "SOLID", "DOTTED", "DASHED", or "OUTSET"
Example
The following example gets the outline properties for "divs" and makes the outline style
"SOLID":
var outlineStyle = dw.getBlockVisOutlineProperties("divs");
if (outlineStyle[2] != "SOLID"){
dw.setBlockVisOutlineProperties("divs", outlineStyle[0],
outlineStyle[1], "SOLID");
}
000_DW_API_Print.book Page 438 Wednesday, July 20, 2005 11:58 AM