7.3 History Panel


The History panel tracks all your actions in the Document window, such as menu options you have selected and characters you have typed. You can use it to undo, redo, and automate one or more commands, but it doesn't track your actions in the Site window and it isn't available when in Code view. To open the History panel, shown in Figure 7-9, use Window figs/u2192.gif History or Shift+F10.

Figure 7-9. The History panel
figs/dwn_0709.gif

The vertical slider on the left side can be used to undo and redo steps in the History panel. You can also click to the left of a step to undo to that point. Use Edit figs/u2192.gif Undo, or Ctrl+Z (Windows), or Cmd+Z (Macintosh) to undo a single step. Use Edit figs/u2192.gif Redo, or Ctrl+Y (Windows), or Cmd+Y (Macintosh) to redo a single step. Set the maximum levels of Undo using Edit figs/u2192.gif Preferences figs/u2192.gif General figs/u2192.gif Maximum Numbers of History Steps (large numbers may consume excessive memory and slow performance).

The history is kept separately for each open document and disappears when you close a document. Unlike most other programs, however, you can undo steps even after saving a document (as long as you haven't closed it). You can clear the History panel, using the Clear History command in the pop-up menu, to conserve memory, but doing so prevents you from using undo.

If you undo several steps and then start a new action, the undone actions are discarded (i.e., those steps can't be recovered).

7.3.1 Replaying Steps

The History panel allows you to repeat a step or series of steps that have been performed. Select the step(s) that you wish to repeat and click the Replay button (indicated in Figure 7-9) or choose Replay Steps from the pop-up menu.

You can't edit steps or modify their order in the History panel, but you can skip steps. To do so, select a step and then use Ctrl-click (Windows) or Cmd-click (Macintosh) to select additional steps (they need not be contiguous). For example, you can select the first, third, and fifth steps in a process, but skip the second and fourth steps. When you click the Replay button, only the selected steps are repeated.

The History panel shows the history for the current window only (although it maintains a history for all open documents). To copy a series of steps into another document:

  1. Select the desired steps in the History panel.

  2. Copy the steps to the clipboard by using the Copy to Clipboard button (see Figure 7-9) or the Copy Steps command from the pop-up menu; the Edit figs/u2192.gif Copy command won't work for this purpose.

  3. Switch documents or open a new document.

  4. Paste the steps into the new document using Edit figs/u2192.gif Paste, Ctrl+V (Windows), or Cmd+V (Macintosh). The copied steps will be executed.

Commands can be applied to individual elements, but not to groups of elements. For example, you can resize three images separately, but not as a group . See "Applying Steps to Multiple Objects" in the Dreamweaver Help for details on applying steps to multiple elements (the trick is to select the next element using the Shift and arrow keys, not the mouse).

Use the Copy Steps button in the History panel to copy one or more selected commands; then use Edit figs/u2192.gif Paste as HTML to see the underlying JavaScript. This is a good way to learn or edit the JavaScript behind any Dreamweaver function.

7.3.2 Creating Custom Commands

Creating custom commands from the History panel allows you to repeat a task multiple times. To create a command from steps that have already been performed, highlight the steps in the History panel and click the Save As Command button (see Figure 7-9). This button opens the Save As Command dialog box, which allows you to name your command. Custom commands appear on your Commands menu and can be used in any Dreamweaver file, not just the original document. Good uses for custom commands include Copyright or Designed By statements, privacy policies, or anything that's used across multiple pages or multiple sites.

Dreamweaver can't record mouse movements, but it can record all of your keyboard shortcuts. If you wish to record a series of intricate menu options, use your keyboard to open and select the options, or use the shortcut keys.

Commands that can't be played back, such as mouse movements, are indicated by a black line or a red X in the History panel. Performing actions without the mouse may take some practice. See Edit figs/u2192.gif Keyboard Shortcuts ( especially the Code Editing and Document Editing commands) for lists of keyboard commands. Remember that you can use the Tab key and arrow keys to navigate in dialog boxes and file lists, and any Windows menu command can be accessed using the Alt key.

7.3.2.1 Editing the Commands menu

To edit the name of a custom command or delete it at a later time, use Commands figs/u2192.gif Edit Command List. You can't edit the actual commandsonly their names ; to change a command's operation, you must delete and recreate it.

Commands are shown in the order they were created. To change the order, edit the menus .xml file, which controls Dreamweaver's menus, directly. See Chapter 19 for details.

Use Commands figs/u2192.gif Get More Commands to download additional commands, (i.e., Extensions) from the Dreamweaver Exchange. These commands are discussed in Chapter 22.

7.3.2.2 Recording a command

If you know you'll want to play back the steps you are about to take, record them using Commands figs/u2192.gif Start Recording, Ctrl+Shift+X (Windows), or Cmd+Shift+X (Macintosh). This command records all of your keystrokes and object insertions until you select Commands figs/u2192.gif Stop Recording or press Ctrl+Shift+X (Windows) or Cmd+Shift+X (Macintosh) again. While recording, the cursor looks like a cassette tape. Recorded commands aren't stored in the Commands menu but can be played back using Commands figs/u2192.gif Play Recorded Command, Ctrl+P (Windows), or Cmd+P (Macintosh).



Dreamweaver in a Nutshell
Dreamweaver in a Nutshell
ISBN: B000C4SPTM
EAN: N/A
Year: 2005
Pages: 208

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net