TMAX sami@csli.stanford.edu, gilmurray@sumex-aim.stanford.edu TMAX stands for Tedit Macros And eXtensions and it enhances TEdit by providing a convenient way to do things such as numbering, indexing, creating a table of contents, and more. Usually these sort of things are done with Scribe. Although Scribe is very powerful, it consumes a significant number of mainframe cycles. Using TMAX reduces the load on the mainframe and users without access to a mainframe are able to use some Scribe-like features. This document assumes you are familiar with TEdit. If you aren't, please read the first part of the Text Editing section in The Lisp Library Packages Manual (i.e. Using TEdit) before proceeding. All the features described here are merely additions to the TEdit document. TMAX does not affect your text in any way. When you invoke one of these features, TMAX inserts a special character (i.e. an Image Object) into your document at the current cursor position. The features described in this document are also used in this document. For example, the note reference on "Scribe" above was generated with the EndNote feature of TMAX. When TMAX is loaded, it adds a new entry to the bottom of the main TEdit pop-up menu (figure ???). The new menu looks like this: m|@@>@3`@3f @3f`@>f` @0f`@0f`@0>8@@@@@@@10@0| @30@10 @10@30@@@@@@@`@`@lϞ@ٳlٳ@ٰlٿ@ٰlٰ@ٳlٳ@ٞgϞ@@@@@@@@>@f@f@f@f@>@@@@@@@@>xϙ@ 3f͘lٕ@ 3fي@ 3f ٔ@ 3f͘lو@ o>x3ϐ@ @ @ @@@?q@ q@ {<@ {͆f͘@ n͆~͘@ nϏ`͘@ nفf͘@ dف<@@@@ Figure ???, main TEdit menu When TMAX Menu is buttoned the following menu is attached to the top of your TEdit window: }{9׷x3:q:vu?9カmomoز[e߭{lU6\osma6s3m߬7mU[m}mo}mm}{8س17;cnm_7 0~ ` 01  ` 7>x@1}ϟ QHÉ\D6l|{03mlcٛ0 QI$I"bD6lə03aٛ JHB(6l31 {?1a c ٛ JH 2B(6l0?1 01alcٛ0 DI$I"Bώx0ٰa ͝3aٙ DHÉBa  ` ? `x  0  0  `` @00|} | |yǀ g>x6x @.(<>f͛3 ,0fl l36l٘͐3x6 ~1#$$0f͛3 0 f o6l٘{8||p ~p3`ff A@3<>~c`|f͛|?f ~>G|3`c3``f͘f 0f A D@ 3fc6f`1͚`fl3f͚` A"DHD 3b~8`|26f6ٳf I!3&$MP m0bbr9``l6f I!"$'g60ϱ?{{6f E!"$$`600{1{6f C#"&$H2166pc3<99| A"%È |~3?f`0`  0` `   6  001 0c1  ! 7|1fyc1 <<` @.y88ن11f͙c1f33f` @!1"&$DD11Fc1 ~3~ @!!#$8|6611c1 `ͳ3` @!!"$@611fc1 fͳ3f` !!!"$$DDxfa0 <3<` !#88 0`?0l $0`0``` 73癰|` %äp6lٞ6l>fcl`6l͘6m6@ &$d$6lߌ6o0fc6f٘6m $$$6l 6l0fcc6g6m $$$ 6lٞ6l0fc36c16m4 $$d 6g33癿f;313 $#p  0 a 0~ $1a 0` 1x<33 `` %äp061ٳfx36l 6g͛3|6a3 &$d $00ٳ~07 7͛`g $$$1ٳ`06 6͛`m $$$ 1ͱٳfx 6c0 6g͛3`6m3 $$d 0xٟ< 30 ``gٙ $#p   Figure ???, TMAX menu There are three type of fields in this menu distinguished by their font. The light face fields (e.g. Miscellany:, EndNotes:, etc.) are simply labels specifying the nature of the items on the rest of the line. These label fields cannot be buttoned. The bold italic fields (i.e. Set AutoUpdate, NGroup Menu, and NGroup Text) are 2-way toggle items. When they are off, they are displayed in normal video (as they are in figure ???). When they are on, they are displayed in reverse video. Buttoning these items complements the current setting. Finally, the normal bold face items (everything except labels and toggle fields) are used to invoke the corresponding TMAX feature. We will first give a quick overview of each item and then go into the details of each item. Command Overview Miscellany: Update When you use TMAX to do some sort of numbering (Endnotes for example), TMAX inserts a "marker" rather than actual number. Buttoning this item will convert all the markers to their corresponding numeric values. TMAX shows you feature it is updating in the TEdit prompt window. Set AutoUpdate When this toggle switch is on (i.e. it appears in reverse video in the TMAX menu), all numbering markers are immediately updated to their corrsponding numeric value when they are inserted. Current Date/Time Buttoning this item inserts the current date into your document at the current cursor position. If you then button the inserted date, a menu will pop up showing the various ways the date or time can be displayed. The date and time are automatically updated each time you GET the document. For example, the last time we did a GET on this file was ???/???. EndNotes: Add Endnote Buttoning this item inserts an Endnote marker at the current cursor position. The Endnote marker is a superscript "^n". You will also be prompted for the text corresponding to this Endnote. Insert Endnotes This item inserts the title line "Notes" followed by the Endnote numbers and corresponding text. The insertion is always after the last line in your TEdit document. Set Style Buttoning this item pops up the Endnote fonts menu. You can use this pop-up menu to change the font of the Endnote numbers, text, and/or title line (i.e. "Notes"). References: To be filled in later. Number Groups: NGroup Menu When this toggle switch is on (i.e. it appears in reverse video in the TMAX menu), the number group (NGroup) menu "tree" is displayed in a window attached to the top of your TEdit window. The number group menu is a tree structure showing the hierarchy of the number groups you define. You insert number group markers by left buttoning items in this window and middle buttoning them allows you to change their font and/or format. NGroup Text This is another toggle switch (that appears in reverse video when it's on). When this switch is on, you will be prompted for a text string each time you insert a NGroup marker. This text string serves two purposes. First, it is a heading for the chapter, section, etc. you have numbered. Second, you can include the NGroup marker and its corresponding text string in the table of contents. New NGroup This item allows you to create new number groups. When it's buttoned, it first turns on NGroup Menu if it was off. It then prompts you for the name of the number group. This name is the NGroup marker. Finally, TMAX prompts you for the parent of this NGroup marker (i.e. by parent we mean the parent node in the number group menu tree). Obviously the first NGroup marker has no parents. When you insert an NGroup marker (by buttoning the appropriate item in the NGroup Menu tree), TMAX will insert the marker, enclosed in square brackets, at the current cursor position. Contents File: Create TOC Buttoning this item creates a Table-Of-Contents (TEdit) file. You must first specify the name of the TOC file via the TOC Filename: item. Each line in the TOC consists of a number group possibly followed by a text string (if NGroup Text was on when you inserted the NGroup), a dotted leader, and the page number on which this NGroup appears. NOTE...You should hardcopy your document before creating the TOC file. The reason for this is TEdit only knows the page numbers while the document is being hardcopied. If you create the TOC without first hardcopying your TEdit document, the page numbers in the TOC will be printed as "NIL". View TOC Buttoning this item first creates the TOC file (via Create TOC) and then prompts you for a TEdit window where TMAX will display the TOC file. This item is exactly equivalent to buttoning Create TOC, opening another TEdit window, and GETting the TOC file yourself. TOC Filename: This item allows you to specify the name of the TOC file. When this item is buttoned, the cursor will appear just to the right of this item. You then type the name of the TOC file and terminate it with a carriage return. You can edit this filename string anytime. If you have already terminated the string, just button the item again. The editing features available are the same as those in the EXEC window. Indices: Index When this item is buttoned, TMAX will prompt you for an index key. It will then insert the string "[Index your-key]" in your document at the current cursor position. TMAX uses these keys to sort the indices and the sorting is case independent. IndexEntry This is a fancy form of indexing. When you button IndexEntry, TMAX first prompts you for the key to sort on (just like Index). It then prompts you for the entry (the text and font of what to print instead of printing the key as Index does). Finally it prompts you for the index page number option. There are three options; print the normal page number, print a fixed page number that you supply, or don't print any page number. TMAX then inserts the following string into your document at the current cursor position: "[Index Key=key,Entry=entry,Number-Option]" Known Indices Buttoning this item brings up a menu of the Indices and IndexEntries specified so far. You can then insert an Index or IndexEntry by simply buttoning the appropriate item in this pop-up menu. Indices are simple items but IndexEntries has subitems because several IndexEntries can have the same Key but completely different Entries, fonts, and/or Number options. To insert an IndexEntry, you must button the appropriate subitem. Indices File: Create Index Buttoning this item creates a sorted Index (TEdit) file. You must first specify the name of the Index file via the Index Filename: item. For simple indices, each line in the Index file consists of the index key followed by the page numbers (separated by commas) on which this index key appears. IndexEntries are treated a little different. Each IndexEntry is printed on a new line. NOTE...You should hardcopy your document before creating the Index file. The reason for this is TEdit only knows the page numbers while the document is being hardcopied. If you create the Index without first hardcopying your TEdit document, the page numbers in the Index will be printed as "[Pages (?)]". The reason for this will be explained later. View Index Buttoning this item first creates the Index file (via Create Index) and then prompts you for a TEdit window where TMAX will display the Index file. This item is exactly equivalent to buttoning Create Index, opening another TEdit window, and GETting the Index file yourself. Index Filename: This item allows you to specify the name of the Index file. When this item is buttoned, the cursor will appear just to the right of this item. You then type the name of the Index file and terminate it with a carriage return. You can edit this filename string anytime. If you have already terminated the string, just button the item again. The editing features available are the same as those in the EXEC window. End of TMAX.TED($$(H(HH($H(($($(GACHA  HELVETICA  HELVETICA  HELVETICA  HELVETICA  HELVETICA HELVETICA 8!   'S1C BMOBJ.GETFN3 HELVETICA  M  BMOBJ.GETFN3 HELVETICA    c       X  v ^ j 4 } C c2M 2 ;h)n + sV / 6  EG} z