This dialog box allows you to specify preferences for how Dreamweaver formats code.
NOTE |
|
All the preferences except "Override Case Of" affect only new documents and new additions to existing documents. That is, when you open a previously created HTML document, these formatting options are not applied to it; to reformat existing HTML documents, use the Apply Source Formatting command. For more information, see Applying new formatting preferences to existing documents. |
Indent indicates whether code generated by Dreamweaver should be indented (according to the indentation rules specified in these preferences) or not.
NOTE |
|
Most of the indentation options in this dialog box apply only to code generated by Dreamweaver, not to code that you type. To make each new line of code that you type indent to the same level as the previous line, use the Auto-Indent option in the View Options menu of Code view. For more information, see Setting code viewing options. |
With (text box and pop-up menu) specifies how many spaces or tabs Dreamweaver should use to indent code that it generates. For example, if you type 3 in the text box and select Tabs in the pop-up menu, then code generated by Dreamweaver is indented using three tab characters for every level of indentation.
Tab Size determines how many characters wide each tab character appears in Code view. For example, if Tab Size is set to 4, then each tab is displayed in Code view as a four-character-wide blank space. If, additionally, Indent With is set to 3 Tabs, then code generated by Dreamweaver is indented using three tab characters for every level of indentation, which appears in Code view as a twelve-character-wide blank space.
NOTE |
|
Dreamweaver indents using either spaces or tabs; it doesnt convert a run of spaces to a tab when inserting code. |
Automatic Wrapping inserts a line-break character (also known as a "hard" return) when a line reaches the specified column width. (Dreamweaver inserts line-break characters only in places where they dont change the appearance of the document in browsers, so some lines may remain longer than the Automatic Wrapping option specifies.) By contrast, the Wrap option in Code view displays long lines (that extend beyond the width of the window) as if they contained line-break characters, but doesnt actually insert line-break characters.
Line Break Type specifies the type of remote server (Windows, Macintosh, or UNIX) that hosts your remote site. Choosing the correct type of line break characters ensures that your HTML source code appears correctly when viewed on the remote server. This setting is also useful when you are working with an external text editor that recognizes only certain kinds of line breaks. For example, use CR LF (Windows) if Notepad is your external editor, and use CR (Macintosh) if SimpleText is your external editor.
NOTE |
|
For servers that you connect to using FTP, this option applies only to binary transfer mode; the ASCII transfer mode in Dreamweaver ignores this option. If you download files using ASCII mode, Dreamweaver sets line breaks based on the operating system of your computer; if you upload files using ASCII mode, the line breaks are all set to CR LF. |
Default Tag Case and Default Attribute Case control the capitalization of tag and attribute names. These options are applied to tags and attributes that you insert or edit in Design view, but they are not applied to the tags and attributes that you enter directly in Code view, or to the tags and attributes already in a document when you open it (unless you also select one or both of the Override Case Of options).
Override Case Of: Tags and Attributes specify whether to enforce your specified case options at all times, including when you open an existing HTML document. When you select one of these options and click OK to dismiss the dialog box, all tags or attributes in the current document are immediately converted to the specified case, as are all tags or attributes in each document you open from then on (until you deselect this option again). Tags or attributes you type in Code view and in the Quick Tag Editor are also converted to the specified case, as are tags or attributes you insert using the Insert bar. For example, if you want tag names always to be converted to lowercase, specify lowercase in the Default Tag Case option, and then select the Override Case Of: Tags option. Then when you open a document that contains uppercase tag names, Dreamweaver converts them all to lowercase.
NOTE |
|
Older versions of HTML allowed either uppercase or lowercase tag and attribute names, but XHTML requires lowercase for tag and attribute names. The web is moving toward XHTML, so its generally best to use lowercase tag and attribute names. |
Centering specifies whether elements should be centered using div
align="center"
or the center
tag when you click the Align Center button in the Property inspector.
NOTE |
|
Both of these approaches to centering have been officially deprecated as of the HTML 4.01 specification; you should use CSS styles to center text. Both of these approaches are still technically valid as of the XHTML 1.0 Transitional specification, but theyre no longer valid in the XHTML 1.0 Strict specification. |