Macromedia dreamweaver 8-extending dreamweaver User Manual

Page of 504
The Property inspector API
285
Creating the image
You can optionally create the image that appears in the Property inspector.
To create the image:
1.
Create an image that is 36 pixels wide and 36 pixels high.
2.
Save the image as marquee.gif in Configuration/Inspectors.
In general, you can save images for Property inspectors in any format that Dreamweaver 
supports.
Testing the Property inspector
Finally, you can test the Property inspector.
To test the Property inspector:
1.
Restart Dreamweaver.
2.
Create a new HTML page, or open an existing HTML page.
3.
Add the following in the 
BODY
 section of the page:
<MARQUEE></MARQUEE>
4.
Highlight the text you just added.
The Property inspector you created for the 
MARQUEE
 tag appears.
5.
Enter a value for the Direction attribute in the Property inspector.
The tag on your page changes to include the direction attribute and the value you entered 
in the Property inspector.
The Property inspector API
Two of the Property inspector API functions (
canInspectSelection()
 and 
inspectSelection()
) are required. 
canInspectSelection()
Description
Determines whether the Property inspector is appropriate for the current selection.