
Editing HTML in Dreamweaver
343
Setting code formatting preferences
You can set the following preferences for formatting code in Dreamweaver:
•
Code Colors preferences control how HTML tags (and the text between them)
and scripts are color coded in the Code view or Code inspector. See “Setting
Code Colors preferences” on page 343.
•
Code Format preferences determine common code formatting options, such as
line length and indentation. See “Setting Code Format preferences” on page
344. These preferences provide a user interface for changing the
SourceFormat.txt file.
•
Code Rewriting preferences determine what changes, if any, Dreamweaver
makes to your code when you open an HTML or script document. See
“Setting Code Rewriting preferences” on page 346.
•
Fonts/Encoding preferences let you specify the font in which your code appears
in the Code view (or Code inspector). See “Setting Fonts/Encoding
preferences” on page 89.
Finally, the SourceFormat.txt file (in the Dreamweaver/Configuration folder)
provides precise specifications for formatting code. Editing this file in a text editor
gives you the greatest degree of control over exactly how Dreamweaver writes code;
you can change certain tag-specific options in this file that you can’t change using the
Code Format preferences. However, do not edit this file unless you are an advanced
Dreamweaver user or developer, because you may cause serious errors to your
Dreamweaver program. See “Changing default HTML formatting” on page 530.
Setting Code Colors preferences
Use Code Colors preferences to control the background, text, tag, and reserved
keyword colors in the Code view (or Code inspector). To work with these
preferences, choose Edit > Preferences and select Code Colors.
Background
specifies the background color of the Code view (or Code inspector).
This color appears only when you click or type in the Code view or inspector.
Text
specifies the color of text that appears between tags. For example, in the
code
<b>some text</b>
, the words “some text” appear in the specified text color,
but the tags do not. To override the text color for a specific tag, select the Include
Contents option.
Comments
specifies the color for comment tags (
<!-- -->
) and their contents.
Tag Default
specifies the color for all tags except comments. To override this color,
set the Tag Specific option.
Reserved Keywords
specifies the color for all reserved keywords. To override this
color, set the Tag Specific option.
Summary of Contents for 38028779 - Macromedia Dreamweaver - Mac
Page 1: ...macromedia Using Dreamweaver...
Page 148: ...Chapter 4 148...
Page 296: ...Chapter 12 296...
Page 472: ...Chapter 18 472...
Page 512: ...Chapter 21 512...
Page 562: ...Appendix 562...