Using Dreamweaver as a Text Editor

The power of Dreamweaver has always been its close integration between visual and text-based editing. The program’s built-in text editor, accessible through the Document window’s Code view or the separate Code inspector panel, offers many features generally found only in dedicated text-editing programs. These include line numbers, word wrap control, syntax-based color coding, complex text searches utilizing regular expressions—and, new to Dreamweaver MX, several features adopted from HomeSite, such as code hints and tag completion. In addition, because the Dreamweaver text editor also is responsible for writing the code created when you work in Design view, it includes built-in source formatting and error-correction functions.

Accessing the Text Editor

You can access the Dreamweaver text editor from the main Document window by choosing Code view or Code and Design view. (For a full discussion of the Document window, see Chapter 2, “Setting Up the Dreamweaver Workspace.”) Alternatively, you can open the text editor in its own tabbed panel window by accessing the Code inspector (go to Window > Others > Code inspector). All text-editing features work the same in both Code view and the Code inspector. If you’re short on screen space, you’ll probably want to use Code view (or Code and Design view) in the Document window. If you have a dual monitor setup at your workstation, you may prefer to display the Document window, set to Design view, on one monitor and the Code inspector, along with any other open panels, on the other monitor. Figure 33.1 shows Code view and the Code inspector, side-by-side for comparison.