
Next: Dials and Buttons
Up: The user interface
Previous: Function Keys
The command line maintains a list of all commands entered so far. The
arrow keys will scroll back through the history. You can press enter to
execute a previous command, or edit the command before running it.
Other features of the command line: you can execute any shell command by
beginning a command line with ``|'' (the vertical bar). For example
you can use |ls to get a directory listing or |pwd to get the
current working directory, or even |xterm & to spawn a shell.
There's also command line substitution like in the c-shell or t-shell.
Commands included in single back-quotes are passed to the shell for
evaluation before being interpreted by spock. One example of this would
be the command read=`ls -1 1a*.pdb`. This command will ask the
shell for a listing of PDB files that begin with 1a, and then (assuming
that there's only one) read it in. Other, more complicated uses are also
possible.
Finally, you may enter more than one command at a time on the command
line, provided that they are separated by a semicolon (;). Each command
will be processed in sequential order, exactly as if they were entered one
after another. However, if any part of the command causes an error, an
error message will be printed, and the rest of the line is ignored.
The command line (and all text-entry prompts) may be edited using the X
selection mechanism. Briefly, use the left mouse button to highlight/copy,
the middle mouse to paste, and press delete with text highlighted to delete.
Alternately, you may use emacs control key editing commands in the text
entry fields. The most commonly used commands are as follows:
- Ctrl-A: go to the beginning of a line
-
Ctrl-E: go to end beginning of a line
- Ctrl-P:
previous line
- Ctrl-N: next line
- Ctrl-K:
kill (delete) from the cursor to the end of the line.
-
Ctrl-F: forward character
- Ctrl-B: backward character
- Ctrl-D: delete next character
- Ctrl-Y: yank
(paste) the clipboard
You may use the X resources mechanism to change the key translations for
the text entry fields. A sample application defaults file may be found in
$SPOCK/Spock.ad, in case you want to do something heretical like
change to a vi-style binding for text editing. If you decide to do this,
be sure to change the bindings for both *XmTextField.translations
and .spock.GXMainW.GXPanedW.GXTextIn.translations.

Next: Dials and Buttons
Up: The user interface
Previous: Function Keys
Jon Christopher
Tue Sep 14 16:44:48 CDT 1999