Sedt Users Guide
Version 2.0
Sedt Users Guide
Screen EDiTor Version 2.0
Sedt is an interactive "what you see is what you get"
editor for VAX/VMS and the Rainbow 100 under CP/M version 2.0 or
MS/DOS version 2.05. Sedt key definitions are soft and can
easily be redefined to suit personal preferences. For
compatibility Sedt is distributed with key definition files that
implement sub/supersets of EDT and Gold keypads.
Sedt is not just a reimplementation of EDT, but contains
a great number of extentions and offers a superior level of
performance. EDT compatibility is designed to offer easy
transition to Sedt. Most users choose to use Sedt on all
operating systems. Sedt has been integrated under ALL-IN-1 V.1,
Mail, Nmail and, of course, DCL.
Although Sedt is not designed as a word processor it
contains most word processor functions that can be implemented
without imbedding tokens. Sedt implements sophisticated text
fill/justification and automatic margin control. With a post
processor such as TXTF or Runoff Sedt will satisfy almost
anybody's word processing requirements.
Page 1
Sedt Users Guide
Version 2.0
Getting Started
Sedt is called with the command line:
SEDT { } {} {-} {-j} {-e} {-b}
and are optional file
names. If only one file name is given, it will be
assigned to both the input and output files. Sedt will
read the input file into buffer number 0 and set the
default output for buffer number 0 to the output file.
is an optional line number at which Sedt
will position the cursor after loading the input file.
-j will disable the generation of a journal file
when editing. The journal file is automatically invoked
if it exists when a new file is edited. -j will
typically be used to improve performance when editing
from a floppy disk.
-e will make Sedt terminate files written with a
Control Z (SUB). This is used to generate files for
applications that require this terminator.
-b will disable the generation of a backup file
when writing files. This is typically used when editing
with limited disk space available. This is not
encouraged because you can end up with no file at all if
disk space runs out before the write is completed.
The initialization sequence for Sedt is as
follows:
On non-PC versions determine the terminal
type.
Load the input file and display the file
on the screen.
Load a key definition file (CP/M and
MS/DOS: Sedtkeys.Txt. VMS: Sedt$Keys:). Sedt
will abort if it cannot find the key definition
file.
Load a default ruler file (CP/M and
MS/DOS: Ruler0.Txt. VMS: Sedt$Dir:Ruler0.Txt).
If no default ruler file is found, Sedt will set
up a standard ruler with tab stops at every 8
columns and margins at column 1 and column 80.
If the user has supplied an optional
Page 2
Sedt Users Guide
Version 2.0
starting line number in the command line, Sedt
will position the cursor at the specified line.
Look for an initialization file on disk
(CP/M and MS/DOS: Sedtcom.Txt. VMS:
Sedt$Commands:). If the initialization file is
found Sedt will read all the input in the file
and execute them as basic Sedt commands.
Look for a journal file with the same
name as the input file except for the file
extention .JOU. If the journal file is present
Sedt will read all characters in the journal file
as if they had been typed on the keyboard. Sedt
will create journal files for all files edited
and remove the journal files when the file is
written to disk or the user quits the edit
session. Journal files will not recreate the
correct file if you have moved data between
windows. Window changes and spawns to the
operating system are disabled when recovering.
Text is entered at the cursor position. Deletion of any
character is done by placing the cursor to the right of
the character and typing Delete. The cursor can be moved
around the text by using the cursor keys. At the end of
the session Gold F or Exit will save the file and exit
from Sedt.
Page 3
Sedt Users Guide
Version 2.0
Screen layout
The Sedt screen is divided into a number of fields. It
can display either one or two windows into your edit buffers. In
single window mode the layout is as follows:
The top line on the screen (in reverse video) is a status
line. It shows you the contents and status of your current
buffer.
The first character on the status line indicates
whether there have been changes to the file in the
current edit buffer. An * indicates that changes have
been made, a space that the file is unchanged.
The second field indicates what the output file
for the current buffer is. The contents of the buffer is
initially the disk contents of the input file.
The third field on PC implementations
(Column=) tells you what column the cursor is
positioned at.
The third (fourth on PC implementations) field
(Line=) tells you what line number in the buffer
Sedt is positioned at,
The final field (Buf=) tells you the
number of the current buffer.
The second line is the ruler line. It shows the current
settings of left and right margins, the word wrap margin and the
tab stop settings. L is the position of the left margin, W the
position of the word wrap margin if fixed, A the position of the
word wrap margin if automatic, R the position of the right margin
with ragged right margin, J the position of the right margin with
right justified margin, I the current indentation setting, and T
tab stop settings. If a position marks several of the above it
will only show one. The order of precedence is W/A over L over
R/J over I over T.
The next 20 lines are in normal video and display a
window into the current buffer. All text is shown exactly as it
is and how will be written to the file. The cursor is always on
line 12 and shows the current position within the buffer. If a
select region is active the region between the select point ant
the cursor will be shown in reverse video.
The 23'd, or second line from the bottom, is in reverse
video and separates the text from the message line. This line
contains status information. The first indicator shows the
default direction for moves. The second whether typed characters
Page 4
Sedt Users Guide
Version 2.0
will be inserted or replace existing text. The last shows
whether Sedt is currently learning keystrokes or executing a
learned keystroke sequence.
The 24'th, or bottom line, is the message line. It is
used to display informational and error messages, and also for
accepting command arguments.
In two window mode a second status line is added on line
14. It has the same format as line 1 and shows the status of the
buffer displayed in lines 15 through 22. The current buffer is
displayed in lines 3 through 13. The Cursor position is always
on line 8.
Page 5
Sedt Users Guide
Version 2.0
Typing text
Text is entered at the cursor position by typing the
desired data. Text keys are all the printable ASCII characters
plus Return and Space. All other keys cause either an error
message or make Sedt execute a series of commands programmed into
the key. Sedt supports the full multinational character set,
either through compose sequences or through the country kits.
Sedt can be in either replace or insert move.
In replace mode typed text will overwrite existing text.
In insert mode (the default) the existing text will be moved to
make room for the typed. If a Tab character is replaced it will
be expanded to spaces before the replacement. The effect of this
is that text to the right remains unchanged. Replace/insert mode
is toggled with Gold O and is indicated on the mode line.
Tab will insert tab and space characters in the text and
position the cursor at the indentation setting (indicated with an
I on the ruler line) if it is to the right of the cursor,
otherwise at the next tab setting on the ruler. Note that the
tabs are soft tabs set by default at columns 9, 17, etc.! Sedt
assumes that the hardware tabs are set at eight character
intervals at the default positions. Using soft tabs means that
text can be tabulated at any column independently of the hardware
tab stops, and will print correctly on most printers.
Return will insert an LF (ASCII 12) character in the text
and place the cursor at the appropriate left margin. If you wish
to search for a string including a new line insert an LF (F13 or
^J) in the search string. When the file is writtenm to disk the
LF will be replaced by the correct line terminator for the
operating system.
Gold Keypad 0 will insert a new line in front of the
current cursor position. No indentation will be done.
To insert an arbitrary ASCII character enter Gold, the
decimal value of the character and Gold Keypad 3.
Typing Escape twice, or F11, will insert an escape
character in the text.
If the end of line is to the right of the physical screen
margin, Sedt will display a reverse video > in the rightmost
column.
Page 6
Sedt Users Guide
Version 2.0
Commands
Commands are coded into ASCII control characters and the
function keys on the keyboard.
PF1 (Gold) has a special meaning. It does not cause any
commands to be executed, but modifies the effect of the next key
to be typed. When in this text the term Gold is used before a
key it means that you have to type PF1 before typing the key.
Gold also causes the normal ASCII characters to be modified to
execute Sedt commands instead of entering text.
Some commands require arguments from the keyboard. These
commands will prompt for the argument and wait for you to type it
in. As you type the argument it is echoed at the end of the
prompt on the message line. Argument entry is terminated by
typing Return, Do or Enter. Mistakes can be corrected by moving
the cursor with the Right and Left Arrow keys and deleting a
character at a time with Delete (above Return) or inserting
characters at the cursor position. The entire command can be
cancelled by typing Control U.
Most commands can be repeated by typing Gold, inputting
the number of times the command should be repeated, and the key
sequence for the command. While entering the number you see it
echoed on the message line. Mistakes can be corrected by typing
Rubout to delete a character. Entry of the number can be aborted
by typing Control U.
Most direction dependent commands can have the direction
set by entering Gold + or Gold > for forward, or Gold - or Gold <
for reverse before typing the key. After typing Gold + or Gold -
you can enter a count exactly as described above.
If you have entered a partial command but do not wish to
continue, you can type one of the dead keys: Resume, Enter or
Main Screen.
Page 7
Sedt Users Guide
Version 2.0
Help
To get help within an edit session type Gold H, Help or
PF2. Sedt will display a help screen and ask you whether you
want to see the next help screen. Typing Return will display the
next help screen. Typing Space will return to the edit session.
The help text is found in a disk file (CP/M and MS/DOS:
Sedthelp.Txt. VMS: Sedt$Help:). If the help file cannot be
found an error message will be displayed.
Return or Next Screen will move you forward through the
help screens. Backspace or Prev Screen wil move you backward,
and space or Exit will return to the edit session.
Page 8
Sedt Users Guide
Version 2.0
Moving
The most simple moving commands to use are the arrow
keys. Left arrow moves the cursor one character backwards in the
text. Right arrow moves one character forward in the text. Up
arrow moves one line up and attempts to keep the cursor at the
same relative position within the line. If the line is too short
the cursor will be positioned at the end of the line. If the
character at the previous line has a representation longer than
one character (Tab or other control characters) the cursor will
be positioned at the end of the representation. Down arrow works
as up arrow, but moves one line down.
Previous Screen moves 10 lines up the text and places the
cursor at the start of the line. Next Screen moves 10 lines down
in the text and places the cursor at the beginning of the line.
Gold T moves the cursor to the top of the text. Gold B
moves the cursor to the bottom of the text.
More complicated moving commands are:
Backspace (F12) Moves to the previous beginning of line
* Find Moves to the next occurrence of the
current search string.
* Keypad 0 Moves to the next beginning of line.
* Keypad 1 Moves one word.
* Keypad 2 Moves to the next end of line.
* Keypad 3 Moves one character.
* Keypad 7 Moves one page.
* Keypad 8 Moves one paragraph.
* PF3 Moves to the next occurrence of the
current search string.
* Gold Find Moves to the next occurrence of the
current search string which is entered
as a command argument on the message
line. Entering an empty argument causes
Sedt to use the old search string.
Gold Up Arrow Moves to the top of the text.
Gold Down Arrow Moves to the end of the text.
Page 9
Sedt Users Guide
Version 2.0
Gold Keypad 4 Moves to the end of the text.
Gold Keypad 5 Moves to the start of the text.
* Gold PF3 Moves to the next occurrence of the
current search string which is entered
as a command argument on the message
line. Entering an empty argument causes
Sedt to use the old search string.
Keypad 4 Causes commands marked by * to move
backwards in the text.
Keypad 5 Causes commands marked by * to move
forward in the text.
Gold Left Arrow Scrolls continuously up through the text
until a key is typed.
Gold Right Arrow Scrolls continuously down through the
text until a key is typed. (Enter is
dead key)
To undo a move you type Gold U as the next command.
Page 10
Sedt Users Guide
Version 2.0
Marks
Marks are points in the text that you may want to return
to. You can mark a point in the text by entering Gold, the
number of the mark to be set, and Gold M. You can set mark
number 1 by entering Gold M.
To return to a mark you enter Gold, the number of the
mark, and . (dot). You can return to mark 1 by entering Gold .
(dot).
Valid mark numbers are in the range 1 to 10.
Page 11
Sedt Users Guide
Version 2.0
Deleting text
The character immediatly before the cursor position may
be deleted with Delete. The word immediatly before the current
position may be deleted with Line Feed (F13). The line up to
the current position may be deleted with Control U.
The character after the current position is deleted with
Keypad , (comma), the next word with Keypad -, and the next line
with PF4.
Gold Keypad 2 deletes up to the end of the current line.
To delete arbitrary text move to one end of the text and
enter either Select or Keypad ., then move to the other end of
the text and enter either Remove or Keypad 6. PF4 will append
the deleted text to the paste buffer.
Gold Remove will move the text between the current
position and the select point into the paste buffer, but will
not delete the text. This command is useful for copying text
from one position to another.
The select point may be cancelled with Gold Keypad .
(dot) or Gold Select.
It is not necessary to delete a character to change it's
case. Simply place the cursor over the character and enter Gold
Keypad 1. If a select point is active the whole select range
will change case, otherwise, if the last command was a search
command the found string will change case.
Page 12
Sedt Users Guide
Version 2.0
Undeletion
Any deleted text can be undeleted until a similar type
of text is deleted. Gold Keypad , (comma) undeletes the last
deleted character, Gold Keypad - undeletes the last deleted
word, and Gold PF4 undeletes the last deleted line.
Insert Here or Gold Keypad 6 undelete the paste buffer
which is filled with Remove, Gold Remove or Keypad 6.
Page 13
Sedt Users Guide
Version 2.0
Search and substitute
Gold Keypad 9 accepts a search and a substitute string
and replaces the next occurrence of the search string with the
substitute string. If an empty argument is entered either for
the search or substitute strings the old values will be used.
If the cursor is placed at the beginning of the search string
the substitution will be done if this occurrence.
Keypad 9 replaces the next occurrence of the current
search string by the substitute string. If the cursor is placed
at the beginning of the search string the substitution will be
done if this occurrence.
To undo a substitution type Gold U as the next command.
Gold U will insert the search string exactly as you typed it
after deleting the substitute string.
Page 14
Sedt Users Guide
Version 2.0
Edit buffers
Sedt can concurrently edit up to four different files.
Each file is contained in a buffer. One of these is the current
buffer on which all commands have effect. F17 to F20 change the
current buffer. F17 makes buffer 0 the current, F18 buffer 1,
F19 buffer 2, and F20 buffer 3.
Whenever F17 to F20 are entered Sedt will change into
two window mode with the previously current buffer contents
displayed in the lower window and the current buffer in the
upper window. If the current and previous buffer are the same
the lower window will not reflect changes in the buffer unless
the screen is refreshed with a Control W, which causes the two
window contents to become identical.
Page 15
Sedt Users Guide
Version 2.0
Windows
Gold D will toggle between one and two window mode. The
upper window always contains the current buffer and the lower
window the previous buffer.
Gold W will toggle between 80 and 132 column display
format.
Page 16
Sedt Users Guide
Version 2.0
Session control
Gold F causes the current buffer to be written to it's
output file. If all buffers have been written to disk Sedt will
exit. If there are still unwritten buffers Sedt will ask you
whether you intend to terminate the edit session without saving
the buffers.
Gold S is used to save the contents of the buffer in any
file and continue the edit session. The filename is accepted
from the keyboard. If no filename is entered the buffer is saved
into the buffer's output file.
Interrupt will save the contents of the buffer in the
output file if any modifications have been made to the buffer.
Gold E causes the current buffer to be loaded with a new
file. If the current buffer holds an unsaved file Sedt will ask
you whether you want to save the old file. If you confirm, Sedt
will save the old file in the output file before loading the new
file.
Gold Q or Cancel will terminate the edit session if all
buffers have been written to disk. If unsaved buffers exist
Sedt will ask for confirmation before exiting.
Gold Z clears the current buffer.
Gold G will load the contents of a file into the current
buffer at the current cursor position.
Control W will refresh the screen.
Page 17
Sedt Users Guide
Version 2.0
Word processing
The basic text formatting commands allow Sedt to be used
as a simple word processing system. The format is controlled
with the ruler displayed on line 2 of the display.
It is convenient to have commonly used rulers saved on
disk, ready to be used by typing a 4 character sequence. For
example, ruler 0 could contaiin a ruler with the margin at column
1, ruler 1 one with the margin indented one tab stop, ruler 2
with the margin indented two tab stops, and so on.
Gold R allows you to change the ruler. The cursor will
be positioned at the first column of line 2 after which you can
modify the layout with the following commands.
Right arrow Moves the cursor one character to the
right. The column number can be read on
the status line.
Left arrow Moves the cursor one column to the left.
- Removes a tab stop at the current
position.
Tab Moves to next tab stop
Backspace Moves to column 1
T Inserts a tab stop at the current
position
L Sets the left margin to the current
position. When a Return is entered the
cursor will be indented to the left
margin.
R Sets the right margin to the current
position. If the right margin is
reached when entering text, a new line
will be entered before the word being
typed and the word will be indented to
the word wrap margin.
J Sets the right margin to the current
position. If the right margin is
reached when entering text, a new line
will be entered before the word being
typed and the word will be indented to
the word wrap margin after adjustment of
the text to the right margin.
Page 18
Sedt Users Guide
Version 2.0
W Sets the word wrap margin to the current
position. W fixes the word wrap
position.
A Sets automatic margin control. The
margin is always the leftmost non-blank
position on the current line.
I Sets the indentation at the current
position.
Space Removes all formatting controls at the
current position.
Digit Load saved ruler number digit. The
rulers are saved in the directory
defined by environment variable Sedt
under MS/DOS and in the directory
pointed to by the logical name Sedt$Dir
under VMS. The name of the ruler file
is RulerN.Txt where N if the number of
the ruler.
Gold Digit Save current ruler in saved ruler number
digit.
Return Returns from ruler definition mode to
normal edit mode.
If more than one ruler setting is commonly used, much
time can be saved by storing the settings in rulers 0 through 9.
Ruler 0 is loaded by default and any of the other rulers can be
called up with four key strokes: Gold R Digit Return.
Gold Keypad 8 will reformat from the current position to
the end of the paragraph.
Gold C will center the text on the current line between
the left and right margins.
Gold P will insert a page mark at the current position.
Control P will print the current buffer on a file. The
file name is prompted for.
Gold _ will insert a - and a space and reformat the
paragraph. This command is used if a hyphenation will improve
the formatting of the paragraph.
Control T will adjust the text within the select range
by a tab stop. The direction of adjustment is determined by the
current direction or by entering Gold + or Gold - before control
Page 19
Sedt Users Guide
Version 2.0
T. By using a count with Gold Digit ..., you can adjust by more
than one tab stop.
Gold Enter will swap characters. Place the cursor over
the first character to swap. Typing Gold Enter will "pull" the
character to the right of the next character.
Additional Options will call the text formatting program
TXTF to produce a formatted file of type .LST. TXTF is in the
public domain and formats using wordstar type . commands.
Page 20
Sedt Users Guide
Version 2.0
Margin Control
The ruler line controls both left and right margins.
Several options exist for controlling the margins.
No margin control is done if L, W, R and I are set in
column 1. Lines can be infinitely long and the cursor is always
positioned in column 1 after a Return is typed.
If L is set in a column different from 1 and W is set in
column 1 a Return will cause Sedt to indent to the column
defined by L.
If I is set in a column different from 1 and the cursor
is positioned to the left of the column a Tab will indent to the
column defined by I.
The left and right margin controls work as follows:
W and R:
When a non-blank character is typed to the right
of R Sedt will insert a Return in front of the
first word that extends to the right of R and
indent to the W column. The effect will be that
text will be filled between W and R. The fill
command, Gold Keypad 8 will fill text from the
current cursor position to the end of the current
paragraph. Text to the left os W will be left
unaffected.
W and J:
When a non-blank character is typed to the right
of J Sedt will change the spacing between the
current position and W so that spacing after
punctuation characters will be exactly 2 and
after non-punctuation characters will be 1. A
return will then be inserted before the first
word that extends to the right of J, after which
spaces will be inserted between words until the
right margin is justified to J. Finally the
wrapped word will be indented to W. Text to the
left of W will be left unaffected.
A and R:
When a non-blank character is inserted to the
right of R a return will be inserted in front of
the first word that extends to the right of R.
The text after the return will be indented to the
same level as the line just terminated.
Page 21
Sedt Users Guide
Version 2.0
A and J:
When a non-blank character is typed to the right
of J Sedt will change the spacing between all
words to the left of the current position so that
spacing after punctuation characters will be
exactly 2 and after non-punctuation characters
will be 1. A return will then be inserted before
the first word that extends to the right of J,
after which spaces will be inserted between words
until the right margin is justified to the same
level as the line just terminated.
W to the right of, or at J/R:
No filling or justification will occur.
A to the right of or at J/R:
When a Return is typed the cursor will be
indented to the same level as the line just
terminated. If the terminated line is empty the
indentation level will remain unchanged. This
mode is particularly useful for structured
programming.
Page 22
Sedt Users Guide
Version 2.0
Programming
Control A will set the indentation level to the current
column. Typing a Tab to the left of the indentation level will
indent the cusor to the current level. Control D will decrease
the indentation level and control E will increase it. The
current indentation level is indicated on the ruler line with an
I.
If automatic margin control is in effect (an A is
displayed on the ruler line) a return will make Sedt indent the
cusor to the same level as the line just terminated.
Indentation of text can be changed to a tab stop with
the control T key, which will adjust the text either left or
right by a number of tab stops. To adjust text to the next tab
stop to the right enter Gold + control T. To adjust left type
Gold - control T. If you desire to adjust by more than one tab
stop type the number of tab stops to adjust after the Gold + or
Gold -.
Page 23
Sedt Users Guide
Version 2.0
Defining keys
Control K will allow you to define keys differently from
the default settings. When the Key: prompt appears type the
key you wish to define. When the As: prompt appears type the
definition of the key either by typing the sequence of command
keys to be executed or by entering the basic Sedt commands. If
the string is terminated with a . the key will take effect
immediatly when typed, otherwise it will be stacked up for
execution when a key with a . at the end of the definition is
struck.
Gold control I will insert a key definition into the
current buffer. When the Key: prompt appears type the key you
want to save the definition of.
Gold control L will load the contents of the current
buffer into a key definition. When the Key: prompt appears
type the key you want to load the definition into.
If you type Gold F17 Sedt will save subsequent
keystrokes for reexecution later. The save is terminated by
typing Control Z. To execute the saved sequence type Gold F18.
Be sure you do not type Gold F18 while saving keystrokes. If
you do this and execute the keystrokes later with Gold F18 Sedt
will loop endlessly. You can enter a count as with other
commands, but note that execution of learned sequences is not
stopped on errors.
Page 24
Sedt Users Guide
Version 2.0
Miscellaneous commands
Gold Keypad 7 or Gold Do accepts a string of basic Sedt
commands from the keyboard and executes them.
Gold X will execute basic Sedt commands from a file.
Sedt will prompt for the file name.
Do will spawn an operating system command. Sedt will
prompt for the command to be executed. Under VMS or MS/DOS an
empty string will spawn to the command language interpreter.
Upon return to Sedt you will be prompted for a character before
the screen is refreshed unless you spawned to the command
language interpreter.
Gold F4 will load the paste buffer from a file. Sedt
will prompt for the file name.
Page 25
Sedt Users Guide
Version 2.0
Quick command guide
Moving
Control H (Backspace) Goto line start
Gold . Goto mark
Gold B Goto end of buffer
Gold T Goto start of buffer
F12(BS) Goto beginning of line
Find Goto next occurrence of search string
Prev Screen Go 10 lines up
Next Screen Go 10 lines down
Up Arrow Go 1 line up vertically
Left Arrow Go 1 character back
Down Arrow Go 1 line down vertically
Right Arrow Go 1 character forward
Keypad 0 Goto next line beginning
Keypad 1 Goto next word
Keypad 2 Goto next end of line
Keypad 3 Goto next character
Keypad 7 Goto next page
Keypad 8 Goto next paragraph
PF3 Goto next occurrence of search string
Gold Find Goto next occurence of string
Gold Up Arrow Goto start of buffer
Gold Left Arrow Go backwards until key struck
Gold Down Arrow Goto end of buffer
Gold Right Arrow Go forward until key struck
Gold Keypad 4 Goto end of buffer
Gold Keypad 5 Goto beginning of buffer
Gold PF3 Goto next occurrence of string
Insertion
Control I (Tab) Insert a tab character
Control L Insert a form feed character
Control M (Return) Insert a carriage return
Escape (twice) Insert an escape character
Gold G Include file at current position
Gold O Toggle insert/replace mode
Gold P Insert a form feed character
F11(ESC) Insert an escape character
Insert Here Paste
Gold Keypad 0 Open line
Gold Keypad 3 Insert ASCII character
Deletion
Control J (Line feed) Delete to beginning of word
Control U Delete to beginning of line
Rubout Delete previous character
Page 26
Sedt Users Guide
Version 2.0
Gold Z Clear buffer
F13(LF) Delete to beginning of word
Remove Cut
Keypad 6 Cut
Keypad , Delete character forward
Keypad - Delete word forward
PF4 Delete line forward
Gold Keypad 2 Delete to end of line
Undeletion
Gold Keypad 6 Undelete paste string
Gold Keypad , Undelete character
Gold Keypad - Undelete word
Gold PF4 Undelete Line
Miscellaneous
Control A Set indentation level
Control D Decrease indentation level
Control E Increase indentation level
Control K Define key
Control P Print contents of buffer
Control T Adjust select range by a tab stop
Control W Refresh display
Gold control I Save key definition in buffer
Gold control L Load key definition from buffer
Gold + Set direction for next command to forward
Gold - Set direction for next command to reverse
Gold < Set direction for next command to reverse
Gold > Set direction for next command to forward
Gold C Center line
Gold D Toggle between one and two window mode
Gold E Edit new file in current buffer
Gold F Save current buffer and exit
Gold H Help
Gold M Set mark
Gold O Toggle insert/replace mode
Gold Q Exit without saving current buffer
Gold R Enter ruler definition mode
Gold S Save contents of buffer
Gold U Undo last command if possible
Gold W Toggle between 132 and 80 character screen
Gold X Execute Sedt commands from file
Gold _ Insert a hyphen and reindent paragraph
F4 Append select range to paste buffer
Interrupt Save contents of buffer
Resume Dead key
Cancel Quit without saving buffer
Main Screen Dead key
Exit Save buffer and exit
Help Help
Page 27
Sedt Users Guide
Version 2.0
Do Execute operating system command
F17 Select buffer 0
F18 Select buffer 1
F19 Select buffer 2
F20 Select buffer 3
Select Set select point at current position
Keypad 4 Set default direction forward
Keypad 5 Set default direction reverse
Keypad 9 Substitute next occurrence of search string
Keypad . Set select point at current position
PF2 Help
Keypad Enter Dead key
Gold F4 Load paste buffer from file
Gold Do Execute Sedt command
Gold F17 Load keystrokes into key until key pressed again
Gold F18 Execute keystrokes loaded into key
Gold Remove Load paste buffer from select range without
deleting
Gold Select Cancel select point
Gold Keypad 1 Change case EDT style
(Select range,found string,character)
Gold Keypad 7 Execute Sedt command
Gold Keypad 8 Fill or justify to end of paragraph
Gold Keypad 9 Substitute one string by another
Gold Keypad . Cancel select point
Gold Keypad Enter Swap characters
Page 28
Sedt Users Guide
Version 2.0
Basic Sedt commands
All Sedt functions are implemented by associating command
strings with keys on the keyboard. The syntax and semantics of
these command strings are given below. Typically, a standard
keyboard layout will only implement a subset of the possible
functionality. For complex editing functions it may be useful to
enter the commands directly through using Gold Do or Gold Keypad
7. To understand the command struicture fully is it a good idea
to study a keypad definition file.
Contitional command execution:
^C() Execute commands in parentheses if the
buffer has been modified since last save.
^C(|)
Execute the first set of commands if the
buffer has been modified since last save.
Execute the second set of commands if the
buffer has not been modified.
^E()()
Execute the first set of commands. If an
error occurs in this command string,
execute the second set of commands.
^E()(|)
Execute the first set of commands. If an
error occors in this command string,
execute the second set of commands.
Otherwise execute the third set of
commands.
Command structure
{+|-}{}:{}
Performs an action within the editor
{+|-}{}@{}
Defines a range within the buffer
Entities that are not command arguments cause
the current position to move to the point defined by the
entity.
Entities preceeded by a - always work backwards
from the current position. When preceeded by a + they
always work forward from the current position. Unsigned
entotoes work forward or backward depending upon the
current direction.
An entity working backward starts with the
Page 29
Sedt Users Guide
Version 2.0
character immediatly before the current cursor position.
When working forward the entity includes the current
cursor position.
Count normally causes the command or entity to
be repeated.
A - causes the command or entity to work
backwards in the buffer.
A + causes the command or entity to work
forwards in the buffer.
Command sequences may be repeated by following a
count with the commands to be repeated in parenthesis.
If count is zero the command sequence will be repeated
until an error occurs or :TI senses type ahead
Entities
@BB Top of buffer
@EB End of buffer
@EL End of line
@C Character
@F
Start of next occurrence of
@L Next beginning of line
@M Point number . Point 0 is the
select point
@N Start of next occurrence of same search
string
@PAG Start of next page
@PAR Start of next paragraph
@SEN Start of next sentence
@SR Select point
@V Same position within next line
@W Start of next word
Commands
:A Make entities default forward
:B Make entities default backward
:CC Change case within entity
:CD Change to lower case within entity
:CE Changes case EDT style. Select range
if set, otherwise search string, else char
:CH Insert character with ASCII value
:CL Center text of current line
:CM Call the top level menu (Not supported)
:CU Change to upper case within entity
:D Delete entity
:EAP Delete entity and append to delete buffer
Page 30
Sedt Users Guide
Version 2.0
:FE
Edit file named
:FG
Insert file named at current
position
:FS
Save current buffer in file named
:FX
Execute basic Sedt commands in file
:GE Get entity into delete buffer but do not
remove from text
:GAP Append entity to delete buffer but do not
remove from text
:H Display help message contained in
SEDTHELP.TXT
:I
Insert at current position
:K{G}{F|A}NNN
Define key as
G Gold
F Function key
A Ascii character
NNN 3 digit decimal number
:LD Decrease indentation by 1
:LD Decrease indentation by
:LI Increase indentation by 1
:LI Increase indentation by
:LK{G}{F|A}NNN Load key definition from current buffer
G Gold
F Function key
A Ascii character
NNN 3 digit decimal number
:LNE{G}{F|A}NNN Execute keystrokes previously saved in key
:LNL{G}{F|A}NNN Save subsequent keystrokes into key until key
retypes
:LS Set current column position as
indentation
:M Save current position in point 1
:M Save current position in point
:NL Insert a new line character
:NS Substitute using save object and target
:OE
Output error message and do
normal error mandling
:OL Open line
:OM
Output message on message line
:OS Toggle replace/insert mode
:PL
Load the paste buffer from file named
Page 31
Sedt Users Guide
Version 2.0
:PR
Print current buffer on devive LST:
:PS
Save the paste buffer in file named
:REP Replace search string by contents of
paste buffer
:RF Refresh the screen
:RL Change to ruler definition mode
:RS Remove select point
:SEL Save current position in select point
:SK{G}{F|A}NNN Save key definition in current buffer
G Gold
F Function key
A Ascii character
NNN 3 digit decimal number
:SL insert entity into search buffer
:SUB
replace next occurrence of with
:SYS
Spawns to the operating system
:TAB Enter tab and space characters to advance
to next tab stop
:TAD Adjust the left margin of the text within
the range of the entity. Direction
determines whether the margin is
adjusted left or right. A count may be
used to adjust by more than one tab
stop.
:TF Fill within entity
:TI Return an error condition if type ahead
:UC Undelete last deleted character
:UL Undelete last deleted line
:UM Undo last command. Commands that can be
undone are moves and substitutes
:UPAG Undelete last deleted page
:UPAR Undelete last deleted paragraph
:UPD Update screen including header
:USEN Undelete last deleted sentence
:USR Paste
:UU Undelete last unknown entity
:UW Undelete last deleted word
:Q Abort without saving file
:WC Toggle between one and two window display
:WD Toggle screen width between 80 and 132
columns
:WI Select buffer
:X Exit and save file after creating backup
file
:Z Zero current buffer
Page 32
Sedt Users Guide
Version 2.0
Error handling:
If an error occurs during execution of a command string
the current command will be terminated and Sedt will skip
the rest of the command string. Only when the command
string is contained in parentheses after ^E will command
execution be resumed.
Page 33
Sedt Users Guide
Version 2.0
Key definition file
Each line in the key definition file SEDTKEYS.TXT
programs one key. The format is a one or two letter key type,
followed by a three digit decimal key number, followed by the
string to program the key with.
If a key definition contains either ?, ! or % special is
taken before the keys is executed:
? causes Sedt to
prompt with String on the bottom line of the display and
accept an input string terminated with Return, Do or
Enter. The whole original contruct is replaced with the
input string.
?? is replaced with ?.
! causes Sedt to
prompt with String on the bottom line of the display and
accept a single keystroke, optionally preceeded with
Gold. The whole original contruct is replaced with a
string identifying the key pressed. The syntax for the
identifying string is given below.
!! is replaced with !.
%F is replaced with the name of the file being
edited in the current buffer.
%N is replaced with the name - minus type - of
the file being edited in the current buffer.
%% is replaced with %.
Key types:
A ASCII character
GA Gold ASCII character
F Function key
GF Gold function key
Ascii character numbers are the decimal values of the
ASCII character.
Function key numbers
000 Compose
001 Hold Screen
002 Print Screen
Page 34
Sedt Users Guide
Version 2.0
003 Setup
004 F4
005 Break
006 Interrupt
007 Resume
008 Cancel
009 Main Screen
010 Exit
011 ESC
012 BS
013 LF
014 Additional Options
015 Help
016 Do
017 F17
018 F18
019 F19
020 F20
021 Find
022 Insert Here
023 Remove
024 Select
025 Prev Screen
026 Next Screen
027 Up Arrow
028 Left Arrow
029 Down Arrow
030 Right Arrow
031 Keypad 0
032 Keypad 1
033 Keypad 2
034 Keypad 3
035 Keypad 4
036 Keypad 5
037 Keypad 6
038 Keypad 7
039 Keypad 8
040 Keypad 9
041 Keypad ,
042 Keypad -
043 Keypad .
044 Keypad PF1
045 Keypad PF2
046 Keypad PF3
047 Keypad PF4
048 Keypad Enter
Page 35
Sedt Users Guide
Version 2.0
Some Sedt hints and suggestions
Defining and inserting templates
Many tasks, such as programming, require input of the
same type on construct over and over again. Probably the best
example of this is COBOL programming. Using learn mode you can
define your own set of templates that can be inserted with two
keystrokes. Typically you will have the key definitions in a
Sedt command file which you can load at your option depending on
the task you are working on. The following example shows how
such a template file can be contructed and used.
To create a file containing a set of COBOL templates
called COBOL.TEM call Sedt with the command
Sedt COBOL.TEM
Define the key Enter as follows. Type Control K and type
Enter to the Key: prompt. Enter the following at the As:
prompt:
:I/:K!"Key:""/:SKA026@EL:I/"/:NL.
Enter the following text as the first line:
:KF014":LNE!/Insert Template: /.".
This will define the key Additional Options to prompt for
and use a template key.
Enter F18 to use buffer 1 as a scratch buffer.
Enter Gold P17 to enter learn mode.
Type the template you want to load. A typical template
will be a COBOL statement or the minimum COBOL program. In this
case we will load the template for "VALUE OF IDENTIFICATION IS "
simply by typing the text as you want it in the template. Note
that you can include using Gold M to mark special places in the
template you may want to go to, Returns, Tabs or anything else
you want repeated to create the template. When you are finished
type Control Z to end learn mode.
Enter F17 to return to buffer 0.
Hit Enter and type the key you want to contain the
template at the Key: prompt. Note that you can use any
character including the letters of the alphabet in upper and
lower case (which are the same), function keys, with or without
Gold. You will now have a line inserted into COBOL.TEM.
Page 36
Sedt Users Guide
Version 2.0
Continue this process until you have defined all your
templates. Any line starting with a ; is treated as a comment
line.
Save the file with Gold F.
When you want to use the templates load them by typing
Gold X and entering COBOL.TEM at the "Execute Sedt commands in
File:" prompt.
Now when you want to use a template enter Additional
Options and type the key that you have entered the template into
at the "Insert Template: " prompt.
A simple template for C programs is included in the
distribution in the file C.TEM.
Page 37