Macromedia dreamweaver 8-extending dreamweaver 사용자 설명서
112
User Interfaces for Extensions
When you design an extension, you should determine what variables are necessary and what
form elements can best handle them.
form elements can best handle them.
Consider the following basic guidelines when you design an extension UI:
■
To name your extension, place the name in the
title
tag of your HTML file.
Dreamweaver displays the name in the extension title bar.
■
Keep text labels on the left side of your UI, aligned right, with text boxes on the right side,
aligned left. This arrangement lets the user’s eyes easily locate the beginning of any text
box. Minimal text can follow the text box as explanation or units of measure.
aligned left. This arrangement lets the user’s eyes easily locate the beginning of any text
box. Minimal text can follow the text box as explanation or units of measure.
■
Keep checkbox and radio button labels on the right side of your UI, aligned left.
■
For readable code, assign logical names to your text boxes. If you use Dreamweaver to
create your extension UI, you can use the Property inspector or the Quick Tag Editor
create your extension UI, you can use the Property inspector or the Quick Tag Editor
to
assign names to the fields.
In a typical scenario, after you create the UI, you test the extension code to see that it properly
performs the following UI-related tasks:
performs the following UI-related tasks:
■
Getting the values from the text boxes
■
Setting default values for the text boxes or gathering values from the selection
■
Applying changes to the user document
Dreamweaver HTML rendering control
For versions through Dreamweaver 4, Dreamweaver rendered more space around form
controls than Microsoft Internet Explorer and Netscape Navigator do. Form controls in
extension UIs are rendered with extra space around them because Dreamweaver uses its
HTML rendering engine to display extension UIs.
controls than Microsoft Internet Explorer and Netscape Navigator do. Form controls in
extension UIs are rendered with extra space around them because Dreamweaver uses its
HTML rendering engine to display extension UIs.
Macromedia has improved form-control rendering to more closely match the browsers. To
take advantage of the rendering improvements, you must use one of three new
take advantage of the rendering improvements, you must use one of three new
DOCTYPE
statements in your extension files, as shown in the following example:
<!DOCTYPE HTML SYSTEM "-//Macromedia//DWExtension layout-engine 5.0//
dialog">
<!DOCTYPE HTML SYSTEM "-//Macromedia//DWExtension layout-engine5.0//
floater">
<!DOCTYPE HTML SYSTEM "-//Macromedia//DWExtension layout-engine5.0//pi">