The Edit class in Tycho provides an emacs-like text editor window.
It is derived from the File class, and
therefore inherits all of its features.
Several classes derived from Edit provide specialized editors for a variety
of uses. All of these share the same emacs-like
key bindings for moving
the insertion cursor, modifying text, and paging through a document.
Equivalent commands are also available in the pull-down menus
at the top.
The Edit class provides the following special features:
- Find/Change
search. This is a fairly sophisticated search
mechanism that includes facilities for identifying only whole words,
considering case, using regular expressions, and changing all instances
at once. When a search is launched, all matches are highlighted in the
text. You can then step through the matches one by one by repeating the
search.
- Spelling checker.
The spelling checker current uses the Unix "spell" command and highlights
all whole words that the spell command identified as being misspelled.
In specialized editors derived from this one, a subset of the text
may be checked for spelling errors. For example, in a language-specific
programming editor, only comments will be checked. In the HTML editor,
HTML directives are ignored.
- Fill. In the "Format" menu, three
commands support filling text.
The Fill Region
command restructures the selected text to make all lines approximately
the same length. The Right Fill Column
command queries the user for the maximum line length to use in filling.
The Set Fill Prefix command queries
the user for a prefix (such as a comment character) to use when filling
text. In language-specific derived classes, this prefix is set by
default to the comment character(s) for the language.
- Printing. In the "File" menu,
the Print command can be used to print the entire contents of the text
widget or, if there is a selection, the selected area.
The user is prompted for the command to use for printing.
Tycho Home Page
Copyright © 1996, The Regents of the University of California.
All rights reserved.
Last updated: 96/12/13,
comments to: eal@eecs.berkeley.edu