PS TEXT FORMAT Reference Manual
Introduction to TFORM
11387 Tandem Computers Incorporated 3–101
You can put macro definitions anywhere you want in your document,
but it’s a good idea to group them together in one place. If you put
them in a separate file and read them in, several different documents
can share them.
You can abbreviate
macro-names
, just as you can TFORM-supplied
macro and command names. For this reason, any name you use must
be unique within its first three characters. You can use 1- and 2-letter
names if you wish, but they can’t be abbreviated.
All the commands that make up a MACRO construct must be in a
single input file. You should therefore check that any MACRO
construct contained in a sourced-in file is both begun and ended in that
file.
You must type a corresponding ENDMACRO command for every
MACRO BEGIN or MACRO APPEND command. If you put a
macro-name
in an ENDMACRO command, it must agree with the
name in the most recent MACRO BEGIN or MACRO APPEND
command.
As a general rule, it’s a good idea to declare as LOCAL all variables that
are relevant only within the macro.
If you include a DEFINE command in a macro, any character you
redefine, except the trigger character, retains its new definition when
you return from the macro. However, if you change the trigger
character, it reverts to its original definition when the macro ends.
See Appendix G for examples of MACRO constructs and a macro
invocation command.