\documentstyle[11pt]{report}
\pagestyle{headings}
\title{EVE Users Guide}
\author{}\date{}
\begin{document}
\maketitle
\tableofcontents
{\sf
This manual describes the local customization of the EVE editing
interface provided by Digital Equipment Corporation under the
VMS Operating System on the VAX.}

\chapter{EVE -- Extensible VAX Editor} % @label(Overview)
\section{What is EVE?}
EVE is an interface to the new V4 TPU (text processing
utility) Editor. The TPU  editor utility contains primitive
function calls which can be tailored into an custom editing environment.
There are currently two interfaces with TPU. One emulates EDT (more or less),
while the other is called EVE. EVE as provided by DEC is 
itself a {\it bare bones} interface to TPU. 
The user may come across documentation for EVE in {\it Guide to Text
Processing}, but should note this documentation is discussing the DEC-EVE,
which is a subset of our local more powerful EVE.
In an attempt to show the user community how to expand the EVE interface,
DEC provided {\it EVEplus} on a
recent DECUS tape. This became the starting point for the local customization
of EVE. Although from a syntax point of view it may be correct to call 
our local EVE - {\it EVEplusplus}, it was decided this might cause confusion
not to mention massive amounts of typing just to invoke our version of
EVE. As the abbreviation implies, EVE can be modified easily and extended
in functionality by the user.

\section{How to Use EVE}
Setup a local symbol : 
\begin{verbatim}
$ eve = "ed/tpu/sec=sys$common:[syslib]eveplus.tpu$section"
\end{verbatim}
Next make sure your terminal setting is either {\tt eight-bit no parity},
or if you are using a 7-bit setting type in (or place in your login.com)-
{\tt \$ set term/noeightbit}.
You will now be able to invoke eve by simply typing
in : 
\begin{verbatim}
$ EVE filename
\end{verbatim}
DEC Has found via benchmark tests EVE is approx. 35\% faster than EDT.
The latest release of TPU makes EVE even faster! Hopefully you will notice
this when attempting to enter the editor. Upon entry into EVE you will 
be automatically placed in screen mode editing. After the file comes up
you will see an inverse status line on the bottom of the screen. It 
will indicate the name of the buffer, which initially is the name of the file
being edited. Next to the buffer name will be {\it WHITE\_MAP}. This field
will always indicate the current keymap or level in the keypad you are on.
The next field indicates whether you are in insert or overstrike mode.
This field can be altered with the F14 key (VT200), or ctrl-V (all terminals).
The last field indicates the direction of editing, forward or reverse. This
can be altered with the F11 key (VT200), or the KP4 advance (white) and
KP5 backup (white) keys.

\section{EVE keypad}
The EVE keypad has 4 layers. The first two layers
(white-yellow) are very simular to the standard EDT keypad. The other two
layers (red-blue) contain additional EVE functions. At anytime if you hit
the PF2 (help) key, it will display the keymap (as a layer is called in
EVE), and the next keymap down. For example if you are in the yellow keymap,
and hit PF2 the yellow-red keymaps are displayed. How do you get from
one keymap to another? Hit the PF1 key and EVE will toggle you down to the
next keymap. If you are in the white keymap and hit the PF1 key 4 times
the following conceptual events would occur: white-$>$yellow-$>$red-$>$blue-$>$white.
Each time the PF1 key is hit the map field in the status line will update
and indicate the new keymap. 
After toggling to the keymap desired, upon hitting a keypad key the command
is executed, and the user to returned the white keymap.
If you wish to stay in the keymap and not be automatically returned to 
the white map, then before entering a keypad key, enter {\it ctrl-?}. 
This will prevent EVE from returning you to the white keymap. Instead you
will remain in the current map. You can use the PF1 to toggle to other
maps, but as long as the lock feature is on EVE is prevented from returning
you to the white keymap automatically. You can reactivate the automatic
return to the white keymap, by entering {\it ctrl-?}. This will toggle the
auto return feature on. This function works only for 
VT200 terminals. If you are on a VT100 terminal,
and wish to have the toggling feature, then you will need to bind the
function: {\it eve\_lock\_map} to a given key of your choice.
We have attempted to arrange the key layout such that the less used
functions are in the bottom keymaps, and complementary functions are at
the same level. The individual keys
are described in the appendix- {\it EVE Keypad Commands}.  A color
diagram of the EVE keypad is available to all users, reflecting             
the first 4 levels in the keypad.

\section{Accessing Non-keypad EVE and TPU commands}
You can access any
EVE or TPU function through the {\tt Do} key. If you hit the {\tt Do}
key you will receive the prompt at the bottom of the screen- {\tt Command}.
At this level you can enter the name of any EVE function. 
To enter a TPU command (i.e. by command we actually mean a TPU
{\it primitive} or function found in the TPU manual), enter {\tt TPU}.
You will now receive the prompt- {\tt TPU command}. At this level
enter the TPU command. Note many TPU commands require parameters.
TPU commands which return values can not be executed interactively
since there is no variable to receive the value. The {\tt Do} key
also has a couple of other neat functions. If you hit the {\tt Do} key
twice it will repeat the last command. You can also toggle through
the command buffer. Hit the {\tt Do} and thereafter the up and down
arrows. This allows the user to go up and down in the command buffer,
to execute a given command in the command buffer just hit $<$CR$>$. 
This mimics the command recall at DCL level.

\section{Concept of EVE keymaps}
Before discussing how the user can define 
his/her own keys, let's first discuss the exact meaning of the word
{\it keymap}. Starting with VMS4.4, TPU was released with the concept of
keymaps and keymap lists. Consider the TPU function define\_key. It takes
4 parameters: function, keyname, comment, and keymap. A key can be bound
to any existing function and keymap. In turn the keymap can be bound to
any existing keymap list. The keymap list behaves analogous to a link
list. When EVE goes to lookup a key definition it starts in the first keymap
in the list, and proceeds to traverse the list until it finds a binding.
A keymap may contain as many definitions as there are keys on the terminal
keyboard, except for a few special keys such as ctrl-Y, ctrl-Q etc. The
number of keymaps which can be created is limited as is EVE by the process
working set  in memory. If the reader is interested in seeing the
EVE keymap list, try giving the eve command: {\tt eve\_show\_keymaps}. There
are two ways a user can define a key: eve\_user\_define\_key (PF3-yellow),
or the tpu command define\_key. Both will behave differently. On the assumption
the user wants his/her definition to supercede the present definition,
eve\_user\_define\_key will attempt to make sure the key is placed in the
proper keymap. The TPU define\_key will place the key definition in the
eve\$user\_keys keymap if the keymap is not explicitly given in the 
define\_key command. It is {\it recommended} the eve\_user\_define\_key function
be used.

\section{How to extend EVE}
If you define a key, the definition will go into
effect immediately. If you write a function it will remain unknown to
EVE until you {\it extend} the current EVE session. Extending EVE places
the definition for the function in the internal tables of EVE.
You may extend EVE by using KP-7 (Red), or directly using the {\tt Do}
key and typing in the command {\tt Extend}. Either method will prompt you
for a function name. Type in the function name to extend a particular
function, else type in ``*'' to extend every function in the current
buffer. EVE will flash at light speed several messages at the bottom
of the screen. If everything is correct EVE will display a message that
the function was extended and TPU detected no errors. If there are
errors, then it will inform you there were errors and that TPU was not
extended. If there are errors you may wish to view the message buffer
to see where they occurred. EVE will point to the syntax errors where
they occurred. After correcting the errors, try the extension again.
The new key binding and function extensions will not be present in the
next editing session unless they are {\it saved}. When you use KP-7 (Blue),
or the command {\tt save}, the extended EVE session is saved in a 
{\it global section file}. A global section file can be thought of as a
snapshot or copy of a section of memory saved  as a binary diskfile.
In this case it is the modified copy of EVE. For a more theoretical 
discussion of global section files the reader is referred to the 
{\it System Services} Manual. The {\tt Save} command will prompt for a
file to save the EVE environment in. You should give a complete file
specification (device, disk) to avoid ambiguities. Also by convention
all EVE global section files have the file extension of {\tt gbl}
[V4.2 {\tt TPU\$SECTION}].
EVE should come back after a save telling you the number of functions,
and keys saved. The next time you
wish to use EVE, you can access your new EVE global section file by
two different methods. Either redefine the EVE symbol so that the
section file named is your section file or explicitly type in:
{\tt eve/sec=dev:[dir]myfile.gbl}. Suppose you have functions which you
use rarely, and you would like to avoid having them around most of time
so as to optimize the startup time of EVE. EVE can interpret TPU
functions at runtime. Whenever you decide that these functions are
needed for a given EVE session, type in the command:
\begin{verbatim}
eve/command=my_function_file.ext  filename
\end{verbatim}
Of course interpretation is expensive, so if you plan to use functions
often it is better to save them in the global section file. 

\section{EVE and DCL}
We have supplied three different keys accessing DCL
while in EVE. The Spawn [KP-9 White] allows the user to spawn out
of EVE to DCL. While in the subprocess you can give any DCL command. You
can even edit the same file you were editing when you spawned! Of course
it will be the file as it appears on disk since the other editing changes
haven't taken effect yet. Logging out will return you to the editing 
session. The Spawn/Mail [KP-9 Yellow] will spawn and invoke mail. This
is useful in those cases where you wish to check incoming mail without
leaving your current editing environment. Upon exiting from mail, you 
are returned to the edit session. The Spawn/DCL [KP-9 Red] allows one
to give a DCL command from within EVE. The output from any given DCL
command is trapped into a buffer named {\tt DCL}.
Suppose you wanted to include all the names of the files in a given
directory into the file you were editing. After the Spawn/DCL directory
command was given you could easily merge [KP-Enter Red] the DCL buffer
into the current buffer. {\bf Warning:} do not use
Spawn/DCL for DCL commands which generate non-terminating output.
An example of such as command would be {\tt monitor process/topcpu}.
The reason for this is that a spawn passes control of the terminal to
the subprocess. If the subprocess never ends control will never 
return to the main process, and anything typed in (including ctrl-Y)
is never picked up by the terminal driver.

\section{Recovering an EVE edit session}
EVE like other editors has the
capability to journal and recover a lost edit session due to system
crashes, ctrl-Y, and process termination or suspension. To recover an
edit session type in :
\begin{verbatim}
$ eve/recover filename.ext
\end{verbatim}
If you leave off the extension EVE will tell you that such a file doesn't
exist, prompt you to continue recovery. If you answer {\tt yes}, the 
recovery is done in a buffer without the extension. An EVE journal file
has the following name : {\tt filename.tjl}. If you attempt to recover
specifying the journal file, EVE will attempt to recover the journal
file using the journal file, discover the mistake and ask you if it's
ok to continue trying. If you answer yes, EVE will create a new buffer
with the name of the file given without an extension and recover the
journal file into it resulting in a mess. Again, specify the filename
to be recovered, not the journal filename extension. EVE like EDT will
journal your entire editing session transparently without any 
interruptions. You can vary the rate of journaling in EVE with the 
Set Journal command [KP-9 Blue]. Thus if the system is erratic and you
fear losing part of your edit session, you may wish to increase the rate
at which the buffer to the journal file is flushed. Of course this will
degrade the overall turnaround time for the editor the faster you
journal. For more information see the appendix on this key. There might
be times when during a long edit session with many changes you would like
to divide your edit session into several sessions, and later decide which
changes were really needed. You can use the {\tt Open Journal}, 
and {\tt Close Journal} commands. Closing the journal file effectively
{\it flushes} the terminal type-ahead buffer.
When you close a journal file, your session is no longer recoverable from
that point forward until you reopen another journal file. When you
open a journal file EVE will prompt you for a name to use for the new
journal file.

\section{Advanced Commands and Interfaces}
Eve has several commands which were never 
available in the standard EDT. There are misc. buffer and window 
commands manipulations you can perform. You can even {\it print} the 
current buffer or screen without ever leaving EVE. There are misc.
column editing routines which allows one to select, cut, and paste 
columns in a file, shift columns, and interchange columns. For more
information the user is referred to the {\it EVE Keypad Commands}, and
{\it EVE Auxillary Commands}. There is a hook from EVE into
LSE, allowing one to toggle between EVE and LSE (Language Sensitive Editor).
LSE is a DEC product which allows one to compile, review, and correct
syntax errors. Thus one could type in some program lines in EVE, enter
LSE to eliminate syntax errors, return to EVE and type in the next
routine or module. For more information on LSE contact the systems group.
You can interface with EVE from the mail facility, and from the debugger.
If you setup the symbol {\tt edit} to have the same definition as EVE, then
while in mail you can invoke the editor to send messages with the :
MAIL$>$send/edit or reply/edit command. These commands will invoke the EVE
editor. Upon exiting from EVE (ctrl-Z), the mail is sent and you are returned
to the mail level prompt. In order to invoke EVE from the debugger you
must first define a logical: \$define dbg\$init util\_root:[eveplus]debug.com.
This initialization file will setup the debugger so that when you enter:
DBG$>$ edit , you will automatically be placed inside the EVE editor using
the source code for the program being executed (i.e. EVE assumes the source
file has the same filename as the file being executed). This feature allows
one to execute a program in the debugger, correct a mistake in the source
code via EVE and then returning to the debugger to continue execution.

\section{EVE Futures}
Since EVE through TPU is DEC supported, we will provide
local support for our version of EVE. If the user discovers errors, in
the functionality of EVE they should report it to the systems group.
Also if they would like to see a function included in the next version of
our EVE, and interest in such a function is widespread they should 
submit the suggestion. For that matter if the user has written a function
which he/she may feel would be of value to others, please submit it and
it will be considered for incorporation into the next version.
New functions as they become available will be placed in: {\tt util\_root:
[eveplus]}. These functions if not already incorporated into EVE may
be used to extend EVE as explained above. Also in this directory is
the file: {\tt evenotes.txt} which contains the latest information and
bug fixes to EVE. An experimental version will be available under the global
section name of {\tt eveplusx}. This experimental version may have 
interesting new functions being added or being considered, but it will be
as it name implies {\it experimental}. 

\section{Summary}
The EVE editing interface described herein provides the user
with a more powerful and elegant editing environment than previously
available through other editors. Since the top two levels or keymaps are very
simular to EDT, most EDT users should find the learning curve to be short.
EVE can be easily modified or extended by the user to their own style.

\chapter{EVE Keypad Commands} %@label(Key Bindings)
\section{White Keypad}
\begin{description}
\item[{Shift Key [PF-1]}] Shift or toggle to the next or previous
keymap. The keymap
name appears in the status line at the bottom of the screen. 
By default EVE will return to the {\tt white\_map} after a command is
executed. If the user is on a VT200 terminal, and wishes to remain 
in a given map, then they should enter {\tt ctrl-?}. 
This key will toggle the user between lock and unlock
in a given keymap. Hitting this key again will unlock the current map
feature. When a map is locked the user remains in the current map level
after a subsequent key is hit, instead of returning to the white map.
You can still toggle to another map using the PF-1 key while in the locked
state. Example: Toggle to the blue\_map using the PF-1 key, and enter
{\tt ctrl-?}. Strike a key on the keypad. You remain in the blue map. Toggle
to another map, using the PF-1 key. Hit any key, and once again you remain
in the current map. Hit {\tt ctrl-?} (unlock), and then a keypad key. EVE
will now return you as before to the white\_map.
Those VT100 users wishing to have this functionality may bind the function
{\tt eve\_lock\_map} to the key of their choice.
When you toggle to another keymap, the status line is updated. If there are 
multiple windows on the screen only the buffer you are currently in is
updated. The status line for the other window will be updated when you
toggle or return to that window.

\item[{White Help [PF-2]}] Display the keypad diagram for the White-Yellow
keymaps.

\item[{Find Next [PF-3]}] Find the occurance of a string. Prompts
for string. EVE will search in the current direction and if the 
string is not found, it will then reverse the direction of search.
If you hit the key again instead of entering a string, it will
search for the next occurance of the previous search string entered
for this command. You can also recall the string entered for the find
command by hitting PF-3, and then the up arrow. This enables one to
recover from spelling errors.

\item[{Delete Line [PF-4]}] Delete the current line.

\item[{Page [KP-7]}] Find and goto the next page or formfeed in the buffer.

\item[{Section [KP-8]}] Advance or backup one screen of text.

\item[{Spawn [KP-9]}] Spawn into a subprocess outside of the editor. While
in the subprocess any valid DCL commands may be given. Upon logging
out control of the process is returned to EVE.

\item[{Delete Word [KP-Minus]}] Delete current word.

\item[{Advance [KP-4]}] Set current direction to Forward.

\item[{Backup [KP-5]}] Set current direction to Reverse.

\item[{Cut [KP-6]}]. Cut the selected range into the {\tt insert here} buffer.

\item[{Delete Character [KP-Comma]}] Delete current character.

\item[{Word [KP-1]}] Advance or backup one word.

\item[{EOL [KP-2]}] Goto the end of the current line.

\item[{Other Window [KP-3]}] Position cursor to the other window on the
screen. If only one window is present a warning is given by EVE and
the command is aborted.

\item[{Line [KP-0]}] Advance or backup one line positioning the cursor at the
beginning of the line.

\item[{Select [KP-Period]}] Select the beginning of a range in the current buffer.

\item[{Get Buffer [KP-Enter]}] Prompts for a buffer name and places it in the
current window, unmapping the current buffer from the window. 

\end{description}

\section{Gray Keymap}

Note. This keymap is a special keymap which appears only when you are in
the buffer by the name of {\tt List Buffer} (see BLUE KP-8). It replaces 
the {\tt White Keymap} when in this buffer. The functionality of the 
{\tt Grey Keymap} is like that of the {\tt White Keymap} except for 
the following two keys:

\begin{description}
\item[{Select Buffer [KP-Period]}] Select the buffer the cursor is pointing
to in the {\tt List Buffer} buffer. Map the buffer to the window and position
the cursor to it.

\item[{Destroy Buffer [KP-6]}] Destroy the buffer the cursor is pointing to
in the {\tt List Buffer} buffer. Buffer is unmapped from the window or
screen, and previous buffer associated with the window is revealed. This
command is destructive, once a buffer is destroyed, it can not be
retrieved.
\end{description}

\section{Yellow Keymap}

\begin{description}
\item[{Yellow Help [PF-2]}] Display a diagram of the EVE Yellow-Red keypad.

\item[{Define Key [PF-3]}] Define a key for this edit session. Will not be
saved for next EVE session unless EVE is extended and saved. It will 
prompt for the EVE command and ask for a {\tt keymap}. By default if the
key to be entered is a keypad key the function will assign the key to
the current keymap you are on. If you are defining a non-keypad key,
it will default to the {\tt eve\$user\_keys} keymap. If a non-keypad key
has a binding in the White, Yellow, Red, or Blue keymaps the user will
be informed that the key has a previous binding, and asked if it's ok
to proceed. If the answer is {\tt yes} then all previous bindings are 
wiped out and the users' function is bound to the key. Without this 
mechanism the user definition would never be hit if it were to be placed
in the default {\tt eve\$user\_keys} keymap. After deciding where it should
go, eve\_define\_key will prompt for a key stroke, function to be bound, and
a short description of the key-function. 

\item[{Undelete Line [PF-4]}] Restore last line deleted.

\item[{Command [KP-7]}] Prompt for an EVE command. If you use to enter a 
TPU command enter {\tt TPU}. It will then prompt for a TPU command.

\item[{Fill [KP-8]}] Fill or pad paragraph with blanks, even up right margin.

\item[{Spawn/Mail [KP-9]}] Spawn into the Mail facility. Upon exiting
mail with a ctrl-Z control is returned to EVE.


\item[{Undelete Word [KP-Minus]}] Restore the last word deleted.

\item[{Bottom [KP-4]}] Goto the bottom of the current buffer.

\item[{Top [KP5]}] Goto the top of the current buffer.

\item[{Paste [KP6]}] Paste the {\tt insert here} buffer before the current cursor
position.

\item[{Undelete Character [KP-Minus]}] Restore the last character deleted.

\item[{Change case [KP-1]}] Change the case of the current character, or
if the {\tt select} is active in the current buffer, then the case of
all characters in that range is changed.

\item[{Delete EOL [KP-2]}] Delete the EOL character.

\item[{Two Windows [KP-3]}] Create two windows on the screen. The current
buffer is duplicated into the
second window. If two windows are present the screen is toggled to one
window displaying the current buffer in the one window. The other buffer
is unmapped with the other window from the screen.

\item[{Goto Line Number [KP-0]}] Prompts for a line number and positions the
cursor to that line in the buffer.

\item[{Print Buffer [KP-Period]}] Print the current buffer. This key will
write the current buffer to a file with the same name, spawn with a
DCL command to print the filename just created.

\item[{Write Buffer [KP-Enter]}] Write the current buffer to a file. If the
buffer was created during the edit session, as opposed to being a file
brought in, then EVE will prompt for a filename. If you enter a $<$CR$>$
then EVE will write out the file using the default buffer name as the
filename. As with all commands in EVE, to abort this command hit ctrl-C,
followed by a $<$CR$>$.

\end{description}

\section{Red Keymap}

\begin{description}

\item[{Red Help [PF-2]}] Display the keypad diagram for the Red-Blue keymaps.

\item[{Set Mark [PF-3]}] Set a place marker in the current buffer. After going
elsewhere in the buffer you can give the {\tt Goto Mark} command to return
to the place marker. EVE will prompt for a marker name, thus you can have
several markers active at the same time. If you enter a marker name which
already exists then the name is associated with the new marker.

\item[{Number Lines [PF-4]}] Number the current buffer with line numbers. This
is a permanent change to the buffer if the {\tt un-number} command is not
used.

\item[{Extend TPU [KP-7]}] Extend the current session with the changes made
to the EVE image.

\item[{List Commands [KP-8]}] List the EVE commands available to the user. It will
sort the list before displaying them. Hitting the {\tt Do} key unmaps the
commands from the screen.

\item[{Spawn/DCL [KP-9]}] Prompts for a DCL command and spawns with it.
{\bf Warning}-- do not give a command which creates a loop like output
activity (e.g. Monitor). When the process is created the terminal is
disconnected from the editor session until the subprocess terminates. 
Thus if the subprocess never terminates the terminal is never reconnected
to the editing session. You must use the straight {\tt Spawn} command
described in the white keymap for non-self terminating subprocesses.

\item[{Close Journal [KP-Minus]}] Close the current EVE-journaling file. 
After closure the journal or recovery file is no longer updated for the
editing session. This command in conjuncture with the {\tt Open Journal}
command is useful when the user wishes to have several journal files for
a long edit session.

\item[{Message Buffer Down [KP-4]}] Display the next line of the message
buffer in the information window at the bottom of the screen. This
command allows the user to advance through the message buffer without
having to display the buffer on the screen.

\item[{Message Buffer Up [KP5]}] Display the last line of the message buffer
in the information window at the bottom of the screen. This command allows
the user to backup through the message buffer without having to display
the entire buffer on the screen.

\item[{Cut Rectangle [KP-6]}] Excise the rectangular section of text previously
selected into the {\tt insert here} buffer. Blanks are used to fill in the
section removed in the buffer.

\item[{Translate Non-Printable Ascii Characters [KP-Comma]}] Translate all
non-printable ascii characters in the current buffer. The translated 
buffer is mapped to a second buffer. This command can be used to see
which non-printable characters are present. This translated buffer can
be written out to a file and printed.

\item[{Substitute [KP-1]}] Substitute new string for old string. Prompts for
both strings. If an occurance is found it will prompt {\tt Replace? Type
yes, no, all, last, quit}. {\tt All} will replace all strings in the buffer,
while {\tt quit} will abort the substitution. A $<$CR$>$ is the same as 
answering {\tt yes}. For either a $<$CR$>$ or {\tt yes}, the substitution is made
and the next old string is found in the file. EVE will then ask if you
wish to substitute for this string, and so forth until all of the old
strings have been found.
If the old string is not found in the current direction,
EVE will look in the reverse direction. If it is found in the reverse of
the current direction you will be asked if you wish to go to that occurance
in the buffer.

\item[{Center Line [KP-2]}] Center the current line in the buffer. 

\item[{Get File [KP-3])}] Prompts and retrieves a file into the current window.
The current buffer is unmapped from the window and a new buffer is created
and mapped to the window. The new buffer will have the same name as the
filename.

\item[{Trim Line [KP-0]}] Trim the current line. Get rid of all trailing
{\tt whitespaces} (i.e. blanks, tabs, etc). After trimming a line, the
cursor is placed at the end of the line.

\item[{Select Rectangle [KP-Period]}] Select a rectangular cut. After hitting
this key, move the cursor horizontally with the (-$>$) arrow key. After 
reaching some column N, then move the cursor in the current direction
usually vertically downward to row M. Upon hitting the rectangular
cut key (RED KP-6), you will have deleted a rectangle with the area of NM.
For example to delete one column in a table: Hit RED KP-Period, move 
horizontal 1, and down to the bottom of the file. Hit RED KP-6 and the
column is removed.

\item[{Merge Buffer [KP-Enter]}] Prompts for a buffer. If the buffer does not
exist it will attempt to find a file by that name in the current default
directory. If either is found it is merged or included before the current
cursor position in the current buffer. Note: if you are in overstrike
mode the text being placed in the buffer will overwrite previous text.

\end{description}

\section{Blue Keymap}

\begin{description}

\item[{Blue Help [PF2]}] Display the keypad diagram for the Blue-White Keymaps.

\item[{Goto Mark [PF-3]}] Goto the place marker indicated in the current buffer.

\item[{Un-number Lines [PF-4]}] Strips off line numbers previously placed in
the buffer by {\tt Number lines} (RED PF-4). {\bf Warning}: If you un-number
a buffer which is not numbered, and the buffer contains numeric text,
unpredictable results may occur, and the numeric text will be lost.

\item[{Save TPU [KP-7]}] Save the extended EVE session in a global section file.
It will prompt for the name of the file to be created. Standard convention
is to create the file with the extension of {\tt .gbl} [{\tt .TPU\$SECTION}].

\item[{List Buffers [KP-8]}] List all available buffers for the current EVE
session. The {\tt select} key is temporarly bound to {\tt select buffer}, and
the {\tt remove} key is temporarly bound to {\tt destroy buffer} This allows
one to select or destroy buffers by positioning the cursor to the beginning
of the buffername and striking either the {\tt select} or {\tt remove} key.
Example: position the cursor at a buffer name, hit the
VT200 select, and that buffer is mapped to the window. After exiting the
list\_buffers buffer, the original definitions for the {\tt select}, and
{\tt find} key will be restored.           

\item[{Set Journal [KP-9]}] EVE will request a number in the range of 
1-10. By default the journal file has a value of approx. 10 which causes
a record to be written to the journal buffer every 125-400 keystrokes. A value
of 1 causes a record to be written every 10-35 keystrokes. These values are
approx. and can differ depending on the type of editing being performed.
The lower the value the safer you become in restoring more of your EVE
session in case of catastrophic events, but it will also slow down your
turnaround time inside EVE due to the I/O.

\item[{Open Journal [KP-Minus]}] Open a new journal file. If one is already
open EVE will give an error message. It will prompt for a journal file
name, with the default name given {\tt tpu.tjl}. 

\item[{Left Margin [KP-4]}] Set left margin in buffer at the current cursor
position.

\item[{Right Margin [KP-5]}] Set right margin in buffer at the current cursor
position.

\item[{Paste Rectangle [KP-6]}] Paste the rectangular area previously selected
and cut to the current cursor position. Any text present at this location
is destroyed after the paste. 

\item[{Display Ascii [KP-Comma]}] Display the ascii value for the current
character in the buffer (e.g. the character the cursor is positioned on).
By default EVE displays all non-printable ascii characters as an upside
down inverted question mark for VT200 terminals and a checkered square for
VT100 terminals.

\item[{Draw Box [KP-1]}] Draw an outline for a box in the area selected. 
Example: hit the rectangular select key (RED KP-Period), move the 
cursor over and down to create a select area. Upon hitting KP-1 a
box appears outlining the area selected.

\item[{Transpose Characters [KP-2]}] Transpose the two characters before the
current cursor position. Example : Teh$\uparrow$ [KP-2] The$\uparrow$ (``$\uparrow$'' is the cursor position).

\item[{Set Screen Width [KP-8]}] Set screen width will prompt for a screen
width number. The number entered must be in the range 1-132. If a number
outside this range is entered, the function returns an error message. 
If a $<$CR$>$ instead of a number is entered the screen will toggle between
80-132 depending on the current screen width. If the current screen width
is 80 a $<$CR$>$ will toggle the screen to 132. Any other current screen width
toggles the screen to 80. Although the screen width may change the current 
window(s) will not change. Therefore
if the screen width is changed from 80 to 40 the last 40 columns of the
current window will not be displayed. This command is most useful in
changing the screen width to view compiler listing files (132).

\item[{Trim Buffer [KP-0]}] Remove trailing whitespaces through out the current
buffer.

\item[{Specins [KP-Period]}] Prompts for Decimal Ascii value in the DEC 
Multinational character set  to be entered into the text.

\item[{Destroy Buffer [KP-Enter]}] This command will prompt and destroy the
buffer indicated. Memory inside EVE is freed for other use. Once a 
buffer is destroyed it can not be restored.
\end{description}

\section{Main Keyboard Keys}
EVE defines several main keyboard keys so as to
allow line edit mode emulation. The following is a list of the keys
defined. It is recommended that the user read page 4-57 in the TPU
manual before defining keys. It is also recommended for key definition
convention that all user defined keys be explicitly placed in the 
keymap {\tt eve\$user\_keys}. 
\begin{description}
\item[Control-A] Quit current EVE session.

\item[Control-B] Recall last TPU/EVE command.

\item[Control-E] Position cursor to EOL.

\item[Control-F] Forward/Reverse.

\item[Control-H] Position cursor to beginning of line.

\item[Control-M] Return.

\item[Control-R] Repeat the next command {\tt N} times.

\item[Control-V] Change mode between insert and overstrike.

\item[Control-W] Refresh screen.

\item[Control-X] Erase from cursor to beginning of line.

\item[Control-Z] Exit and save EVE edit for current buffer.

\item[Control-?] Lock or Unlock the current keymap. See PF-1 key above.

\item[DO-up\_arrow] Toggle back through command buffer.

\item[DO-down\_arrow] Toggle forward through command buffer.
\end{description}

\section{VT200 Auxillary-Keypad Keys}
These keys are located on VT200 terminals
between the main keyboard keys and the main keypad keys. They are labeled:
{\tt find, select, Prev Screen,} etc. Their functions are as they
are labeled, except under the special condition of the {\tt list buffers}
command (as discussed above for Blue KP-8).

\section{VT200 Function Keys}
Various function keys on the keyboard have been
defined which gives the VT200 user convenient usage of some common
functions, and also additional functions not available on the keypad.

\begin{description}

\item[{Control-Y [F6]}] Interrupts edit session.

\item[{Spawn [F8]}] Spawn to DCL level.

\item[{Spawn/Mail [F8-Yellow\_map]}] Spawn into mail.

\item[{Spawn/DCL [F8-Red\_map]}] Spawn with a DCL command.

\item[{LSE [F9-White\_map]}] Invoke LSE from within EVE. The current buffer
is written out. The process is spawned and LSE is invoked using the
buffer name as the filename. Upon exiting from LSE a new copy of the
buffer is brought into EVE.

\item[{Spell [F9-Yellow\_map]}] Invoke the Vasar speller correction program
on the current buffer.

\item[{Describe Key [F10]}] Describe a key, return the keys' comment field.

\item[{Change Direction [F11]}] Change direction of edit forward/reverse.

\item[{Move by Line [F12]}] Move line by line.

\item[{Erase Previous Word [F13]}] Delete the previous word before the cursor.

\item[{Change Modes [F14]}] Toggle between insert and overstrike.

\item[{Select Rectangle [F17-White\_map]}] See rectangular select [Period Red\_map].

\item[{Rectangular Cut [F17-Yellow\_map]}] See rectangular cut [KP-6 Red\_map].     

\item[{Rectangular Paste [F17-Red\_map]}] See rectangular paste [KP-6 Blue\_map].

\item[{Copy\_buffer [F18-White\_map]}] Copy buffer A to buffer B.

\item[{Ruler [F18-Yellow\_map]}] Place a ruler at the top of the current buffer.
If a ruler is already present then it's removed.

\item[{Move\_Columns [F18-Red\_map]}] Switch or move two columns in a buffer.

\item[{Rectangular-Pad [F18-Blue\_map]}] Pad or place blanks before a given
column in a file, causing it to shift to the right.

\item[{Grow\_Window [F19-White\_map]}] Allow the current window to grow by
one row.

\item[{Shrink\_Window [F19-Yellow\_map]}] Shrink the current window by one
row.

\item[{Print\_screen [F19-Red\_map]}] Print the current contents of the screen
to a line printer.

\item[{Next\_buffer [F19-Blue\_map]}] Goto the next buffer in the buffer list.
Map it to the screen.

\item[{Two Windows [F20]}] See two\_windows [KP-3 Yellow\_map].
\end{description}

\chapter{EVE Auxilliary Commands} %@label(New Commands)
{\bf EVE\_function\_name} [filename function is located in]
\begin{description}
\item[EVE\_append\_buffer] [APPEND.TPU] Append a select range (if present)
or buffer to another buffer. If a select range is not active it is assumed
another buffer is to be appended and is prompted for. If the buffer to
append doesn't exist then an error is returned. If the buffer to be
appended to doesn't exist then it's created. This function uses the help
function EVE\_exist\_buffer which requires 3 args: loop\_buffer
(a buffer variable), found\_buffer (integer), and this\_file (a string
specifying the filename). Returns a ``1'' in found\_buffer if the buffer exists,
else a ``0'' is returned.

\item[EVE\_copy\_buffer] [COPYBUFF.TPU] Copies one buffer to another. Prompts
for the two buffer names, and then calls the help function eve\$copy\_buffer
(oldbuff,newbuff), where both args are strings. If the orgin buffer doesn't
exist then an error is returned. If the destination buffer exists it is
erased and the orgin buffer is copied to it. If it doesn't exist then it
is created before the copy.

\item[EVE\_grow] [SHRINK\_GROW.TPU] Add one line to the current window.

\item[EVE\_lse] [LSE.TPU] Hook function into LSE. Spawns into LSE with the
current buffer (file) name. Both ends (EVE and LSE) write out the file
so as to ensure the corrected version is being used.

\item[EVE\_move\_column] [MOVECOLUMN.TPU] Prompts for two column numbers M and N.
It then switches columns M and N in the file. It will handle irregular
alignment on the right hand side of columns. If the left hand side is
irregular data sticking out from the starting column (of the column) is
truncated or lost. Example. If the first item in a column is 5 chars, and the
next is 15 and the next is 8 then for the 3 lines length would be: 5 chars,
5th-15th char (or 10 chars) , 5th-8th char (3 chars). Help functions in this
file include : eve\_traverse\_column, eve\_skip\_column, eve\_skip\_white\_space,
eve\$find\_column.

\item[EVE\_next\_buffer] [NEXTBUFFER.TPU] Find the next buffer in the internal
buffer list and map it to the current window. This function does not 
differeniate between user and system buffers.

\item[EVE\_pscreen] [PRINTSCREEN.TPU] Print the current screen to a line printer.
It selects and copies the screen lines to printscreen.scr. If this buffer
doesn't exist then it's created. The function then calls eve\_print\_buffer.

\item[EVE\_rectangular\_pad] [RECPAD.TPU] Insert Y blanks before a column for
X  lines. Activate the rectangular select function. Move the cursor Y spaces
to the right and X lines down creating the typical area. EVE\_rectangular\_pad
will compute the number of blanks to be inserted is equal to the end\_column-
start\_column. This many blanks will be inserted before the start position.

\item[EVE\_ruler] [RULER.TPU] Places a column ruler at the top of the current
window. If the ruler is already present, then it's removed. The ruler length
will adjust so that it corresponds to the current screen width.

\item[EVE\_searchctrl] [SEARCHCTRL.TPU] Prompts for a decimal ascii value, and
finds that ascii character in the file. This enables one to search for ctrl-
characters.

\item[EVE\_shrink] [SHRINK\_GROW.TPU] Subtract or shrink the current window by
line one.
\end{description}
\end{document}
