12. Using File Lists

file list is simply a named list of file-name patterns or actual file names (possibly with extra suffixes attached to them specifying certain tree or node by its position in the file - see the file-name handling conventions described in Section 14, “Command-line options”). file lists can be created, modified, saved or deleted in a file list editor accessible via FileFile ListsManage File Lists... menu-command.

file lists can serve several purposes, the most common of which are searching and comfortable editing series of files. Each view is associated with a file list. For the active view, we call that file list the current file list. Name of the current-file list is displayed at the title of the main TrEd's window. If current file list contains more than one file, the commands FileFile ListsPrevious in File List (or start button) and FileFile ListsNext in File List (or end button) can be used to open previous and next file in the file list, respectively.

Figure 9. Creating file lists

file list

The following file lists are created and managed automatically by TrEd:

Default

This file list contains files opened with FileOpen ... during the current session up to the moment.

CmdLine-n

This file list contains files specified either directly on the command line or in file(s) following the command-line option -l. n is an integer number starting from 1 (files from the n-th file specified in -l appear in the file list CmdLine-n).

Bookmarks

The Bookmarks file list conains all bookmarks.

To create a user-defined file list, open the File List dialog, Type a name of the file list into the File lists field (on the top right side), press Enter and confirm the creation by pressing the Create button in the confirmation dialog which pops up. Alternativelly, press the New button, fill the name of the new file list to the entry in the displayed dialog and press OK.

To modify an existing file list, first choose it from the menu that appears when the button on the right of the File lists entry is pressed. To add some files to the chosen file list, first browse the files in the list on the left of the File List dialog. Then select the desired files in this list and finally press the Add-->. If the selection contains a directory, user is prompted for a wild-card pattern and all files from the directory matching the pattern are added to the file list. This is a very convenient way for adding all files in a directory. This has also the advantage that any change made in the content of the directory automatically leads to the corresponding effect in the file list.

To remove files from the file list, select the files and press the Remove button.

To make certain file list the current file list for TrEd double-click on any file in the file list or just select the file and press Show in TrEd. The selected file is opened and the file list is made current.

Note

It is possible to switch between several file lists without entering the file list editor, simply by selecting other file list using FileFile ListsSelect File List....

The button Save is used to save the chosen file list to a file, so that it can be either automatically or manually opened in the next TrEd's session. Note that the Bookmark file list is saved automatically at the end of every TrEd session.

The button Delete makes TrEd forget about the selected file list. Note that deleting a file list does not delete the file it was previously saved to.

The Load button can be used to load a previously saved file list. Note that all saved file lists that are known to TrEd at the end of a session are automatically loaded at the start of the next TrEd's session.

The button Close closes the File List dialog window.