Trailing-Edge - PDP-10 Archives - steco_19840320_1er_E35 - 10,5676/teco/manual/tecins.rnm
There is 1 other file named tecins.rnm in the archive. Click here to see a list.
.Chapter Insert strings and String arguments
The most basic function of text editing programs is inserting
text into a file.  There are several ways of accomplishing this, 
however, the I command is the easiest and the most useful.
.HL1 Insert strings
The basic format of the insert command is:
.b.entry ^Command
.index ^Command ><I
.index ^Command >^Insert
where "text" is the text to be inserted.
This is all that is needed so long as the text does not contain
any control characters other than: backspace (_^H), horizontal tab (_^I),
line feed (_^J), vertical tab (_^K), form feed (_^L), or carriage return
Escapes are used for the purpose of terminated a normal insert string,
and therefore cannot be used within the string without special handling
(see delimited mode insert and insert subcommand _^R).
The control characters other than these are either currently special
commands within the insert string, or are reserved for future use
as special commands.  Those that are currently special commands are documented
.HL2 Insert subcommands
The control characters other than the normal motion characters are used
for special commands within insert strings.
.HL3 _^A and _^V subcommands
These subcommands (along with _^B and _^W) are used to convert
the case of the text that follows.  When a single _^A or _^V is
encountered in the insert string, the following character, if it
is an alphabetic character, is converted to lower case.  When two
consecutive _^A's or _^V's are encountered, the lower case lock is set,
i.e., all subsequent alphabetic characters are converted to lower case.
.HL3 _^B and _^W subcommands
These subcommands are the upper case equivalents of _^A and _^V.
A single _^B or _^W will cause the next character to be converted to
upper case (if it is a lower case alphabetic).  Two consecutive _^B's or
_^W's will set the upper case lock.
.HL3 _^G subcommand
This subcommand is used to insert the contents of a Q-register
in the current position in the insert string. The formats of this subcommand
.break;where "i" is any single character Q-register name, and "q-register"
is any Q-register name.
Note that the text in the Q-register is processed just like the
rest of the text in the insert command with one exception:  If the
terminating character appears, it is treated as a normal character.
This means that subcommands are processed even if the text is coming
from a Q-register, and case conversion is done (if the upper or lower
case lock is set).  This can be a convienient way to up-case or down-case
all the text in a given Q-register.  Also, since the _^G subcommand is
valid with the Q-register text, the text in the Q-register may
specify the inclusion of yet another Q-register.
.HL3 _^R subcommand
This subcommand is used (just like in command input) to quote the
next character.  This character will cause the next character to next
character to be inserted without checking if it is the terminating
character or if it is a subcommand character.
.HL3 _^T subcommand
This subcommand is used to toggle a flag to indicate whether any of
the other subcommands (except _^R) are to be treated as commands or
as normal text characters.  At the beginning of each insert string the
flag is set to treat the subcommand characters as subcommands.
Note that this subcommand (like the others) must be entered as a control
character, not as up-arrow ("_^") character.  This can cause problems
since TOPS-10 and the TOPS-20 EXEC use _^T as a special command character
themselves.  Under TOPS-10, doing the monitor command "TERMINAL RTCOMP"
will cause the monitor to pass _^T's to TECO as a character instead of
doing a "USESTAT" command.
.HL3 _^_^ subcommand
This subcommand is used to convert the following character into its
lower case range equivalent.  The following conversions are done:
.break.i+5;"@" => "`"
.break.i+5;"[" => "{"
.break.i+5;"_\" => "|"
.break.i+5;"]" => "}"
.break.i+5;"_^" => "~"
.break.i+5;"__" => DELETE
 This subcommand has no effect on any other characters, and does
not affect the setting of the case lock.
.HL2 Delimited insert command
At times it is desirable to have some character other than escape
terminate the insert string.  This is particularly useful when inserting
TECO commands, or any other text that contains a number of escapes.
This can be done by prefixing the insert command with the character
"@".  The format of the delimited insert command which results is:
where "_<delim_>" is any character which will be the delimiting character
for "text", the insert string.
.HL1 String arguments
.index Argument >String arguments
String arguments are used for immediate input of text to be used
by commands which take strings for arguments.  (Examples of such
commands are "U", and "=".)
.index ^Command ><U
.index ^Command ><=
The format of a string argument is:
.break .b
where "text" is an insert string format string.  Note that all
characters valid within an insert string are valid within a string argument,
except that to include a "}", it must be quoted by a control-R (_^R).