home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CP/M
/
CPM_CDROM.iso
/
cpm
/
turbopas
/
rnf-pas.lbr
/
RNFMAN2.RQF
/
RNFMAN2.RNF
Wrap
Text File
|
1986-07-16
|
27KB
|
686 lines
<.MACRO <EEX = <.RES <.S 1
.EEX
AND SO ON!
^THE FOLLOWING DISCUSSION IS INTENDED TO GIVE THE USER SOME
INSIGHT INTO POTENTIAL USES OF MACROS WHILE
DEMONSTRATING HOW EASY MACROS ARE TO DEFINE AND USE.
.HL 1 <WHAT <MACROS <ARE
^MACROS HAVE TWO PARTS: A NAME, AND SOME TEXT. ^THE NAME IS
A SINGLE WORD LONG, WHILE THE TEXT MAY BE ZERO OR MORE WORDS LONG.
^THE EFFECT OF A MACRO IS SIMILIARLY EASY TO DESCRIBE: WHEREVER
THE NAME OF THE MACRO APPEARS <RNF REMOVES IT AND SUBSTITUTES
THE TEXT.
^FOR EXAMPLE, IF THE FOLLOWING MACRO IS DEFINED:
.EX <.MACRO <CDC = <CONTROL <DATA <CORPORATION
.EEX
WHENEVER <.CDC APPEARS IN THE INPUT, <RNF REMOVES IT AND SUBSTITUTES
<CONTROL <DATA <CORPORATION.
.MACRO NOTE * = .SAV .S 2 .LM +15 .RM -15 .P +0 1 5 .C .NOTE1 .S 1
.MACRO ENOTE = .RES .S 2
.NOTE ^NOTE THE ^DOTS
^THE MACRO NAME IS DEFINED WITHOUT A PRECEDING PERIOD (DOT).
^BUT WHEN THE MACRO IS USED, THE NAME MUST BE PRECEDED BY A DOT.
.ENOTE
.HL 1 <HOW <TO <DEFINE <A <MACRO
^THE SIMPLEST FORM OF MACRO DEFINITION IS:
.EX <.MACRO NAME = TEXT
.EEX
WHERE NAME IS THE NAME OF THE MACRO, AND TEXT REPRESENTS ALL THE
TEXT ON THE REST OF THE SAME LINE.
^AFTER THE MACRO DEFINITION, WHEREVER _.NAME APPEARS <RNF REMOVES
IT AND SUBSTITUTES THE TEXT.
.HL 1 <SUB-MACROS
^ALL MACRO EXPANSIONS ARE CONSIDERED TO TAKE PLACE ON THE SAME INPUT
LINE AS THE "OUTERMOST" MACRO CALL. ^THUS, MACROS CAN BE PARAMETERIZED
IN A SIMPLE WAY BY ENDING A MACRO EXPANSION WITH A COMMAND
AND TYPING THE COMMAND ARGUMENT(S) AFTER THE MACRO CALL. ^FOR EXAMPLE,
.EX <.MACRO <RIGHTMARG = <.RM
.EEX
WHICH COULD BE USED BY
.EX <.RIGHTMARG 65
.EEX
^BUT, AS THE EXAMPLE SHOWS, THIS APPROACH IS MOSTLY LIMITED TO TRIVIAL
COMMAND REPLACEMENTS.
^SUB-MACROS PROVIDE THE ABILITY TO PARAMETERIZE MACROS IN A MORE USEFUL
FASHION.
.HL 2 ^DEFINING ^PARAMETERIZED ^MACROS
^MACROS WITH SUB-MACROS ARE DEFINED BY THE FORMATS:
.EX <.MACRO NAME N = TEXT
-OR-
<.MACRO NAME * = TEXT
.EEX
^THE N IN THE FORMAT STANDS FOR A NUMBER IN THE RANGE 1 THROUGH 7.
^IT MEANS THAT THE 1 THROUGH 7 WORDS FOLLOWING THE MACRO CALL ON THE
SAME LINE ARE DYNAMICALLY MADE THE VALUES OF THE SUB-MACROS NAME1,
NAME2, _... ,NAME7.
^SUB-MACROS HAVE A DEFINED VALUE ONLY WHEN THE MACRO IS BEING
EXPANDED.
^IF AN ASTERISK IS USED INSTEAD OF A NUMBER N, IT MEANS THAT ALL
THE WORDS WHICH FOLLOW THE MACRO CALL ON THE SAME LINE ARE DYNAMICALLY
MADE THE VALUE OF THE SUB-MACRO NAME1.
^FOR EXAMPLE,
.EX <.MACRO <Z 2 = ^I HOPE YOU ARE <.Z1 <.X ING <.Z2 <.X ! .EEX
^WHEN <.Z IS CALLED, THE SUB-MACROS <.Z1 AND <.Z2 ARE GIVEN
VALUES EQUAL TO THE TWO WORDS WHICH FOLLOW <.Z ON THE SAME LINE.
^THUS, THE CALL
.EX <.Z FOLLOW ME .EEX
PRODUCES THE TEXT
.EX ^I HOPE YOU ARE FOLLOWING ME! .EEX
.HL 2 ^SUB-MACRO ^SEMANTICS
^SINCE THE PARAMETERS OF A MACRO ARE DEFINED AS MACROS THEMSELVES,
THEY MAY BE USED IN ANY MACRO CALLED WHILE THE SUB-MACROS ARE
DEFINED, AND NEED NOT BE "PASSED DOWN" FROM MACRO TO MACRO.
^IF NO WORDS OR NOT ENOUGH WORDS FOLLOW THE CALL OF A MACRO
WITH SUB-MACROS, THE SUB-MACROS ARE GIVEN NULL VALUES. ^THAT
IS, UNLESS THERE IS ACTUALLY A WORD CORRESPONDING TO A SUB-MACRO,
IT EXPANDS TO NOTHING AT ALL.
.MACRO CHTTL = ^VARIABLES
.CH <VARIABLES
<RNF ALLOWS THE USER TO DEFINE AND USE NUMERIC VARIABLES.
^THESE ARE HANDY (AND ARE USED INTERNALLY) FOR KEEPING TRACK OF
PAGE NUMBERS, CHAPTER NUMBERS, HEADER LEVELS, ETC.
.HL 1 <VARIABLE <SYNTAX
^VARIABLES ARE WORDS WHICH BEGIN WITH A DOLLAR SIGN ($),
FOLLOWED BY FROM 1 TO 9 LETTERS, NUMBERS, OR _$ CHARACTERS.
^THE CASE OF VARIABLE NAMES IS NOT SIGNIFICANT, E.G., <$HILO AND <$<HILO
ARE THE SAME VARIABLE.
^THE FIRST CHARACTER AFTER THE LEADING _$ CANNOT BE A NUMBER.
^THIS IS SO CHARACTER COMBINATIONS OF THE FORMS _$_<BLANK> AND
_$_<NUMBERS> ARE NOT RECOGNIZED AS VARIABLES, MAKING A NUISANCE
FOR THE USER.
^USERS SHOULD NOT DECLARE VARIABLES WITH TWO LEADING DOLLAR
SIGNS, AS THIS IS THE FORMAT USED BY PRE-DECLARED <RNF SYSTEM
VARIABLES.
^FOR EXAMPLE, THE FOLLOWING ARE VALID VARIABLE NAMES:
.TP 8
.EX <$VARIABLE
<$<N$
<$L23
.EEX
WHILE THE FOLLOWING ARE INVALID:
.EX <$100
<$
.EEX
.HL 1 <HOW <TO <DECLARE <VARIABLES
^VARIABLES ARE DECLARED BY THE <.VAR COMMAND, WHICH HAS THE FORMAT:
.EX <.VAR _$NAME
.EEX
^NOTE THAT THE VARIABLE NAME IS BOTH DECLARED AND USED WITH A
LEADING _$.
^THE EFFECT OF <.VAR IS TO ALLOCATE SPACE FOR A NUMERIC VARIABLE,
GIVE IT THE NAME SPECIFIED, AND INITIALIZE THE VARIABLE TO ZERO.
<RNF PROVIDES 75 SPACES FOR USER-DEFINED VARIABLES IN ADDITION
TO PREDEFINED VARIABLES.
.HL 1 <PREDEFINED <VARIABLES
^AS A CONVENIENCE TO THE USER, <RNF MAKES USE OF SEVERAL PREDEFINED
VARIABLES WHILE PERFORMING VARIOUS COMMANDS. ^THE PREDEFINED
VARIABLES ARE:
.SAV .LM +17 .P -12 0 1 .TAB 18
.B
<$$PAGE .T ^CURRENT PAGE NUMBER.
<$$CH .T ^CURRENT CHAPTER NUMBER.
<$$HL .T ^CURRENT HEADER LEVEL. ^ALSO DEFINED ARE <$$HL[1] THROUGH
<$$HL[5], WHICH CONTAIN THE CURRENT COUNTS AT EACH LEVEL.
<$$LIST .T ^CURRENT LIST LEVEL. ^ALSO DEFINED ARE <$$LIST[1]
THROUGH <$$LIST[10], WHICH CONTAIN THE CURRENT COUNTS AT EACH
LEVEL.
<$$LM .T ^CURRENT LEFT MARGIN, SET BY <.LM.
<$$RM .T ^CURRENT RIGHT MARGIN, SET BY <.RM.
<$$SP .T ^CURRENT SPACING, SET BY <.SP.
<$$NMP .T ^PAGE NUMBERING FLAG, SET BY <.NMP.
<$$OLNO .T ^OUTPUT LINE NUMBER ON THE CURRENT PAGE.
<$$ANSI .T ^IF SET TO 1, UNDERLINING AND BOLD WILL USE <ANSI
SEQUENCES RATHER THAN OVERSTRIKING. ^THIS CAN BE USED TO PREVIEW
DOCUMENTS ON TERMINALS WITH <ANSI DRIVERS.
.RES
^THE VALUES OF THE PREDEFINED VARIABLES MAY BE EXAMINED OR
CHANGED BY THE USER AT ANY TIME. (^OF COURSE, CHANGING THESE
VALUES WILL AFFECT THE OPERATION OF THE BUILT IN <RNF FEATURES
WHICH USE THEM.)
.HL 1 <VARIABLE <ARRAYS
^ARRAYS MAY BE DECLARED BY THE <.ARRAY COMMAND, WHICH HAS THE
FORMAT:
.EX <.ARRAY _$NAME N .EEX
^THE EFFECT OF THIS DECLARATION IS THAT _$NAME IS DECLARED TO
BE AN N+1 ELEMENT ARRAY, WHICH MAY BE REFERENCED AS _$NAME[0]
THROUGH _$NAME[N].
^THE SUBSCRIPT MAY BE OMITTED IF THE ZEROETH ELEMENT OF THE
ARRAY IS BEING REFERENCED. ^THAT IS, _$NAME[0] AND _$NAME
ARE EQUIVALENT. ^THIS CONVENTION IS ADOPTED SO THAT A SINGLE
DECLARATION CAN ALLOCATE BOTH AN N-ELEMENT ARRAY AND AN
INDEX VARIABLE ASSOCIATED WITH THE ARRAY.
(^THE PREDECLARED ARRAYS <$$HL AND <$$LIST ARE USED IN THIS FASHION.)
^NOTE THAT THE ARRAY DECLARATION REQUIRES N+1 SPACES OF THE
75 ALLOWED FOR USER VARIABLES.
.HL 1 <EXPRESSIONS
^AN EXTREMELY USEFUL FEATURE OF <RNF IS THE ABILITY TO COMBINE
VARIABLES, NUMBERS, AND OPERATORS INTO EXPRESSIONS WHICH COMPUTE
A NUMERIC VALUE.
^THE VALUES COMPUTED BY THE EXPRESSIONS CAN IN TURN INDEX ARRAYS,
BE ASSIGNED TO VARIABLES, OR BECOME A PART OF THE OUTPUT TEXT.
.HL 2 ^EXPRESSION ^SYNTAX
^AN EXPRESSION IS DEFINED AS FOLLOWS:
.TAB 20 27
.EX EXPR .T ::= .T TERM _< RELOP TERM >
.NOPERIOD
RELOP .T ::= .T <.EQ. ! <.NE. ! <.LT. ! <.LE. ! <.GT. ! <.GE.
.PERIOD
TERM .T ::= .T ITEM _< _< + ! - > ITEM >...
ITEM .T ::= .T _< + ! - ! _# > ELEMENT
ELEMENT .T ::= .T ( TERM) ! VAR ! INTEGER
VAR .T ::= .T _$ID _< [ TERM ] > _< = TERM >
.EEX
^THE ANGLE BRACKETS _< AND > IN THE SYNTAX EXPRESSIONS ENCLOSE
OPTIONAL PARTS. ^THE CONSTRUCTION
.EX _< STUFF >...
.EEX
INDICATES THAT STUFF IS ALLOWED TO APPEAR ZERO OR MORE TIMES.
^NOTE THAT ANGLE BRACKETS ARE USED TO DESCRIBE EXPRESSIONS; THEY
DO NOT APPEAR IN EXPRESSIONS.
^THE _# CHARACTER IN AN EXPRESSION REPRESENTS A LOGICAL <NOT
OPERATION. ^THE EXPRESSION _#X HAS THE VALUE 1 IF X EQUALS
0, OTHERWISE IT HAS THE VALUE 0.
^THE BLANKS IN THE SYNTAX EXPRESSIONS ARE NOT SIGNIFICANT AND IN FACT
BLANKS ARE .U <NOT .NOU PERMITTED IN EXPRESSIONS. ^THAT IS, AN
EXPRESSION MUST BE A SINGLE WORD.
^SOME EXAMPLES OF VALID EXPRESSIONS ARE:
.EX <$A.GR.5
<$HL[$HL+1]=0
<2+$$PAGE
<$X[$X=$X+1]=$X[$X]+1
<$A=$B=$C
.EEX
.HL 2 ^EXPRESSION ^EVALUATION
^EXPRESSIONS ARE EVALUATED FROM LEFT TO RIGHT, EXCEPT THAT
ASSIGNMENTS (INDICATED BY THE = SIGN) AT THE SAME LEVEL ARE
DONE FROM RIGHT TO LEFT.
^IN THE EXAMPLES ABOVE, <$X[$X=$X+1]=$X[$X]+1 IS EQUIVALENT
TO THE SERIES OF EXPRESSIONS <$X=$X+1 <$X[$X]=$X[$X]+1.
(^RECALL THAT THE ZEROETH ELEMENT OF AN ARRAY CAN BE REFERENCED
WITHOUT SUBSCRIPTS.)# ^ON THE OTHER HAND, THE EXPRESSION
<$A=$B=$C IS EQUIVALENT TO <$B=$C <$A=$B.
.HL 2 ^WHERE ^EXPRESSIONS ^ARE ^USED
^AN EXPRESSION CAN ALWAYS BE USED AS AN ARGUMENT TO A COMMAND
WHICH REQUIRES A NUMERIC VALUE.
^AN EXPRESSION CAN ALSO APPEAR IN TEXT. <RNF DECIDES WHETHER
TO EVALUATE AN EXPRESSION IN TEXT OR NOT BASED ON WHETHER THE
FIRST CHARACTER IS A _$. ^IF IT IS, <RNF EVALUATES THE EXPRESSION;
OTHERWISE THE EXPRESSION IS TREATED LIKE ANY OTHER TEXT WORD.
^FOR EXAMPLE,THE EXPRESSION <$A+2 WILL BE EVALUATED, WHILE
<2+$A WILL NOT.
^IF <$A HAS THE VALUE 3, THE FORMER WILL APPEAR IN THE OUTPUT
AS "5", WHILE THE LATTER WILL APPEAR AS <"2+$A".
^FOR THE FEW CASES WHEN IT IS NOT CONVENIENT TO BEGIN AN EXPRESSION
TO BE EVALUATED WITH A VARIABLE NAME, THE SYNTAX:
.EX <$(<EXPR)
.EEX
WILL CAUSE EXPR TO BE EVALUATED.
.HL 2 ^SUPPRESSED ^EXPRESSIONS
^FREQUENTLY, ONE WISHES TO COMPUTE A VALUE AND ASSIGN IT TO
A VARIABLE -- THAT IS, EVALUATE AN EXPRESSION -- WITHOUT
PLACING ANYTHING AT ALL IN THE OUTPUT TEXT. ^THIS IS DONE
BY TERMINATING THE EXPRESSION WITH A SEMICOLON.
^FOR EXAMPLE, THE WORDS:
.EX
.EX <.VAR <$A ^SEE <$A=$A+1; ONLY <$A OF THESE.
.EEX
ARE OUTPUT AS
.EX ^SEE ONLY 1 OF THESE.
.EEX
.PAGE
.FIG 20
.C .U <THIS <PAGE <INTENTIONALLY <LEFT <BLANK .NOU
.MACRO CHTTL = ^EXAMPLES
.CH <EXAMPLES
^THIS CHAPTER CONTAINS A NUMBER OF SHORT EXAMPLES DEMONSTRATING
VARIOUS FREQUENTLY USED <RNF FEATURES. ^THE INPUT FOR THESE EXAMPLES
WAS PREPARED ON A ^CYBER; IT IS UPPER-CASE AND ASSUMES <.CASECONVERT,
<.FLAG, AND <.FLAGCAPS. ^ON COMPUTERS WITH <ASCII CHARACTERS, INPUT
WOULD NORMALLY BE TYPED UPPER AND LOWER CASE.
^THE EXAMPLES ARE INTENDED TO BE SELF-EXPLANATORY AND ARE PRESENTED
WITHOUT ACCOMPANYING TEXT.
.PAGE
.HL 1 <INPUT <TEXT <EXAMPLE
.ASIS
.C <RNF
.C ^INPUT ^TEXT
^INPUT TEXT TO <RNF CONSISTS OF A SEQUENCE OF WORDS AND COMMANDS
SEPARATED BY BLANKS. ^A COMMAND IS ANY WORD WHICH BEGINS WITH
A PERIOD FOLLOWED BY A NON-DIGIT, WHILE A WORD IS ANY
SEQUENCE OF CHARACTERS WHICH
DOES NOT CONTAIN A BLANK. ^THE FOLLOWING ARE CONSIDERED WORDS:
.I 5 ^THIS
.BR .I 5 _.^B
.BR .I 5 ^S^I^G^N^I^F^I^C^A^N^T_#^B^L^A^N^K
.BR .I 5 .234
.B ^OF THE ABOVE WORDS, ONLY _.^B IS A COMMAND.
.B <RNF GATHERS WORDS INTO LINES. ^BY DEFAULT, THE FIRST WORD IN
A LINE BEGINS AT THE LEFT MARGIN, AND THE LAST WORD ENDS AT
OR BEFORE THE RIGHT MARGIN. ^THAT IS, LINES ARE LEFT JUSTIFIED.
^IN THE OUTPUT,
AT LEAST ONE BLANK APPEARS BETWEEN WORDS; TWO BLANKS FOLLOW A
PERIOD OR QUESTION MARK WHICH END A WORD.
!
.PAGE
.C <RNF
.C ^INPUT ^TEXT
^INPUT TEXT TO <RNF CONSISTS OF A SEQUENCE OF WORDS AND COMMANDS
SEPARATED BY BLANKS. ^A COMMAND IS ANY WORD WHICH BEGINS WITH
A PERIOD FOLLOWED BY A NON-DIGIT, WHILE A WORD IS ANY
SEQUENCE OF CHARACTERS WHICH
DOES NOT CONTAIN A BLANK. ^THE FOLLOWING ARE CONSIDERED WORDS:
.I 5 ^THIS
.BR .I 5 _.^B
.BR .I 5 ^S^I^G^N^I^F^I^C^A^N^T_#^B^L^A^N^K
.BR .I 5 .234
.B ^OF THE ABOVE WORDS, ONLY _.^B IS A COMMAND.
.B <RNF GATHERS WORDS INTO LINES. ^BY DEFAULT, THE FIRST WORD IN
A LINE BEGINS AT THE LEFT MARGIN, AND THE LAST WORD ENDS AT
OR BEFORE THE RIGHT MARGIN. ^THAT IS, LINES ARE LEFT JUSTIFIED.
^IN THE OUTPUT,
AT LEAST ONE BLANK APPEARS BETWEEN WORDS; TWO BLANKS FOLLOW A
PERIOD OR QUESTION MARK WHICH END A WORD.
.PAGE
.HL 1 <PARAGRAPHING
.ASIS
.C ^PARAGRAPHING
.P +5 1 5
.PP ^THE PARAGRAPHING FACILITY IN <RNF ENABLES FAST, CONVENIENT
TEXT ENTRY IN A NATURAL FORMAT.
.PP ^PARAGRAPHING IS SET UP BY THE _.<P COMMAND, WHICH HAS THE
FORMAT:
.B .I 9 _.<P INDENT SPACING TEST
.PP ^INDENT IS THE COLUMN AT WHICH THE FIRST LINE OF EACH
PARAGRAPH IS TO BEGIN, SPECIFIED EITHER AS AN UNSIGNED COLUMN
NUMBER OR AS A POSITIVE OR NEGATIVE OFFSET FROM THE CURRENT
LEFT MARGIN. ^SPACING SPECIFIES THE NUMBER OF SPACES BETWEEN
PARAGRAPHS, WHERE 1 IS THE EQUIVALENT OF A <.S 1 COMMAND,
2 IS THE EQUIVALENT OF A <.S2 COMMAND, ETC. ^TEST
SPECIFIES THE NUMBER OF LINES WHICH
MUST REMAIN ON THE CURRENT PAGE, OR THE PARAGRAPH IS BEGUN
ON THE NEXT PAGE.
.PP ^THE DEFAULT IS:
.B .I 9 _.<P +0 1 3
.PP ^THE _.<PP COMMAND DENOTES THE BEGINNING OF A NEW PARAGRAPH.
.AP
^AS AN ALTERNATIVE (OR IN ADDITION) TO THE <.PP COMMAND, THE
USER CAN SELECT AUTOPARAGRAPH MODE BY MEANS OF THE <.AP COMMAND.
^IF <.AP IS IN EFFECT, A BLANK AT THE BEGINNING OF ANY LINE
(OR A BLANK LINE)
IS TAKEN TO BE A <.PP COMMAND.
(^NOTE THAT A BLANK LINE IN <.NOAP MODE IS TAKEN TO BE A <.B
COMMAND.)
^THE AUTOPARAGRAPH CONVENTIONS ALLOW A TYPIST TO ENTER AND WORK
WITH ALL TEXT IN A READABLE FORMAT WHICH IS CONVENIENT FOR
COMPUTER EDITING (FOR EXAMPLE, SINGLE SPACED WITH SINGLE
CHARACTER INDENTS), YET PRODUCE THE DRAFT AND FINAL COPIES
OF WORK IN WHATEVER STYLE IS REQUIRED.
!
.PAGE
.C ^PARAGRAPHING
.P +5 1 5
.PP ^THE PARAGRAPHING FACILITY IN <RNF ENABLES FAST, CONVENIENT
TEXT ENTRY IN A NATURAL FORMAT.
.PP ^PARAGRAPHING IS SET UP BY THE _.<P COMMAND, WHICH HAS THE
FORMAT:
.B .I 9 _.<P INDENT SPACING TEST
.PP ^INDENT IS THE COLUMN AT WHICH THE FIRST LINE OF EACH
PARAGRAPH IS TO BEGIN, SPECIFIED EITHER AS AN UNSIGNED COLUMN
NUMBER OR AS A POSITIVE OR NEGATIVE OFFSET FROM THE CURRENT
LEFT MARGIN. ^SPACING SPECIFIES THE NUMBER OF SPACES BETWEEN
PARAGRAPHS, WHERE 1 IS THE EQUIVALENT OF A <.S 1 COMMAND,
2 IS THE EQUIVALENT OF A <.S2 COMMAND, ETC. ^TEST
SPECIFIES THE NUMBER OF LINES WHICH
MUST REMAIN ON THE CURRENT PAGE, OR THE PARAGRAPH IS BEGUN
ON THE NEXT PAGE.
.PP ^THE DEFAULT IS:
.B .I 9 _.<P +0 1 3
.PP ^THE _.<PP COMMAND DENOTES THE BEGINNING OF A NEW PARAGRAPH.
.AP
^AS AN ALTERNATIVE (OR IN ADDITION) TO THE _.<PP COMMAND, THE USER
CAN SELECT AUTOPARAGRAPH MODE BY MEANS OF THE _.<AP COMMAND.
^IF _.<AP IS IN EFFECT, A BLANK AT THE BEGINNING OF ANY LINE
(OR A BLANK LINE)
IS TAKEN TO BE A _.<PP COMMAND.
(^NOTE THAT A BLANK LINE IN _.<NOAP MODE IS TAKEN TO BE A _.<B
COMMAND.)
^THE AUTOPARAGRAPH CONVENTIONS ALLOW A TYPIST TO ENTER AND WORK
WITH ALL TEXT IN A READABLE FORMAT WHICH IS CONVENIENT FOR
COMPUTER EDITING (FOR EXAMPLE, SINGLE SPACED WITH SINGLE CHARACTER
INDENTS), YET PRODUCE THE DRAFT AND FINAL COPIES OF WORK
IN WHATEVER STYLE IS REQUIRED.
.PAGE
.HL 1 <HEADER <LEVEL <EXAMPLES
.ASIS
.AP
.HL 2 <HOW <TO <USE <HEADER <LEVELS
^THE _.<HL COMMAND ENABLES THE TYPIST TO ORGANIZE TEXT INTO
SECTIONS, AND SECTIONS WITHIN SECTIONS, WITH SEQUENTIAL NUMBERS
WHICH ARE CHANGED BY THE COMPUTER IF SECTIONS ARE ADDED OR
DELETED.
.HL 3 ^FORMAT
^THE FORMAT OF THE _.<HL COMMAND IS:
.S 1 .I 9 _.<HL NUMBER TEXT
^THE NUMBER IS THE LEVEL NUMBER, WHERE 1 IS THE OUTERMOST
LEVEL, 2 IS THE NEXT INNER LEVEL, ETC. ^THE TEXT IS THE
TITLE OF THE SECTION.
.HL 3 ^EFFECT OF THE ^COMMAND
^THE _.<HL COMMAND STARTS A SECTION AT THE LEVEL SPECIFIED AND
USES TEXT AS THE HEADER. ^THE NUMBER CAN BE IN THE RANGE
FROM 1 TO 5. ^THE SECTION NUMBER OUTPUT IS IN THE FORM
I.J.K.L.M. ^IF THE DOCUMENT IS CHAPTER ORIENTED, I IS THE
CHAPTER NUMBER; OTHERWISE IT IS THE NUMBER OF _.<HL 1 COMMANDS
SINCE THE BEGINNING OF THE INPUT TEXT.
^THE COMMAND DOES A RETURN, A TEST PAGE 9, AND PRECEDES THE
SECTION IDENTIFIER WITH 3 BLANK LINES.
^THE MARGINS AND OTHER ENVIRONMENT ARE RESET TO THE VALUES
THEY HAD BEFORE THE FIRST _.<HL COMMAND (IN THE CHAPTER).
^THE SECTION NUMBER BEGINS AT THE LEFT MARGIN, FOLLOWED
BY TWO SPACES, FOLLOWED BY THE TEXT, IF ANY.
^A SINGLE BLANK LINE IS INSERTED AFTER THE HEADER.
.HL 2 <INCREMENTING
^SECTION NUMBERS ARE INCREMENTED BY 1 AT THE LEVEL OF THE
CURRENT _.<HL COMMAND.
^EACH TIME LEVELS ARE NESTED (FOR EXAMPLE, _.<HL 1 FOLLOWED
BY _.<HL 2), THE NUMBERING IS RESTARTED AT 1 FOR THE HIGHER
NUMBERED LEVEL.
!
.PAGE
.AP
.HL 2 <HOW <TO <USE <HEADER <LEVELS
^THE _.<HL COMMAND ENABLES THE TYPIST TO ORGANIZE TEXT INTO
SECTIONS, AND SECTIONS WITHIN SECTIONS, WITH SEQUENTIAL NUMBERS
WHICH ARE CHANGED BY THE COMPUTER IF SECTIONS ARE ADDED OR
DELETED.
.HL 3 ^FORMAT
^THE FORMAT OF THE _.<HL COMMAND IS:
.S 1 .I 9 _.<HL NUMBER TEXT
^THE NUMBER IS THE LEVEL NUMBER, WHERE 1 IS THE OUTERMOST
LEVEL, 2 IS THE NEXT INNER LEVEL, ETC. ^THE TEXT IS THE
TITLE OF THE SECTION.
.HL 3 ^EFFECT OF THE ^COMMAND
^THE _.<HL COMMAND STARTS A SECTION AT THE LEVEL SPECIFIED AND
USES TEXT AS THE HEADER. ^THE NUMBER CAN BE IN THE RANGE
FROM 1 TO 5. ^THE SECTION NUMBER OUTPUT IS IN THE FORM
I.J.K.L.M. ^IF THE DOCUMENT IS CHAPTER ORIENTED, I IS THE
CHAPTER NUMBER; OTHERWISE IT IS THE NUMBER OF _.<HL 1 COMMANDS
SINCE THE BEGINNING OF THE INPUT TEXT.
^THE COMMAND DOES A RETURN, A TEST PAGE 9, AND PRECEDES THE
SECTION IDENTIFIER WITH 3 BLANK LINES.
^THE MARGINS AND OTHER ENVIRONMENT ARE RESET TO THE VALUES
THEY HAD BEFORE THE FIRST _.<HL COMMAND (IN THE CHAPTER).
^THE SECTION NUMBER BEGINS AT THE LEFT MARGIN, FOLLOWED
BY TWO SPACES, FOLLOWED BY THE TEXT, IF ANY.
^A SINGLE BLANK LINE IS INSERTED AFTER THE HEADER.
.HL 2 <INCREMENTING
^SECTION NUMBERS ARE INCREMENTED BY 1 AT THE LEVEL OF THE
CURRENT _.<HL COMMAND.
^EACH TIME LEVELS ARE NESTED (FOR EXAMPLE, _.<HL 1 FOLLOWED
BY _.<HL 2), THE NUMBERING IS RESTARTED AT 1 FOR THE HIGHER
NUMBERED LEVEL.
.HL 1 <EXAMPLES OF <LISTS
.ASIS
.C ^USING ^LISTS
.AP
^AUTOMATICALLY NUMBERED LISTS CAN BE GENERATED BY THE <.LIST,
<.LE, AND <.ENDLIST COMMANDS. ^THE <.LIST COMMAND HAS THE
FORMAT:
.I 9 <.LIST SPACING
WHERE SPACING IS A NUMBER IN THE RANGE 1 THROUGH 5 WHICH
SPECIFIES THE SPACING TO BE USED WITHIN THE LIST.
^THE LIST IS GENERATED AS FOLLOWS:
.LIST 1
.LE ^EACH LIST ELEMENT IS PRECEDED BY THE <.LE COMMAND.
.LE ^LIST ELEMENTS ARE SEPARATED BY "SPACING" BLANK LINES.
.LE ^EACH ELEMENT IS AUTOMATICALLY NUMBERED BEGINNING AT
1 BY 1.
.LE ^THE LIST IS TERMINATED BY THE <.ENDLIST COMMAND (WHICH
ALSO RESETS THE MARGINS AND SPACING).
.LE ^LISTS CAN BE NESTED WITHIN LISTS. ^THIS IS HANDLED
AS FOLLOWS:
.LIST 1
.LE ^THE LEFT MARGIN IS SET 9 COLUMNS TO THE RIGHT FOR
THE OUTERMOST LIST, AND 4 COLUMNS TO THE RIGHT FOR EACH
INNER LIST.
.LE ^EACH <.LIST MUST BE TERMINATED BY A MATCHING <.ENDLIST.
^THE <.ENDLIST RESETS THE MARGINS AND SPACING AS THEY WERE
BEFORE THE <.LIST COMMAND.
.LE ^FOR USERS OF AUTOPARAGRAPHING, THE PARAGRAPH MARGIN
IS SET TO COINCIDE WITH THE LEFT MARGIN, AND PARAGRAPH
SPACING IS SET TO THE LIST SPACING PLUS 1.
^THIS MEANS THAT AUTOPARAGRAPHING CAN BE CONVENIENTLY
USED AT ANY LIST LEVEL.
^THE PARAGRAPH VALUES ARE RESET BY THE <.ENDLIST COMMAND.
.ENDLIST
.LE ^LISTS CAN BE NESTED UP TO 5 LEVELS.
.ENDLIST
^THE LIST FACILITY CAN BE A SIGNIFICANT CONVENIENCE FOR
THE TYPIST.
!
.PAGE
.C ^USING ^LISTS
.AP
^AUTOMATICALLY NUMBERED LISTS CAN BE GENERATED BY THE <.LIST,
<.LE, AND <.ENDLIST COMMANDS. ^THE <.LIST COMMAND HAS THE FORMAT:
.I 9 <.LIST SPACING
WHERE SPACING IS A NUMBER IN THE RANGE 1 THROUGH 5 WHICH
SPECIFIES THE SPACING TO BE USED WITHIN THE LIST.
^THE LIST IS GENERATED AS FOLLOWS:
.LIST 1
.LE ^EACH LIST ELEMENT IS PRECEDED BY THE <.LE COMMAND.
.LE ^LIST ELEMENTS ARE SEPARATED BY "SPACING" BLANK LINES.
.LE ^EACH ELEMENT IS AUTOMATICALLY NUMBERED BEGINNING AT
1 BY 1.
.LE ^THE LIST IS TERMINATED BY THE <.ENDLIST COMMAND (WHICH
ALSO RESETS THE MARGINS AND SPACING).
.LE ^LISTS CAN BE NESTED WITHIN LISTS. ^THIS IS HANDLED
AS FOLLOWS:
.LIST 1
.LE ^THE LEFT MARGIN IS SET 9 COLUMNS TO THE RIGHT FOR
THE OUTERMOST LIST, AND 4 COLUMNS TO THE RIGHT FOR EACH
INNER LIST.
.LE ^EACH <.LIST MUST BE TERMINATED BY A MATCHING <.ENDLIST.
^THE <.ENDLIST RESETS THE MARGINS AND SPACING AS THEY WERE
BEFORE THE <.LIST COMMAND.
.LE ^FOR USERS OF AUTOPARAGRAPHING, THE PARAGRAPH MARGIN
IS SET TO COINCIDE WITH THE LEFT MARGIN, AND PARAGRAPH
SPACING IS SET TO THE LIST SPACING PLUS 1.
^THIS MEANS THAT AUTOPARAGRAPHING CAN BE CONVENIENTLY
USED AT ANY LIST LEVEL.
^THE PARAGRAPH VALUES ARE RESET BY THE <.ENDLIST COMMAND.
.ENDLIST
.LE ^LISTS CAN BE NESTED UP TO 5 LEVELS.
.ENDLIST
^THE LIST FACILITY CAN BE A SIGNIFICANT CONVENIENCE FOR
THE TYPIST.
.PAGE
.HL 1 <CHANGE <BAR <EXAMPLES
.ASIS
.BAR .AP
.C ^USING ^CHANGE ^BARS
.B
^CHANGE BARS ARE USED TO FLAG TEXT WHICH HAS BEEN
ALTERED SINCE THE LAST VERSION OF A DOCUMENT, AND ARE
COMMONLY FOUND ONLY IN TECHNICAL WRITING,
.BB WHERE THE READER MUST BE ALTERTED TO NEW FEATURES. .EB
^THE <.BAR COMMAND ENABLES CHANGE BARS, AND HAS THE IMMEDIATE
EFFECT OF SHIFTING ALL OUTPUT TEXT RIGHT
.BB THREE .EB
SPACES.
^THE <.NOBAR DISABLES CHANGE BARS. ^USUALLY, THE .BAR COMMAND
COMMAND APPEARS BEFORE ANY TEXT IN A DOCUMENT, SO THE LEFT MARGIN
IN THE OUTPUT IS UNIFORM.
^THE <.BB (^BEGIN ^BAR) COMMAND TURNS ON CHANGE BARS. ^THAT IS,
<.BB CAUSES A _| TO APPEAR AT THE LEFT MARGIN FOR ANY LINES WHICH
ARE OUTPUT AFTER THE <.BB
.BB (INCLUDING BLANK LINES WHICH ARE A PART OF THE TEXT). .EB
^THE <.EB (^END ^BAR) COMMAND SIGNIFIES THE END OF THE CHANGE
BEGUN BY <.BB, AND TURNS OFF CHANGE BARS.
.BB ^SPACES CAUSED BY THE <.RIGHT COMMAND APPEAR TO THE LEFT OF
THE THREE EXTRA COLUMNS USED BY THE <.BAR FEATURE.
^BLANK LINES WHICH APPEAR AS A PART OF CHANGED TEXT ARE
ALSO FLAGGED BY A BAR.
!
.PAGE
.BAR .AP
.C ^USING ^CHANGE ^BARS
.B
^CHANGE BARS ARE USED TO FLAG TEXT WHICH HAS BEEN
ALTERED SINCE THE LAST VERSION OF A DOCUMENT, AND ARE
COMMONLY FOUND ONLY IN TECHNICAL WRITING,
.BB WHERE THE READER MUST BE ALTERTED TO NEW FEATURES. .EB
^THE <.BAR COMMAND ENABLES CHANGE BARS, AND HAS THE IMMEDIATE
EFFECT OF SHIFTING ALL OUTPUT TEXT RIGHT
.BB THREE .EB
SPACES.
^THE <.NOBAR COMMAND DISABLES CHANGE BARS. ^USUALLY, THE .BAR COMMAND
APPEARS BEFORE ANY TEXT IN A DOCUMENT, SO THE LEFT MARGIN IN THE OUTPUT
IS UNIFORM.
^THE <.BB (^BEGIN ^BAR) COMMAND TURNS ON CHANGE BARS. ^THAT IS,
<.BB CAUSES A _| TO APPEAR AT THE LEFT MARGIN FOR ANY LINES WHICH
ARE OUTPUT AFTER THE <.BB
.BB (INCLUDING BLANK LINES WHICH ARE A PART OF THE TEXT). .EB
^THE <.EB (^END ^BAR) COMMAND SIGNIFIES THE END OF THE CHANGE
BEGUN BY <.BB, AND TURNS OFF CHANGE BARS.
.BB ^SPACES CAUSED BY THE <.RIGHT COMMAND APPEAR TO THE LEFT OF
THE THREE EXTRA COLUMNS USED BY THE <.BAR FEATURE.
^BLANK LINES WHICH APPEAR AS A PART OF CHANGED TEXT ARE
ALSO FLAGGED BY A BAR.
.BR .EB
.EB
.NOBAR .PAGE
.HL 1 <TAB <EXAMPLES
.ASIS
.C ^USING <RNF ^TABS
.AP
<RNF TAB STOPS ARE SET BY THE <.TABS COMMAND. ^THE FORMAT IS:
.I 9 <.TABS C1 C2 <... C15
WHERE C1 THROUGH C15 ARE CHARACTER POSITIONS, IN ASCENDING ORDER,
WHERE THE TAB STOPS ARE TO BE SET.
(^CHARACTER POSITIONS ARE NUMBERED BEGINNING AT 1). ^TO WORK
CORRECTLY, TAB STOPS MUST NOT BE SET BEYOND THE RIGHT MARGIN.
^TABS ARE USED BY THE <.T COMMAND, WHICH MEANS "BEGIN THE NEXT
WORD AT THE NEXT TAB STOP".
^FOR EXAMPLE, THE FOLLOWING
.I 9 <.TABS 10 20 30 40
.BR .I 9 ^LINE <.T THIS <.T UP <.T IN <.T COLUMNS
PRODUCES
.TABS 19 29 39 49
.I 9 ^LINE .T THIS .T UP .T IN .T COLUMNS
^THE FOLLOWING FEATURES SHOULD BE NOTED:
.TAB 30 .P -21 2 5 .LM 30
^JUSTIFICATION .T ^HAVING TABS IN A LINE DOES NOT SUPPRESS
JUSTIFICATION. ^ONLY THE TEXT AFTER THE LAST TAB IN A LINE IS
BLANK PADDED. ^THIS PERMITS CONVENIENT USE OF "HANGING" TITLES
AND INDENTATION.
^LEFT/^RIGHT .T ^TABS PRODUCED BY <.T CAUSE THE FOLLOWING
WORD TO BEGIN AT THE NEXT TAB STOP. ^THE <.RT
COMMAND CAUSES THE FOLLOWING WORD TO END AT THE
NEXT TAB STOP. ^THIS PERMITS CREATING TABLES OF NUMERIC
DATA.
!
.PAGE
.C ^USING <RNF ^TABS
.AP
<RNF TAB STOPS ARE SET BY THE <.TABS COMMAND. ^THE FORMAT IS:
.I 9 <.TABS C1 C2 <... C15
WHERE C1 THROUGH C15 ARE CHARACTER POSITIONS, IN ASCENDING ORDER,
WHERE THE TAB STOPS ARE TO BE SET.
(^CHARACTER POSITIONS ARE NUMBERED BEGINNING AT 1). ^TO WORK
CORRECTLY, TAB STOPS MUST NOT BE SET BEYOND THE RIGHT MARGIN.
^TABS ARE USED BY THE <.T COMMAND, WHICH MEANS "BEGIN THE NEXT
WORD AT THE NEXT TAB STOP".
^FOR EXAMPLE, THE FOLLOWING
.I 9 <.TABS 10 20 30 40
.BR .I 9 ^LINE <.T THIS <.T UP <.T IN <.T COLUMNS
PRODUCES
.TABS 19 29 39 49
.I 9 ^LINE .T THIS .T UP .T IN .T COLUMNS
^THE FOLLOWING FEATURES SHOULD BE NOTED:
.TAB 30 .P -21 1 5 .LM 30
^JUSTIFICATION .T ^HAVING TABS IN A LINE DOES NOT SUPPRESS
JUSTIFICATION. ^ONLY THE TEXT AFTER THE LAST TAB IN A LINE IS BLANK
PADDED. ^THIS PERMITS CONVENIENT USE OF "HANGING" TITLES AND
INDENTATION.
^LEFT/^RIGHT .T ^TABS PRODUCED BY <.T CAUSE THE FOLLOWING
WORD TO BEGIN AT THE NEXT TAB STOP. ^THE <.RT
COMMAND CAUSES THE FOLLOWING WORD TO END AT THE
NEXT TAB STOP. ^THIS PERMITS CREATING TABLES OF NUMERIC
DATA.
.PAGE
.HL 1 <MACRO <EXAMPLES
.ASIS
.MACRO BBCB 1 = .B .B .C .BBCB1 .B
.MACRO NOTE * = .NOTEA .NOTEB
.MACRO NOTEA = .SAV .TP 8 .SP 1 .LM +15 .RM -15 .P +0 1 5
.MACRO NOTEB = .BBCB .NOTE1
.MACRO ENOTE = .B .B .RES
.AP
.C ^THE <NOTE ^COMMAND
^THIS EXAMPLE SHOWS THE DEFINITION OF A USEFUL COMMAND VIA
THE <.MACRO FACILITY.
.NOTE ^WARNING
^THIS COMMAND CAN BE HABIT-FORMING. ^USE IT SPARINGLY.
.ENOTE
^TRY IT, YOU'LL LIKE IT!
!
.PAGE
.MACRO BBCB 1 = .B .B .C .BBCB1 .B
.MACRO NOTE * = .SAV .TP 8 .SP 1 .LM +15 .RM -15 .P +0 1 5 .BBCB .NOTE1
.MACRO ENOTE = .B .B .RES
.AP
.C ^THE <NOTE ^COMMAND
^THIS EXAMPLE SHOWS THE DEFINITION OF A USEFUL COMMAND VIA THE <.MACRO
FACILITY.
.NOTE ^WARNING
^THIS COMMAND CAN BE HABIT-FORMING. ^USE IT SPARINGLY.
.ENOTE
^TRY IT, YOU'LL LIKE IT!
.MACRO CHTTL = ^HOW#^TO#^RUN#<RNF
.CH <HOW <TO <RUN <RNF
<MS-DOS <AND <CPM <MICROCOMPUTERS
^TO PRINT A FILE CALLED PAPER.RNF ON THE <LST: DEVICE (NORMALLY
THE PRINTER), TYPE:
.EX <RNF PAPER.RNF
.EEX
^THIS ASSUMES CONTINUOUS SHEET FEEDING. FOR SINGLE-SHEET FEED, OR
FOR A LISTING TO ANOTHER FILE OR DEVICE, TYPE
.EX <RNF
.EEX
AND THE <RNF PROGRAM WILL PROMPT YOU FOR THE NAME OF THE LISTING FILE
AND WHETHER CONTINUOUS FEED OR SINGLE-SHEET FEED IS DESIRED.
<CYBER
<RNF RESIDES IN <PASCLIB. ^TO ACCESS <RNF, USE THE CONTROL CARDS
.EX <ATTACH,PASCLIB.
.BR <LIBRARY,PASCLIB.
.EEX
<RNF DOES AN AUTOMATIC <RFL,30000.
^THIS IS SUFFICIENT CORE TO PROCESS THIS MANUAL. ^DOCUMENTS WITH
MANY MACRO DEFINITIONS MAY NEED TO INCREASE THE FIELD LENGTH --
FIGURE 40 WORDS PER MACRO DEFINITION.
<RNF IS EXECUTED BY A COMMAND OF THE FORM:
.EX <RNF,<LFN1,LFN2,LFN3.
.EEX
WHERE LFN1 IS THE <RNF INPUT SOURCE, LFN2 IS THE FILE
WHICH IS TO RECEIVE AN ALL UPPER CASE COPY OF THE FORMATTED OUTPUT TEXT,
AND LFN3 IS THE FILE WHICH IS TO RECEIVE AN UPPER/LOWER CASE
COPY OF THE FORMATTED OUTPUT TEXT. ^THE DEFAULT NAMES OF LFN1, LFN2,
AND LFN3 ARE <INPUT, <OUTPUT, AND <ASCII95, RESPECTIVELY.
^IF ANY ERROR MESSAGES ARE GENERATED (FOR EXAMPLE, YOU FORGET
TO DEFINE A MACRO, AND THEN ATTEMPT TO USE IT) THESE ARE WRITTEN
TO THE UPPER CASE ONLY FILE (<DEFAULT: <OUTPUT).