,ll 6.6
,cs 10
,pl 66
,lm 0.2,0.5
,pn 1
,ju
,hd
,ce
OmegaSoft 6809 Cross Screen Editor (V1.0)
,,
,ft

,ce 1
12-##
,,
,ce
OmegaSoft 6809 Cross Screen Editor (V1.0)

,ce
SCREEN EDITOR COMMANDS

Line syntax : "." = current, "$" = last, digits = offset or relative line number, + and - allowed. Default keys are assumed.

Buffered Commands ('E' prompt)

 Edit <filename>                  Clear buffer and read file.
 New <filename>                   Clear buffer and set filename.
 Get <filename>                   Get file past cursor.
 Save [<filename>]                Save entire file.
 Save and Quit                    Save entire file and quit.
 Save Partial <line>,<line>
                <filename>        Save part of file.
 Move <line>[,<line>]             will move lines to after
                                          cursor position.
 Copy <line>[,<line>]             will copy lines to after
                                          cursor position.
 DElete <line>[,<line>]           will delete lines. 
 Position <line>                  positions cursor to line.
 Tabs Repetitive <incr>           Sets tabs at columns 0, incr,  
                                  2 * incr, 3 * incr, etc.
 Tabs Non-repetitive {<column>}   Sets tab at entered columns.
                                  (Columns separated by spaces).
 Tabs Add                         Add tab at cursor position.
 Tabs                             Clear all tabs.
 T+                               Enable display of tab markers.
 T-                               Disable display of tab markers.
 U+                               Upper/lower case same.
 U-                               Upper/lower case different.
 $<command line>                  Operating system command.
 ?                                Display status, help.

When loading a new file or exiting the editor you will be prompted to save the current buffer if it has been modified since last saved. Any response other than an 'N' or 'n' will save the old buffer. A response of 'C' or 'c' will allow you to change the file name before saving.

Non-buffered commands 

 Quit            Exit editor.
 J               move cursor left one character.
 L               move cursor right one character.
 I               move cursor up one line.
 ,               move cursor down one line.
 K               alternate between left and right of line.
 O               move cursor 1/2 screen up
 .               move cursor 1/2 screen down
 space           move cursor to next identifier.
 HT or cntrl T   move cursor to next tab.
 cntrl R         move cursor backwards to previous tab.
 cntrl D         delete single character. deleting the carriage
                 return will merge lines, with multiple leading
                 spaces compressed into one space.
 cntrl X         delete current line.
 1               (digit one) Overwrite one character. 
 V               overwrite characters until escape.
 A               enter append mode.
 ;               enter insert mode.
,pg

,ce
SCREEN EDITOR COMMANDS

Text search commands

 Find          will position cursor, response is 
                                     CR = stop command
                                     Space = continue
                                     M = multiple
                                         occurrences on line
                                       
 Replace       will position cursor, response is
                                     CR = stop command
                                     Space = continue
                                     R = Replace and continue
                                     M = multiple
                                         occurrences on line
                                     E = entire buffer

Note : When the 'F' prompt appears enter the find pattern - if you enter just a carriage return then this will terminate the command. When the 'R' prompt appears enter the Replace pattern.  A '?' is used as a don't care in the find and Replace patterns. The entire buffer option will enable the replacement throughout the rest of the buffer. The multiple occurrences option will allow a match on each occurence of the find pattern on any one line, else only the first match on a line is recognized. The search will start on the current line, continue to the end of the buffer, start back at the top, and stop on the current line. The cursor will be positioned at the last match when the command terminates.

Insert or append mode 

Character entry until an escape is entered. Insert mode will insert characters before the current cursor position. If a carriage return is entered during insert mode then append mode will be entered with the last part of the line carried over until append mode is exited. Append mode will start new lines past the current line with no partial line carried over. In addition the following special characters are recognized :

BS or DEL        backspaces over character.
HT or cntrl T    forward tab.
cntrl R          reverse tab.
cntrl A          copies remainder of last line entered.
cntrl X          removes all characters entered so far.
,pg
,ce
INTRODUCTION

The OmegaSoft Screen Editor is designed to provide a facility for editing Pascal and assembly language programs. The software is designed for maximum efficiency by using a minimum of file accesses and by using some of the features of "smart" terminals.

On some operating systems the editor also allows you to compile and assemble directly from the edit buffer, making for a quick syntax check mechanism.

The TCON file must be setup on your system before the screen editor can be used, see the installation section of this manual.

General Information

A line number is provided that is relative to the start of the text. The first line of the text is line one. Normally the cursor is always to the right of the line numbers (you cannot edit them). The only exception is when the cursor is positioned at line zero in which case the cursor is at the upper left hand corner of the screen. Line zero is only valid in certain circumstances which will be pointed out. If there are no text lines in the edit buffer then the cursor will be on line zero.

The cursor can only be positioned within the valid characters of a line, if you position the cursor past the end of the line you are on then it will move to the far right of the line (representing the carriage return if you like).

This editor does not use scratch files and does not allow you to edit a file that will not fit into memory all at once. When you start to edit a file it is read completely into the edit buffer. When you are done editing the file it is written back under the same file name as you started with (unless told to do otherwise). The number of lines allowed is proportional to the amount of memory available to the editor, but never more than 8000.

It is possible to modify this editor to read in parts of files, edit them, write them to a scratch file, read in the next block, etc. and then rename the scratch file to the original file name. This however, would defeat the purpose of writing an efficient editor. Either you don't have enough memory or your files are quite large. It is usually better to have smaller, more manageable files rather than using paging in an editor.

,ce
COMMANDS

Commands will be shown with their default key shown (see installation section). The relevant key description as used by the configuration manager will also be noted.

,ce
FILE HANDLING COMMANDS

EDIT

Syntax :  E <filename>                    Con key : edit old file

Will clear the edit buffer and load in the entire contents of the named file. This file name will be remembered for use with a Save command without a file name parameter. 
,pg
,ce
FILE HANDLING COMMANDS

If there is already a file in the edit buffer that has been modified since the last save then you will be prompted to save the old buffer. If you answer with an "N" or "n" then the old buffer will not be saved. If you answer with an "C" or "c" then it will save the old buffer into a new file name that you specify. Any other answer will cause the old buffer to written to the file name remembered from the last Edit command.

While the file is loading you may get a "Memory full" error. This means that the file will not fit in the edit buffer and you cannot modify the file. You can however save what part will fit into another file. The maximum length of a text line is 200 characters, portions of the line past the edge of the screen are accessed using automatic horizontal scrolling.

NEW

Syntax : N <filename>                     Con key : edit new file

The new command will clear the edit buffer, make sure the file does not exist, remember the file name for use with a future save command, and enter the append mode at line one.

Note that the file is not actually opened at this time. If there is an old file in the edit buffer that has been modified then you will be prompted to save it as in the EDIT command.

If the file already exists you will be prompted to see if you would like to edit the existing file.

This command is the normal method of creating new files.

GET

Syntax : G <filename>                          Con key : get file

This command will open the specified filename and read its entire contents into the edit buffer past the line where the cursor is positioned. This is useful for merging files together, or with the use of the save partial command can be used to "cut and paste" parts of files together.

SAVE

Syntax : S [<filename>]                       Con key : save file

This command will write out the entire contents of the edit buffer to the specified file. No changes are made to the edit buffer. If there is a remembered filename (from an edit or new command) then the filename parameter can be omitted.

SAVE and QUIT

Syntax : SQ                                   Con key : save file

This command will act the same as both a SAVE command with no filename and a QUIT command. This is a short-cut that is commonly used since in general you will be editing one file and saving it back and then exiting the editor.
,pg
,ce
FILE HANDLING COMMANDS

SAVE PARTIAL

Syntax : SP <first_line>,<last_line> <filename>
                                              Con key : save file

This command will save only a portion of the edit buffer to the file. First_line through last_line will be written, and the edit buffer will not be modified.

QUIT

Syntax : Q                                  Con key : quit editor

This command will exit the editor and is not buffered (a carriage return is not required). If the contents of the edit buffer have been modified since the last save command then you will be prompted to save it as in the EDIT command.

,ce
STATUS AND HELP PAGES

To display the status page the ? (default, con key : display info) key must be hit while in command mode. To exit this display hit any key except H. The status line will display the editor version number, the copyright notice, the current file name, if any, the last line number in the edit buffer, the maximum line number available, the amount of memory used so far, and the amount of memory available in the edit buffer. Note that there is some memory that cannot be used and you will not be able to change the edit buffer if this value falls below 200 hex bytes. 

Entering an H while the status page is being display will display the first help page. Entering another H at each step will display the next help page, until they have all been displayed. You can exit any time by entering any character other than H.

,ce
TEXT APPEND AND INSERT

If an 'A' (default, con key : append mode) is entered in command mode you will enter the text append mode. You exit this mode by entering an escape (default, con key : edit escape). The editor will start creating new lines immediately following the line where the cursor was when this mode was entered. To start a new file, or insert lines before the first line of the file you can move the cursor to line zero and enter this mode.

Any text typed in will be entered into the edit buffer, with a carriage return (default, con key : end of line) starting a new line. You cannot type past the end of the line and this editor will not do "word-wrap". Typing past the right edge of the screen will initiate horizontal scrolling. A number of special control characters are recognized in text append and text insert modes, they are :

BS (cntrl H) or DEL ($7F) (defaults, con key : backspace) : Backspaces one character and removes that character from the buffer (destructive backspace).

HT (cntrl I) or cntrl T (defaults, con key : forward tab) : Forward Tab - move to next tab stop. If there are no further tab stops to the right then the cursor will move to the far right of the line.
,ce
TEXT APPEND AND INSERT

cntrl R (default, con key : reverse tab) : Reverse Tab - move to previous tab stop. If there are no further tab stops to the left then cursor will move to the first position on the line (tab 0).

cntrl A (default, con key : duplicate last line) : Copies previous line to current line starting at the current cursor position. Useful for duplicating equivalent or similar text from the previous line.

cntrl X (default, con key : delete one line) : Removes all characters on the line and positions the cursor at the first position on the line.

If a ";" (default, con key : insert mode) is entered when in the command mode then text insert mode will be entered. This mode is exited by typing an escape (default, con key : edit escape).  The text to the right of the cursor is moved off the right edge of the screen and you can enter text until the editor no longer accepts characters. If you enter a carriage return (default, con key : end of line) while in this mode then you will enter the text append mode. The only difference is that if you typed the carriage return with text to the right of the cursor then the text to the right will be carried down to the next line, and will continue to do this until the escape is entered at which point it will join with the contents of the last line entered.

As an example of this usage the following Pascal segment is going to be broken down into 3 lines instead of one, with the cursor located at the underlined character in the text and your entries in bold print.

if count = 3 then count := 4 ; 

position the cursor to the "then", enter a ";", and enter a carriage return :

if count = 3 then count := 4 ; 

will result in 

if count = 3 
     

type in a tab character and then escape :

if count = 3
  then count := 4 ; 

By positioning the cursor to "count" and re-entering the insert text mode this sequence can be repeated to produce :

if count = 3
  then
    count := 4 ;
,pg

,ce
POSITION TO LINE

Syntax : P <expression>                con key : position to line

Where expression consists of line numbers with any valid combination of the operators plus "+" and minus "-". No spaces may exist in the expression. A line number can be a decimal number, the period "." which represents the current line, or a dollar sign "$" which represents the last line of the file. You cannot position the cursor to a line that exceeds the last line number, you can however, position to line zero.

,ce
CURSOR MOVEMENT

The basic cursor movement is controlled by a group of keys controlled by the right hand (default) :

                            I      O

                       J      K      L

                                 ,      .


The correlation between the keys discussed and the configuration manual description key is as follows :

J = move one left    K = move alternate     L = move one right
I = move one up      , = move one down
O = half page up     . = half page down
space = move to ident

The J, K, and L keys control cursor left/right movement, J will move the cursor left one character (but not to the left of the first character of the line), doing horizontal scrolling if necessary. L will move the cursor right one character, doing horizontal scrolling if necessary, if past the end of the line the cursor will move to the far right of the screen to indicate that it positioned on the end of line marker. The K key will move the cursor alternately to the far left and far right of the line but will not do horizontal scrolling.

The I and , (comma) keys will move the cursor up (I) or down (,) one line on the screen. Moving up past line one will position you at line zero, you cannot move down past the last line.

The O and . (period) keys will move the cursor up (O) or down (.) one half page (number-of-lines-on-screen >> 2). You cannot move to line zero using the O key.

The space bar will move you to the next identifier on the current line. An identifier is defined to be any sequence of characters containing upper or lower case letters, digits 0 through 9, and the characters "_", "$", and ".". After you are positioned to the last identifier using the space bar will position you back to the first identifier on the line. The space bar will do horizontal scrolling when necessary.

HT (cntrl I) or cntrl T (default, con key : forward tab) will move you to the next tab stop if still within the current line, or the far right of the screen. Cntrl R (default, con key : reverse tab) will position you to the previous tab stop.
