The Visual Schnauzer

What's a Visual Schnauzer?

Hint: it's not a smallish seeing-eye dog of Germanic descent.

Probably the most exciting new feature in Version 3.00 was the Visual Schnauzer, and while it hasn't changed dramatically in Version 3.10, it's still plenty exciting. The Visual Schnauzer gives you a visual interface to the UNIX file system. It lets you view tiny 'thumbnail' representations of your image files, directories, and other files. It lets you create directories, rename files, move and copy files to different directories, delete files, view image files, view text files, and just generally nose around.

In short, it's cool, and it should be of some use for those of us who have large numbers of GIF and JPEG files with non-descriptive MS-DOS- style '8+3' filenames.

Note: Unlike most xv windows, schnauzer windows are resizable. You can decide how many (or few) icons you'd like displayed by changing the size of the schnauzer window. It also should be pointed out that there are more command buttons available than are shown at the default schnauzer size. If you make the window larger, you will be given additional command buttons. All the commands are always available from the Misc. Commands menu.

Operating the Schnauzer

Click on the Visual Schnauzer button in the xv controls window, or type a <Ctrl> v inside any active xv window. This will open a schnauzer window. The window will display the contents of the directory that you were in when you started xv. (Though this behavior, like so many things, can be overridden. See the description of the ' -dir ' command-line option in "Miscellaneous Options" .)

The first time you open an image directory with the schnauzer, you'll find that your image files are not displayed as spiffy little thumbnail icons, but instead are shown as generic icons showing the file format used. This is because the icons need to be generated from the image files. Displaying a thumbnail icon would normally require loading the entire image, compressing it down to a small 80x60- ish image, and dithering it with some set of colors. This is a very time-consuming operation. To avoid doing this every single time you open a schnauzer window, xv lets you do this operation once, and it maintains the results in a hidden subdirectory (' .xvpics ') for each directory. This subdirectory contains one small (2k) file for each file in the parent directory. The icons are in an 8-bit per pixel format, pre-dithered with a 332 RGB colormap.

So, assuming that there are some image files in the current directory, the first thing you should do is generate some icons. (If there aren't any image files in the current directory, exit xv and start it again from a directory that does have image files. We'll discuss navigating via the schnauzer later.)

Generating Image Icons

To generate icons for all the images in the current directory, issue the select All files command from the Misc. Commands menu. All the icons in the current directory should 'light up' in some way to signify that they are selected, with the possible exception of the <parent> directory.

Next, issue the Generate icons command from the Misc. Commands menu. xv will begin the process of generating icon files for the selected files. This process can be quite time-consuming, particularly if you have a large number of files in the directory, or the image files are in the JPEG format. During this time, xv is effectively 'out-to-lunch', as it will not be paying attention to any X events. There isn't any way to stop it either, though if you kill the xv process from another window, you will succeed in stopping the icon generation. You will not lose any computed icons by doing this, as icon files are written out as they are computed, so it's perfectly safe to stop the generation via this method.

Also, you'll note that xv displays a bar-graph 'progress meter' at the top of the schnauzer window while it's doing this, so you can gauge roughly how long it will take. Icons will be displayed as they are generated, in an attempt to make the process as entertaining as possible.

Changing Directories

The name of the current directory is displayed in a button at the top-center of the schnauzer window. You can change to any higher-level directory in the current path by pulling down this menu button. The names of the parent directories will be shown in the pull down menu.

You can also go up one level by double-clicking on the <parent> directory icon.

You can go down to any subdirectory by double-clicking on the appropriate subdirectory icon.

The Change Directory command gives you a more direct route: you just type the pathname of the directory you'd like to go to.

Scrolling the Schnauzer

You can scroll the schnauzer by operating the vertical scroll bar, which operates exactly as described in "Operating a List Window" .

You can also scroll the window a page at a time by using the <PageUp> and <PageDown> keys on your keyboard (which may be labeled <Prev> and <Next> on some keyboards). The <Home> and <End> keys will take you to the beginning and end of the list, respectively. (If your keyboard doesn't have Home and End keys, <Shift> <PageUp> and <Shift> <PageDown> may also work.) You can scroll the list aline at a time by using the up and down arrow keys. Note, however, that the arrow keys move the indicator that shows the currently selected file. Likewise, the left and right arrow keys move the selection indicator left and right, wrapping at the edges of the window.

Also, if you type a normal, alphabetic character into the schnauzer window, it will attempt to scroll the window so that the first file beginning with that character will be visible. Note that this behavior keeps you from typing normal xv keyboard equivalents into this window, so don't even try it.

Selecting Files

Double-click on an image file's icon. The image should be loaded, and the full path name of the image should be added to the bottom of the xv controls window's name list. You can also double-click on text files to view them in a TextView window. (See "The TextView Window" for more information.)

It is possible to select more than one file at a time. The easiest way to do so is to hold down the <Shift> key and click on icons. When the <Shift> key is held down, any icons clicked on are simply toggled between being selected, and being not selected. All other files remain as they were. If you type <Shift> <Space> , xv will keep all currently 'lit' files lit, and light (and load) the file after the last lit file it finds. This can be useful for building up a big list of files to delete by <Shift> <Space> -ing your way through the list, and manually unselecting any files you want to keep.

You can also select files by drawing a rectangle around icons that you want selected. To do so, simply click in the space in between the icons, and drag. A rectangle will be drawn, and all icons that are inside (or partially inside) the rectangle will be selected. Note that if you drag the rectangle off the top or bottom of the window, the window will automatically scroll. Also, if you hold down the <Shift> key while you draw a rectangle, any previously selected icons will continue to remain lit.

Finally, you can also select files by using the select All files command from the menu (or by typing a <Ctrl> a ) to select all the icons in the current directory. If you want most of the files selected, it might be easiest to select all the files, hold down the <Shift> key, and selectively turn off the ones you don't want selected.

If you double-click on a selected file while there are multiple files selected, the clicked-on file will be displayed, and all selected filenames will be copied into the xv controls window's list.

File Management

Once you have some files selected, you can move them to other directories by clicking on a lit icon and dragging it into one of the subdirectories. When you press the mouse button, the cursor will change to a 'files' cursor to indicate that you are potentially moving files around. If you move the cursor near the top or bottom edge of the window, the window will scroll up or down accordingly. Necessary, as the subdirectory folders are always shown at the top of the window. When you move the cursor on top of a folder (either the <parent> directory, or one of the subdirectories), the folder will light up to acknowledge your selection. If you release the mouse button while a folder is lit, all currently selected files (and folders) will be moved into the lit folder.

Note that, using only one schnauzer window, it's only possible to move files up or down one directory level. If you want to move files to completely unrelated directories, you can easily accomplish this by opening a second schnauzer window (via the open new Window command in the menu, or <Ctrl> w ). Get the second schnauzer window aimed at the desired destination directory, and simply drag the files from the first window into the second window.

Also, when you drag files around, xv normally 'moves' the files from one directory to another. If you'd like, you can copy files instead of moving them. Just press (and hold down) the <Ctrl> key while dragging the files. The 'files' cursor will change to display 'CPY' as well, to signify that you are copying files instead of moving them.

The remaining file-management commands (renaming files, deleting files, and creating subdirectories) are discussed below.

The Commands

There are more commands available in the schnauzer than are normally displayed in the buttons at the bottom of the window. The additional buttons will be displayed if you make the window larger.

Alternately,all commands are always available via the Misc. Commands menu shown to the left.

Note that the keyboard equivalent for all commands that have one is listed in the menu, next to the command. ('^' means <Ctrl> )

Also note that the bottom two commands, Show hidden files , and Select files , do not appear as buttons, ever. They're only accessible via the Misc. Commands menu.

Pops open a dialog box that prompts you for a directory name to cd to. This can be handy if the directory you want to go to is far away in the directory tree.
Keyboard Equivalent: <Ctrl> c
This command can only be issued when one or more files (or directories) are selected. It will pop up a confirmation box to make sure you didn't accidentally issue the command. At the confirmation box, you can type <Ctrl> d a second time to say Ok , or press <Esc> to Cancel the deletion. (Of course, you can just click on the appropriate button, as well.) Also, note that if you delete a subdirectory, all files and directories in that subdirectory will be recursively deleted. Finally, note that you can't delete the <parent> directory... for your own protection.
Keyboard Equivalent: <Ctrl> d
When you issue this command you'll be prompted for a plain filename for the new directory. You can only create subdirectories in the current directory.
Keyboard Equivalent: <Ctrl> n
This command can only be used when a single file (or subdirectory) is selected. You'll be prompted for the new name. Also, note that you can't rename the <parent> directory, again, for your own good.
Keyboard Equivalent: <Ctrl> r
Rescans the current directory. Since other programs may be creating or deleting files in the current directory, the contents shown in the schnauzer may not always be up-to-date. Use the ReScan command to re-read the current directory.
Keyboard Equivalent: <Ctrl> s
Like the ReScan command, but more serious about it. In addition to re-reading the current directory contents, it will also look for files that don't have icons created (or files that have later modification times than their associated icon files) and generate icons for them. After that, it will look for icon files that no longer have associated image files (which can happen if you delete the image files without using the schnauzer), and deletes them. Note that this command is not limited to the selected files, unlike the Generate icon(s) command listed below.
Keyboard Equivalent: <Ctrl> u
Opens a new schnauzer window, up to a maximum of 4. The new schnauzer opened will display the same directory that the opening- schnauzer was displaying.
Keyboard Equivalent: <Ctrl> w
Unconditionally generates icons for all the currently selected files. As such, you can only issue this command when one or more files are selected.
Keyboard Equivalent: <Ctrl> g
Selects all files in the current directory.
Keyboard Equivalent: <Ctrl> a
Displays the currently-selected file in a TextView window. This command can only be used when there is exactly one file currently selected. Note that if you double-click on a file in an unrecognized format, xv will automatically display it in a TextView window. This command lets you view recognized image files in text mode.
Keyboard Equivalent: <Ctrl> t
Recursively walks its way down a directory tree, starting from the current directory, and does an Update command in each subdirectory. It will follow symbolic links, if you have any, and it's smart enough to avoid circular links. It gives you a nifty way to generate icons for an entire hierarchy of image files. It can also take a Good Long Time, depending on your particular situation, so it pops up an annoying "Are You Sure?" dialog box before it starts working its magic.
Keyboard Equivalent: <Ctrl> e
Exits the xv program.
Keyboard Equivalent: <Ctrl> q
Closes this particular schnauzer window.
Keyboard Equivalent: <Ctrl> c
Toggles whether or not 'hidden' files (in Unix, files that have a '.' as their first character) should be displayed.
Keyboard Equivalent: <none>
Opens a dialog box that lets you select files by name. Wildcards are accepted. It does not clear any previously selected files.
Keyboard Equivalent: <Ctrl> f

This document was extracted from the PostScript documentation and formatted by Roy Johnson. Much of the process was automated, and may therefore have introduced errors. Corrections are appreciated.