home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Source Code 1993 July / THE_SOURCE_CODE_CD_ROM.iso / languages / elisp / packages / tpu.el / text0000.txt < prev   
Encoding:
Text File  |  1990-07-22  |  100.2 KB  |  2,112 lines

  1.  
  2. Hack, hack, hack.
  3. This represents a serious series of hacks to edt.el (as
  4. supplied with GNU Emacs) in order to more closely simulate
  5. the edt editor.  I was wrong when I called it a TPU emulator.
  6. TPU would be tough to emulate in Emacs since TPU is a language.
  7. What I meant was that tpu.el simualtes the EDT interface to TPU.
  8.  
  9. Well, with a few extensions.
  10.  
  11. There's a truly nice new style of abbrevs that uses alists.
  12. Try typing the partial word "Heu", then GOLD-H a few times.
  13. See where the cursor goes?
  14.  
  15. I don't have up to date docs for my toy, but I'll include
  16. what I gave the students last semester, along with tpu.el
  17.  
  18. Have fun, mail me bugs, questions, chocolate chip cookies.
  19.  
  20. Jeff
  21.  
  22. CADIF Swamp
  23. 172 Hollister Hall
  24. Cornell University
  25. Ithaca, NY 14853
  26.  
  27. ----------
  28. GUIDE
  29. ---------
  30. The long-heralded emulation of the highly acclaimed BOBTPU is here!
  31.  
  32. What is bobtpu?  It's simply the most extended editor ever.  Written by
  33. system programmer par-excellence Bob Covey, it was formerly available
  34. only on VMS systems supporting tpu.  Now, through the miracle of modern
  35. pharmaceuticals, Jeff Kowalski has just completed a complete emulation
  36. of the incredible editor under Unix.  That's right, UNIX!  For the first
  37. time ever in the history of CADIF, the Unix user, previously hindered by
  38. such evil tortures as vi and ed, will finally be able to complete work!
  39.  
  40. "How can I, so simple an undeserving a student, gain access to the
  41. fruits of Jeff's laudable accomplishment?"  Well, I will tell you.  But
  42. first, you must suffer through the incredible mind-expanding description
  43. of what the bobtpu emulator can do for you (or you must turn the page).
  44.  
  45. Firstly, the bobtpu emulator (hereafter called bobtpu) is written in
  46. elisp, which is the emacs native language.  This means that the
  47. behind-the-scenes editor is GNU Emacs, not VAX TPU.  There are,
  48. therefore, a few subtle differences between VMS bobtpu and Unix bobtpu.
  49. For the most part, however, you'll probably never notice.  If you have
  50. questions, you should refer to both the EDT and Emacs guides.  Ask the
  51. room monitor for them.
  52.  
  53. At the very least, bobtpu is an EDT emulator.  That means that the
  54. arrows work and the keypad at the right has special meaning, among other
  55. things.  If you are not familiar with EDT, ask the room monitor for
  56. information (a manual or online CAI on VMS).  In addition to the basics
  57. of EDT, bobtpu provides all of these extras:
  58.  
  59.                 TERMINOLOGY
  60.  
  61.    The GOLD key is the PF1 key on DEC-style keyboards, F9 on SGI style
  62. keyboards.  It is not a modifier in the same sense as the shift or
  63. control keys: you don't hold it down while striking another key, you
  64. simply strike it first.  Thus GOLD-a means strike PF1, then the letter
  65. "a."  On the VMS version, GOLD-a and GOLD-A are equivalent.  On my unix
  66. version, the letters are different, so we have twice the functionality.
  67. In general, the lowercase version is the same as the VMS version, while
  68. the uppercase version, since it is harder to type, performs an extended
  69. operation, or an operation with no query.  For example, GOLD-q quits,
  70. but asks about saving unsaved files first; GOLD-Q quits without asking.
  71. In the cases where case is insignificant, I will represent the sequence
  72. as GOLD-[Aa] which means use either case.
  73.    If you get stuck in some crazy mode, you can type CTRL-G (cancel) to
  74. get out.  So if you're being prompted for a filename and you don't know
  75. why (ie you're lost), just hit a CTRL-G.
  76.  
  77.                 MULTIPLE FILES
  78.  
  79.    It is possible to edit many files at a time.  They may be entered
  80. using wildcards or lists on the command line. Any files which are not
  81. found and do not contain wildcards will be created and marked as
  82. modified. You are placed in the first file read/created (if no files are
  83. found and all specifications have wildcards, you will be placed in a
  84. default buffer).  The files are marked for update on exit.  A status
  85. line shows information about the current buffer, just as in Emacs.
  86.  
  87.     The easiest way to move between files is by hitting GOLD-W to "walk"
  88. to the next one.  GOLD-w will "walk" to the previous one.  GOLD-f will
  89. ask you for the name of a file to jump to, it will try to find one it
  90. has that best matches the name you give.  GOLD-F will do the same, but
  91. will show the selected buffer in another window.
  92.  
  93.     You can add more files to the list (just as if you had included them
  94. on the original edit command) by hitting GOLD-e.  It will prompt for the
  95. file(s), which may contain wildcards/lists.  The new files will be
  96. marked for update on exit.  There is and equivalent line-mode "find-file
  97. filespec(s)".  GOLD-E will read the file into another window.
  98.  
  99.     CTRL-F allows you to specify a new filename to be attached to the
  100. current buffer.
  101.  
  102.     Hitting GOLD-[Uu] will change the update mode of a buffer.  Only
  103. those buffers marked with the double star in the status line will be
  104. written out on exit.
  105.  
  106.     GOLD-[Bb] will generate a list of the current buffers.  The list
  107. will show a dot in the first column to indicate the current buffer, a
  108. star in the second for each buffer that has been modified, and a "%" in
  109. the third if the buffer is marked readonly.  It also shows the number of
  110. characters in each buffer and the filename and mode associated with it.
  111.  
  112.     GOLD-[Ii] is a handy shorthand for the line mode "insert-file
  113. filename" command.  It will prompt for the name of a file, which is
  114. included into the current buffer immediately after the current cursor
  115. location.  The file name specified may contain wildcards and/or lists.
  116.  
  117.     GOLD-CTRL-W allows you to have the current versions of all buffers
  118. written out (saved), without exiting the editor.
  119.  
  120.     GOLD-k will throw away the current buffer and move onto the next,
  121. but will ask for confirmation first.  GOLD-K doesn't ask.  Be really
  122. careful...
  123.  
  124.  
  125.                  SHELL COMMANDS
  126.  
  127.     It is possible to execute shell commands from within the editor, and
  128. get the results.  Hitting GOLD-[Dd] will prompt you for a shell command,
  129. then place you in the shell buffer.  The command is executed in a
  130. subprocess in that other buffer.  Commands which try to take over the
  131. screen (such as talk) may not work.
  132.  
  133.  
  134.                 DEFINING KEYS
  135.  
  136.     Defining keys is almost the same as in EDT, the only major
  137. difference is that it executes the keys as you build the definition --
  138. you don't have to try to visualize what the sequence will do.  The
  139. definitions properly handle repeat counts (even if you use a repeat
  140. count on a defined key containing a repeat on some other keys), and
  141. execution of a key definition halts immediately if it encounters any
  142. error (string not found, move past end of buffer, etc.).
  143.  
  144.  
  145.                 SUBSTITUTIONS
  146.  
  147.     GOLD-s or GOLD-/ allows you to easily specify a substitution.  It
  148. will prompt for the old string you want to replace, and the new
  149. replacement string.  Then, the function will pause at each occurence of
  150. the original and wait for a response.  Typical responses are "Y"
  151. (replace), "N" (don't replace), "Q" (stop replacing).  For more
  152. information, see the Emacs manual under query-replace.  GOLD-S will
  153. replace all the old strings with the new ones, without asking for any
  154. confirmation.
  155.  
  156.  
  157.                    AUTO-TAB
  158.  
  159.     When enabled (disabled by default), hitting RETURN will act as if
  160. you hit RETURN, followed by appropriate spacing if the resulting line is
  161. blank.  TAB at the beginning of a line (still in the whitespace) will
  162. re-indent the line according to the language you are using.  TAB
  163. anywhere in the text is still a tab.  GOLD-[Aa] is provided as an easy
  164. way to toggle autotab mode on and off.
  165.  
  166.  
  167.                     OTHER
  168.  
  169.     GOLD-DEL (GOLD-BS on some) will remove the current window, if it's
  170. not the only one.  CTRL-X 1 will make the current window the only one,
  171. by removing all the others.  Remember, buffers and windows are not the
  172. same thing.  Don't worry: removing a window doesn't erase that buffer!
  173.  
  174.     You can get help at any time by pressing the HELP key on VT200
  175. keyboards, or using "GOLD-KP7 info RETURN"
  176.  
  177.     You can get the description of any key's function by using the PF2
  178. key, then pressing a key sequence.  Neat, huh?
  179.  
  180.     As with normal EDT at CADIF, GOLD-q and GOLD-x provide any easy way
  181. to quit without saving any changes or exit & write out all buffers
  182. marked update which have been modified.  The lowercase versions ask for
  183. confirmation if necessary; GOLD-Q and GOLD-X do not.  Be careful...
  184.  
  185.     GOLD-[Yy] is defined to copy the selected region into the paste
  186. buffer.  It is similar to the CUT command, but you don't have to paste
  187. the text back in, and it doesn't mark the buffer as changing.
  188.  
  189.     GOLD-CTRL-L and GOLD-CTRL-U act the same as CHANGE CASE (GOLD-KP1),
  190. except that all the text is forced to be lower or upper case instead of
  191. switching to the opposite case.
  192.  
  193.     GOLD-UP and GOLD-DOWN will move up or down a full screen.  GOLD-LEFT
  194. and GOLD-RIGHT will ask you for a new screen size, in case your terminal
  195. is screwed up.
  196.  
  197.     GOLD-SPACE is an undo.  You can typically undo about 500 major
  198. changes.  After that, you're on your own.
  199.  
  200.     GOLD-~ swaps the current location with the other end of the selected
  201. region, allowing you to check where it is or easily adjust both ends.
  202.  
  203.  
  204.  
  205.                   ADVANCED FUNCTIONS
  206.  
  207.     And now some more advanced (pronounced "bizarre") definitions...
  208.  
  209.  
  210.                    MARKERS
  211.  
  212.     GOLD-. (keyboard period, not the one on the keypad) will set a
  213. marker that can be returned to later using GOLD-, (also not the one on
  214. the keypad).  You may use a repeat count to specify which marker (1 is
  215. normally the default).  On DEC-style keyboards, the keys F17-F20 retrieve
  216. markers 2 through 5 automatically, and GOLD-F17 through GOLD-F20
  217. insert them.  Pretty convenient, huh?
  218.  
  219.                    SEARCH PATTERNS
  220.  
  221.     GOLD-' or GOLD-" will allow you to search for a regular expression
  222. instead of just a simple string.  The pattern matching is relatively
  223. powerful, but takes a little practice.  See a good Unix manual (ha!) for
  224. more details on patterns.  After a pattern search is entered, FIND NEXT
  225. (PF3) may be used to search with the same pattern.
  226.  
  227.                    MATCH DELIMITERS
  228.  
  229.     The VMS version of bobtpu has special keys for matching delimiters.
  230. The unix version does it constantly, by blinking on the matching open
  231. delimiter briefly.  For example, if you type a closing brace (}) in
  232. c-mode, the editor rests the cursor briefly on the mathing opening
  233. brace, then returns the cursor to its proper place.
  234.  
  235.                    COUNTERS
  236.  
  237.     There is an internal counter that may be useful.  GOLD-= will set
  238. the counter to the repeat count, zero if not specified.  GOLD-> and
  239. GOLD-< will increment and decrement the counter by the repeat count (1
  240. by default).  GOLD-# will copy the value of the counter into the buffer
  241. using the current format, which is C-like format that may be changed
  242. using GOLD-! (the default is %d).  GOLD-* inserts the ASCII character
  243. corresponding to the counter value (mod 256).
  244.  
  245.                 TEXT EXPANSION
  246.  
  247.     GOLD-h (also DO on VT200-style keyboards or F1 on SGI-styles) will
  248. invoke an automatic text expander.  This will search a special list for
  249. the word which is under the cursor.  If it finds a line containing the
  250. word (called the key), the word is replaced by a "tag".  Repeating will
  251. find successive occurrences, replacing the text each time.  If no more
  252. matches are found, it will restore the original word.  For instance, if
  253. you enter "open<GOLD-h>", it might first replace "open" with
  254. "HC_Open_Segment ();", then "HC_KOpen_Segment ();", and then return to
  255. "open" if requested a third time.  Gold-DO or GOLD-H will cause the
  256. original text to be restored.  Currently, all the HOOPS commands are in
  257. the list.  If you'd like to add more, I'll provide a facility for doing
  258. so.
  259.  
  260.                 SPELLING CHECKER
  261.  
  262.     If spell has been installed on the system it can be invoked to check
  263. all or part of a file/buffer.  The simplest means of using it is to use
  264. GOLD-?.  This will cause it to generate Spell as a subprocess and have
  265. it check the selected region, or the whole buffer if no region was
  266. selected.  If any changes are made in Spell and then saved, the changes
  267. will be incorporated back into the editor.
  268.  
  269.                   NUMERIC KEYPAD
  270.  
  271.     GOLD-$ toggles between numeric keypad mode (the digits and
  272. punctuation characters on the keypad merely insert the corresponding
  273. text into the buffer) and function mode (the keypad keys have their
  274. normal editing functions).
  275.  
  276.                      LINE MODE
  277.  
  278.     You can enter commands directly to the emulator with GOLD-KP7.  You
  279. can evaluate elisp s-espressions with GOLD-PF2.
  280.  
  281.  
  282. ** If for some obscure reason you want plain emacs, 
  283. ** you can type "GOLD-KP7 cancel-tpu"
  284. ** Use "ESC-X use-tpu" to get it back.
  285.  
  286.  
  287. ---------
  288. tpu.el
  289. --------
  290. ;;;
  291. ;;;
  292. ;;;
  293. ;;;  E D T / B O B T P U
  294. ;;;  Editor Definitions
  295. ;;;  Jeff Kowalski
  296. ;;;  November, 1988
  297. ;;;
  298. ;;;  Based on the edt.el 
  299. ;;;
  300. ;;;
  301. ;; Copyright (C) 1989 Free Software Foundation, Inc.
  302.  
  303. ;; GNU Emacs is distributed in the hope that it will be useful,
  304. ;; but WITHOUT ANY WARRANTY.  No author or distributor
  305. ;; accepts responsibility to anyone for the consequences of using it
  306. ;; or for whether it serves any particular purpose or works at all,
  307. ;; unless he says so in writing.  Refer to the GNU Emacs General Public
  308. ;; License for full details.
  309.  
  310. ;; Everyone is granted permission to copy, modify and redistribute
  311. ;; GNU Emacs, but only under the conditions described in the
  312. ;; GNU Emacs General Public License.   A copy of this license is
  313. ;; supposed to have been given to you along with GNU Emacs so you
  314. ;; can know your rights and responsibilities.  It should be in a
  315. ;; file named COPYING.  Among other things, the copyright notice
  316. ;; and this notice must be preserved on all copies.
  317. ;;; 
  318.  
  319.  
  320. ;;;
  321. ;;;
  322. ;;;  G L O B A L
  323. ;;;  K E Y M A P S
  324. ;;;
  325. ;;;
  326. (defvar CSI-map nil
  327.   "Maps the CSI function keys on the VT100 keyboard.
  328. CSI is DEC's name for the sequence <ESC>[.")
  329. (setq CSI-map (make-sparse-keymap))
  330.  
  331. (defvar APPLE-map nil
  332.   "Maps the Apple Extended Keyboard function keys.
  333. The sequence begins with CTRL-A.")
  334. (setq APPLE-map (make-sparse-keymap))
  335.  
  336. (defvar DCS-map nil
  337.   "Maps the DCS function keys on the iris-ansi keyboard.
  338. DCS is SGI's name for the sequence <ESC>P.")
  339. (setq DCS-map (make-sparse-keymap))
  340.  
  341. (defvar SS3-map nil
  342.   "Maps the SS3 function keys on the VT100 keyboard.
  343. SS3 is DEC's name for the sequence <ESC>O.")
  344. (setq SS3-map (make-sparse-keymap))
  345.  
  346. (defvar GOLD-map nil
  347.    "Maps the function keys on the VT100 keyboard preceeded by PF1.
  348. GOLD is the ASCII 7-bit escape sequence <ESC>OP.")
  349. (setq GOLD-map (make-sparse-keymap))
  350.  
  351. (defvar GOLD-APPLE-map nil
  352.   "Maps the function keys on the Apple Keyboard preceeded by F9 CTRL-A.")
  353. (setq GOLD-APPLE-map (make-sparse-keymap))
  354.  
  355. (defvar GOLD-CSI-map nil
  356.    "Maps the function keys on the VT100 keyboard preceeded by GOLD-CSI.")
  357. (setq GOLD-CSI-map (make-sparse-keymap))
  358.  
  359. (defvar GOLD-SS3-map nil
  360.    "Maps the function keys on the VT100 keyboard preceeded by GOLD-SS3.")
  361. (setq GOLD-SS3-map (make-sparse-keymap))
  362.  
  363.  
  364. ;;;
  365. ;;;
  366. ;;;  G L O B A L
  367. ;;;  V A R I A B L E S
  368. ;;;
  369. ;;;
  370. (defvar tpu-global-key-plist nil
  371.   "Original pre-tpu definitions of global keys, so they may be restored.")
  372. (defvar tpu-breadcrumb-plist nil
  373.   "The set of user-defined markers (breadcrumbs), as a plist.")
  374. (defvar tpu-current-expansion nil
  375.   "The expansion that was last performed.")
  376. (defvar tpu-last-expand-point 0
  377.   "The position at which the last bob-expand was performed.")
  378. (defvar tpu-expand-key ""
  379.   "The key for which the last expansion was performed.")
  380. (defvar tpu-counter 0
  381.   "A general-purpose counter available for the user.")
  382. (defvar tpu-counter-format "%d"
  383.   "The format to use to when displaying the tpu-counter.")
  384. (defvar tpu-last-replaced-text ""
  385.   "Last text deleted by an TPU emulation replace command.")
  386. (defvar tpu-last-deleted-lines ""
  387.   "Last text deleted by an TPU emulation line-delete command.")
  388. (defvar tpu-last-deleted-words ""
  389.   "Last text deleted by an TPU emulation word-delete command.")
  390. (defvar tpu-last-deleted-chars ""
  391.   "Last text deleted by an TPU emulation character-delete command.")
  392. (defvar tpu-search-last-string ""
  393.   "Last text searched by the tpu-search commands.")
  394. (defvar newline-and-indent-p nil
  395.   "Predicate: return produces a newline and indent.")
  396.  
  397.  
  398. ;;;
  399. ;;;
  400. ;;;  U T I L I T I E S
  401. ;;;
  402. ;;;
  403. (defun caar (thingy) (car (car thingy)))
  404. (defun cadr (thingy) (car (cdr thingy)))
  405. (defun cadar (thingy) (car (cdr (car thingy))))
  406. (defun caddar (thingy) (car (cdr (cdr (car thingy)))))
  407.  
  408.  
  409. ;;;
  410. ;;;  Bob-expand
  411. ;;;
  412. (defun bob-unexpand nil
  413.   "Cancels current expansion."
  414.   (interactive)
  415.     (cond ((and (= (point) tpu-last-expand-point)
  416.                 (string= (cadar tpu-current-expansion)
  417.                          (buffer-substring
  418.                           (- (point)
  419.                              (length (cadar tpu-current-expansion))
  420.                              (caddar tpu-current-expansion))
  421.                           (- (point)
  422.                              (caddar tpu-current-expansion)))))
  423.          (backward-char (caddar tpu-current-expansion))
  424.          (backward-delete-char (length (cadar tpu-current-expansion)))
  425.          (insert tpu-expand-key)
  426.          (message "Cancelled.")
  427.          (setq tpu-last-expand-point 0))
  428.         (t (message "No expansion to cancel."))))
  429.  
  430. (defun bob-expand nil
  431.   "Expand the word before the point."
  432.   (interactive)
  433.   (let ((beg (point))
  434.         (old-syntax (char-syntax 95))
  435.         (not-found t))
  436.     (cond ((and (= (point) tpu-last-expand-point)
  437.                 (string= (cadar tpu-current-expansion)
  438.                          (buffer-substring
  439.                           (- (point)
  440.                              (length (cadar tpu-current-expansion))
  441.                              (caddar tpu-current-expansion))
  442.                           (- (point)
  443.                              (caddar tpu-current-expansion)))))
  444.            (backward-char (caddar tpu-current-expansion))
  445.            (backward-delete-char (length (cadar tpu-current-expansion)))
  446.            (setq tpu-current-expansion (cdr tpu-current-expansion)))
  447.           (t (setq tpu-current-expansion tpu-expansions)
  448.              (modify-syntax-entry 95 "w")
  449.              (forward-word -1)
  450.              (modify-syntax-entry 95 (char-to-string old-syntax))
  451.              (setq tpu-expand-key (buffer-substring (point) beg))
  452.              (delete-region beg (point))))
  453.     (while (and tpu-current-expansion not-found)
  454.       (if (string-match tpu-expand-key (caar tpu-current-expansion))
  455.           (setq not-found nil)
  456.         (setq tpu-current-expansion (cdr tpu-current-expansion))))
  457.     (cond (tpu-current-expansion
  458.            (insert (cadar tpu-current-expansion))
  459.            (forward-char (caddar tpu-current-expansion))
  460.            (setq tpu-last-expand-point (point)))
  461.           (t
  462.            (insert tpu-expand-key)
  463.            (message "Not found.")
  464.            (setq tpu-last-expand-point 0)))))
  465.  
  466. ;;;
  467. ;;;  Breadcrumbs
  468. ;;;
  469. (defun drop-breadcrumb (num)
  470.   "Drops a breadcrumb that can be returned to later with goto-breadcrumb."
  471.   (interactive "p")
  472.   (put tpu-breadcrumb-plist num (list (current-buffer) (point)))
  473.   (message "Mark %d set." num))
  474.   
  475. (defun goto-breadcrumb (num)
  476.   "Returns to a breadcrumb set with goto-breadcrumb."
  477.   (interactive "p")
  478.   (cond ((get tpu-breadcrumb-plist num)
  479.      (switch-to-buffer (car (get tpu-breadcrumb-plist num)))
  480.      (goto-char (cadr (get tpu-breadcrumb-plist num)))
  481.      (message "mark %d found." num))
  482.     (t
  483.      (message "mark %d not found." num))))
  484.  
  485. (defun drop-breadcrumb-2 nil
  486.   "drops breadcrumb number 2 at the point."
  487.   (interactive)
  488.   (drop-breadcrumb 2))
  489.  
  490. (defun drop-breadcrumb-3 nil
  491.   "drops breadcrumb number 3 at the point."
  492.   (interactive)
  493.   (drop-breadcrumb 3))
  494.  
  495. (defun drop-breadcrumb-4 nil
  496.   "drops breadcrumb number 4 at the point."
  497.   (interactive)
  498.   (drop-breadcrumb 4))
  499.  
  500. (defun drop-breadcrumb-5 nil
  501.   "drops breadcrumb number 5 at the point."
  502.   (interactive)
  503.   (drop-breadcrumb 5))
  504.  
  505. (defun goto-breadcrumb-2 nil
  506.   "goto breadcrumb number 2."
  507.   (interactive)
  508.   (goto-breadcrumb 2))
  509.  
  510. (defun goto-breadcrumb-3 nil
  511.   "goto breadcrumb number 3."
  512.   (interactive)
  513.   (goto-breadcrumb 3))
  514.  
  515. (defun goto-breadcrumb-4 nil
  516.   "goto breadcrumb number 4."
  517.   (interactive)
  518.   (goto-breadcrumb 4))
  519.  
  520. (defun goto-breadcrumb-5 nil
  521.   "goto breadcrumb number 5."
  522.   (interactive)
  523.   (goto-breadcrumb 5))
  524.  
  525.  
  526. ;;;
  527. ;;;  miscellaneous
  528. ;;;
  529. (defun replace-global-key (key func)
  530.   "Saves the current global key definition and replaces it with a new one."
  531.   (interactive)
  532.   (if (not (get tpu-global-key-plist key))
  533.       (put tpu-global-key-plist key func))
  534.   (define-key global-map key func))
  535.  
  536. (defun restore-global-key (key)
  537.   "Restores the original definition of a global key."
  538.   (interactive)
  539.   (define-key global-map key (get tpu-global-key-plist key)))
  540.  
  541. (defun case-flip (num)
  542.   "Change the case of the character under the cursor or region.
  543. accepts a prefix argument of the number of characters to invert."
  544.   (interactive "p")
  545.   (if (mark)
  546.       (let ((end (max (mark) (point)))
  547.             (point-save (point)))
  548.         (goto-char (min (point) (mark)))
  549.         (while (not (eq (point) end))
  550.           (funcall (if (<= ?a (following-char))
  551.                        'upcase-region 'downcase-region)
  552.                    (point) (1+ (point)))
  553.           (forward-char 1))
  554.         (goto-char point-save))
  555.     (progn
  556.       (if (string= tpu-direction-string " backup")
  557.           (backward-char num))
  558.       (while (> num 0)
  559.         (funcall (if (<= ?a (following-char))
  560.                      'upcase-region 'downcase-region)
  561.                  (point) (1+ (point)))
  562.         (forward-char 1)
  563.         (setq num (1- num))))))
  564.  
  565. (defun indent-or-fill-region nil
  566.   "fill region in text modes, indent region in programming language modes."
  567.   (interactive)
  568.   (if (string= paragraph-start "^$\\|^ ")
  569.       (indent-region (point) (mark) nil)
  570.     (fill-region (point) (mark))))
  571.  
  572. (defun mark-section-wisely nil
  573.   "mark the section in a manner consistent with the major-mode.
  574. uses mark-defun for emacs-lisp, lisp,
  575. mark-c-function for c,
  576. and mark-paragraph for other modes."
  577.   (interactive)
  578.   (cond  ((eq major-mode 'emacs-lisp-mode)
  579.           (mark-defun))
  580.          ((eq major-mode 'lisp-mode)
  581.           (mark-defun))
  582.          ((eq major-mode 'c-mode)
  583.           (mark-c-function))
  584.          (t (mark-paragraph))))
  585.  
  586. (defun update-mode-line nil
  587.   "make sure mode-line in the current buffer reflects all changes."
  588.   (set-buffer-modified-p (buffer-modified-p))
  589.   (sit-for 0))
  590.  
  591. (defun reset-screen-size (height width)
  592.   "sets screen size."
  593.   (interactive "nnew screen height: \nnnew screen width: ")
  594.   (set-screen-height height)
  595.   (set-screen-width width))
  596.  
  597. (defun toggle-newline-and-indent nil
  598.   "toggle between 'newline and indent' and 'simple newline'."
  599.   (interactive)
  600.   (cond (newline-and-indent-p
  601.          (setq newline-and-indent-p-string "")
  602.          (setq newline-and-indent-p nil)
  603.          (global-set-key "\c-m" 'newline))
  604.         (t
  605.          (setq newline-and-indent-p-string " autoindent")
  606.          (setq newline-and-indent-p t)
  607.          (global-set-key "\c-m" 'newline-and-indent)))
  608.   (update-mode-line))
  609.  
  610. (defun spell-check nil
  611.   "checks the spelling of the region, or of the entire buffer if no
  612.  region is selected."
  613.   (interactive)
  614.   (cond ((= (point) (mark)) (spell-buffer))
  615.         (t (spell-region (point) (mark)))))
  616.   
  617. (defun report-position nil
  618.   "prints a message in the minibuffer that shows the current position
  619.  of the point in the buffer."
  620.   (interactive)
  621.   (message "char %d   line %d   %d%%"
  622.            (point)
  623.            (1+ (count-lines 1 (point)))
  624.            (/ (* 100 (point)) (point-max))))
  625.  
  626. (defun unset-mark-command nil
  627.   "Remove current mark."
  628.   (interactive)
  629.   (setq mark-ring nil)
  630.   (set-mark nil)
  631.   (message "Mark unset."))
  632.  
  633. (defun quit-emacs-now nil
  634.   "Go away.  Now.  Just  g o  a w a y."
  635.   (interactive)
  636.   (kill-emacs t))
  637.  
  638.  
  639. ;;;
  640. ;;;  Auto-insert
  641. ;;;
  642. (defun insert-escape nil
  643.   "Inserts an escape character, and so becomes the escape-key alias."
  644.   (interactive)
  645.   (insert "\e"))
  646.  
  647. (defun insert-formfeed nil
  648.   "Inserts a formfeed character."
  649.   (interactive)
  650.   (insert "\C-L"))
  651.  
  652.  
  653. ;;;
  654. ;;;  Define key
  655. ;;;
  656. (defun end-define-macro-key nil
  657.   "Ends the current macro definition"
  658.   (interactive)
  659.   (end-kbd-macro nil)
  660.   (global-set-key defining-key last-kbd-macro)
  661.   (global-set-key "\eOM" 'newline))
  662.  
  663. (defun define-macro-key (key)
  664.   "Bind a set of keystrokes to a single key."
  665.   (interactive "kKey to define: ")
  666.   (setq defining-key key)
  667.   (global-set-key "\eOM" 'end-define-macro-key)
  668.   (start-kbd-macro nil))
  669.  
  670.  
  671. ;;;
  672. ;;;  Counter
  673. ;;;
  674. (defun set-counter nil
  675.   "Set the internal counter to the repeat count."
  676.   (interactive)
  677.   (message "Counter set to %d."
  678.        (setq tpu-counter current-prefix-arg)))
  679.  
  680. (defun region-length-to-counter nil
  681.   "Sets the counter to the length of the region."
  682.   (interactive)
  683.   (cond ((mark)
  684.      (message "Counter set to %d."
  685.           (setq tpu-counter
  686.             (- (max (point) (mark)) (min (point) (mark))))))
  687.     (t (message "The mark is not set now; no select range is active."))))
  688.  
  689. (defun decr-counter nil
  690.   "Decrement the internal counter by the repeat count,
  691.  or by one if no repeat count is defined."
  692.  (interactive)
  693.  (message "Counter set to %d."
  694.       (setq tpu-counter (- tpu-counter (or current-prefix-arg 1)))))
  695.  
  696. (defun incr-counter nil
  697.   "Increment the internal counter by the repeat count,
  698.  or by one if no repeat count is defined."
  699.  (interactive)
  700.  (message "Counter set to %d."
  701.       (setq tpu-counter (+ tpu-counter (or current-prefix-arg 1)))))
  702.  
  703. (defun change-counter-format (fmt)
  704.   "Changes the display format for use when inserting the internal tpu counter.
  705.  You may use standard C format expressions."
  706.   (interactive "sFormat (C-like):")
  707.   (setq tpu-counter-format fmt))
  708.  
  709. (defun insert-counter nil
  710.   "Inserts the internal tpu counter using the tpu counter format."
  711.   (interactive)
  712.   (insert (format tpu-counter-format tpu-counter)))
  713.  
  714. (defun insert-counter-as-char nil
  715.   "Inserts the character value (mod 256) of the internal tpu counter."
  716.   (interactive)
  717.   (insert (mod tpu-counter 256)))
  718.  
  719.  
  720. ;;;
  721. ;;;  Buffer
  722. ;;;
  723. (defun set-buffer-clean nil
  724.   "Toggles the update mode of the buffer."
  725.   (interactive)
  726.   (set-buffer-modified-p (not (buffer-modified-p))))
  727.  
  728. (defun kill-this-buffer nil
  729.   "Kills the current buffer, but ask first."
  730.   (interactive)
  731.   (if (y-or-n-p (format "Really kill %s? " (current-buffer)))
  732.       (kill-buffer (current-buffer))))
  733.  
  734. (defun kill-this-buffer-now nil
  735.   "Kills the current buffer without asking."
  736.   (interactive)
  737.   (kill-buffer (current-buffer)))
  738.  
  739. (defun save-all-buffers-kill-emacs nil
  740.   "Save all buffers and exit emacs."
  741.   (interactive)
  742.   (setq trim-versions-without-asking t)
  743.   (save-buffers-kill-emacs t))
  744.  
  745. (defun write-current-buffers nil
  746.   "Save all modified buffers without exiting."
  747.   (interactive)
  748.   (save-some-buffers t))
  749.  
  750. (defun next-buffer nil
  751.   "Go to next buffer in ring."
  752.   (interactive)
  753.   (switch-to-buffer (car (reverse (buffer-list)))))
  754.  
  755. (defun switch-to-last-buffer nil
  756.  "Go to most recent buffer in ring."
  757.   (interactive)
  758.   (switch-to-buffer (cadr (buffer-list))))
  759.  
  760.  
  761. ;;;
  762. ;;;  Repeat count
  763. ;;;
  764. (defun repeat-command-0 nil
  765.   "Repeats the following keystroke."
  766.   (interactive)
  767.   (prefix-arg-internal 48 nil nil))
  768.  
  769. (defun repeat-command-1 nil
  770.   "Repeats the following keystroke."
  771.   (interactive)
  772.   (prefix-arg-internal 49 nil nil))
  773.  
  774. (defun repeat-command-2 nil
  775.   "Repeats the following keystroke."
  776.   (interactive)
  777.   (prefix-arg-internal 50 nil nil))
  778.  
  779. (defun repeat-command-3 nil
  780.   "Repeats the following keystroke."
  781.   (interactive)
  782.   (prefix-arg-internal 51 nil nil))
  783.  
  784. (defun repeat-command-4 nil
  785.   "Repeats the following keystroke."
  786.   (interactive)
  787.   (prefix-arg-internal 52 nil nil))
  788.  
  789. (defun repeat-command-5 nil
  790.   "Repeats the following keystroke."
  791.   (interactive)
  792.   (prefix-arg-internal 53 nil nil))
  793.  
  794. (defun repeat-command-6 nil
  795.   "Repeats the following keystroke."
  796.   (interactive)
  797.   (prefix-arg-internal 54 nil nil))
  798.  
  799. (defun repeat-command-7 nil
  800.   "Repeats the following keystroke."
  801.   (interactive)
  802.   (prefix-arg-internal 55 nil nil))
  803.  
  804. (defun repeat-command-8 nil
  805.   "Repeats the following keystroke."
  806.   (interactive)
  807.   (prefix-arg-internal 56 nil nil))
  808.  
  809. (defun repeat-command-9 nil
  810.   "Repeats the following keystroke."
  811.   (interactive)
  812.   (prefix-arg-internal 57 nil nil))
  813.  
  814. (defun repeat-command-- nil
  815.   "Repeats the following keystroke."
  816.   (interactive)
  817.   (prefix-arg-internal 45 nil nil))
  818.  
  819.  
  820. ;;;
  821. ;;;  Search
  822. ;;;
  823. (defun tpu-search-forward (pat)
  824.   "Search for a string."
  825.   (interactive "sSearch: ") 
  826.   (setq tpu-search-last-string
  827.         (if (not (string= "" pat)) pat (read-string "Search: ")))
  828.   (search-forward tpu-search-last-string))
  829.  
  830. (defun tpu-search-backward (pat)
  831.   "Search for a string."
  832.   (interactive "sSearch: ")
  833.   (setq tpu-search-last-string
  834.         (if (not (string= "" pat)) pat (read-string "Search: ")))
  835.   (search-backward tpu-search-last-string))
  836.  
  837. (defun search-again-forward nil
  838.   "Search for the same string as last time."
  839.   (interactive)
  840.   (tpu-search-forward tpu-search-last-string))
  841.  
  842. (defun search-again-backward nil
  843.   "Search for the same string as last time."
  844.   (interactive)
  845.   (tpu-search-backward tpu-search-last-string))
  846.  
  847.  
  848. ;;;
  849. ;;;  Delete
  850. ;;;
  851. (defun delete-current-line (num)
  852.   "Delete one or specified number of lines after point.
  853. This includes the newline character at the end of each line.
  854. They are saved for the TPU undelete-lines command."
  855.   (interactive "p")
  856.   (let ((beg (point)))
  857.     (forward-line num)
  858.     (if (not (eq (preceding-char) ?\n))
  859.         (insert "\n"))
  860.     (setq tpu-last-deleted-lines
  861.           (buffer-substring beg (point)))
  862.     (delete-region beg (point))))
  863.  
  864. (defun delete-to-eol (num)
  865.   "Delete text up to end of line.
  866. With argument, delete up to to Nth line-end past point.
  867. They are saved for the TPU undelete-lines command."
  868.   (interactive "p")
  869.   (let ((beg (point)))
  870.     (forward-char 1)
  871.     (end-of-line num)
  872.     (setq tpu-last-deleted-lines
  873.           (buffer-substring beg (point)))
  874.     (delete-region beg (point))))
  875.  
  876. (defun delete-to-bol (num)
  877.   "Delete text back to beginning of line.
  878. With argument, delete up to to Nth line-end past point.
  879. They are saved for the TPU undelete-lines command."
  880.   (interactive "p")
  881.   (let ((beg (point)))
  882.     (backward-char 1)
  883.     (beginning-of-line num)
  884.     (setq tpu-last-deleted-lines
  885.           (buffer-substring (point) beg))
  886.     (delete-region (point) beg)))
  887.  
  888. (defun delete-current-word (num)
  889.   "Delete one or specified number of words after point.
  890. They are saved for the TPU undelete-words command."
  891.   (interactive "p")
  892.   (let ((beg (point)))
  893.     (forward-word num)
  894.     (setq tpu-last-deleted-words
  895.           (buffer-substring beg (point)))
  896.     (delete-region beg (point))))
  897.  
  898. (defun delete-previous-word (num)
  899.   "Delete one or specified number of words before point.
  900. They are saved for the TPU undelete-words command."
  901.   (interactive "p")
  902.   (let ((beg (point)))
  903.     (forward-word (- num))
  904.     (setq tpu-last-deleted-words
  905.           (buffer-substring (point) beg))
  906.     (delete-region beg (point))))
  907.  
  908. (defun delete-current-char (num)
  909.   "Delete one or specified number of characters after point.
  910. They are saved for the TPU undelete-chars command."
  911.   (interactive "p")
  912.   (setq tpu-last-deleted-chars
  913.         (buffer-substring (point) (min (point-max) (+ (point) num))))
  914.   (delete-region (point) (min (point-max) (+ (point) num))))
  915.  
  916. (defun delete-previous-char (num)
  917.   "Delete one or specified number of characters before point.
  918. They are saved for the TPU undelete-chars command."
  919.   (interactive "p")
  920.   (setq tpu-last-deleted-chars
  921.         (buffer-substring (max (point-min) (- (point) num)) (point)))
  922.   (delete-region (max (point-min) (- (point) num)) (point)))
  923.  
  924. (defun append-region nil
  925.   "Deletes selected region and appends it to the current kill ring entry."
  926.   (interactive)
  927.   (append-next-kill)
  928.   (kill-region (mark) (point)))
  929.  
  930.  
  931. ;;;
  932. ;;;  Undelete
  933. ;;;
  934. (defun replace nil
  935.   "Deletes text in selected range and replaces it with contents of kill ring."
  936.   (interactive)
  937.   (setq tpu-last-replaced-text
  938.         (buffer-substring (point) (mark)))
  939.   (delete-region (point) (mark))
  940.   (yank))
  941.  
  942. (defun undelete-lines nil
  943.   "Yank lines deleted by last TPU line-deletion command."
  944.   (interactive)
  945.   (insert tpu-last-deleted-lines))
  946.  
  947. (defun undelete-words nil
  948.   "Yank words deleted by last TPU word-deletion command."
  949.   (interactive)
  950.   (insert tpu-last-deleted-words))
  951.  
  952. (defun undelete-chars nil
  953.   "Yank characters deleted by last TPU character-deletion command."
  954.   (interactive)
  955.   (insert tpu-last-deleted-chars))
  956.  
  957.  
  958. ;;;
  959. ;;;  Position
  960. ;;;
  961. (defun next-end-of-line (num)
  962.   "Move to end of line; if at end, move to end of next line.
  963. Accepts a prefix argument for the number of lines to move."
  964.   (interactive "p")
  965.   (forward-char)
  966.   (end-of-line num))
  967.  
  968. (defun next-beginning-of-line (num)
  969.   "Move to beginning of line; if at beginning, move to beginning of next line.
  970. Accepts a prefix argument for the number of lines to move."
  971.   (interactive "p")
  972.   (backward-char)
  973.   (beginning-of-line num))
  974.  
  975. (defun previous-end-of-line (num)
  976.   "Move EOL upward.
  977. Accepts a prefix argument for the number of lines to move."
  978.   (interactive "p")
  979.   (end-of-line (- 1 num)))
  980.  
  981. (defun forward-to-word (num)
  982.   "Move to next word-beginning, or to Nth following word-beginning."
  983.   (interactive "p")
  984.   (forward-word (1+ num))
  985.   (forward-word -1))
  986.  
  987. (defun backward-to-word (num)
  988.   "Move back to word-end, or to Nth word-end seen."
  989.   (interactive "p")
  990.   (forward-word (- (1+ num)))
  991.   (forward-word 1))
  992.  
  993. (defun backward-line (num)
  994.   "Move point to start of previous line.
  995. Prefix argument serves as repeat-count."
  996.   (interactive "p")
  997.   (forward-line (- num)))
  998.  
  999. (defun next-paragraph (num)
  1000.   "Move to beginning of the next indented paragraph.
  1001. Accepts a prefix argument for the number of paragraphs."
  1002.   (interactive "p")
  1003.   (while (> num 0)
  1004.     (next-line 1)
  1005.     (forward-paragraph)
  1006.     (previous-line 1)
  1007.     (if (eolp) (next-line 1))
  1008.     (setq num (1- num))))
  1009.  
  1010. (defun previous-paragraph (num)
  1011.   "Move to beginning of previous indented paragraph.
  1012. Accepts a prefix argument for the number of paragraphs."
  1013.   (interactive "p")
  1014.   (while (> num 0)
  1015.     (backward-paragraph)
  1016.     (previous-line 1)
  1017.     (if (eolp) (next-line 1))
  1018.     (setq num (1- num))))
  1019.  
  1020. (defun move-to-beginning nil
  1021.   "Move cursor to the beginning of buffer, but don't set the mark."
  1022.   (interactive)
  1023.   (goto-char (point-min)))
  1024.  
  1025. (defun move-to-end nil
  1026.   "Move cursor to the end of buffer, but don't set the mark."
  1027.   (interactive)
  1028.   (goto-char (point-max)))
  1029.  
  1030. (defun goto-percent (perc)
  1031.   "Move point to ARG percentage of the buffer."
  1032.   (interactive "NGoto-percentage: ")
  1033.   (if (or (> perc 100) (< perc 0))
  1034.       (error "Percentage %d out of range 0 < percent < 100" perc)
  1035.     (goto-char (/ (* (point-max) perc) 100))))
  1036.  
  1037.  
  1038. ;;;
  1039. ;;;  Window
  1040. ;;;
  1041. (defun scroll-window-down (num)
  1042.   "Scroll the display down a window-full.
  1043. Accepts a prefix argument for the number of window-fulls to scroll."
  1044.   (interactive "p")
  1045.   (scroll-down (- (* (window-height) num) 2)))
  1046.  
  1047. (defun scroll-window-up (num)
  1048.   "Scroll the display up a window-full.
  1049. Accepts a prefix argument for the number of window-fulls to scroll."
  1050.   (interactive "p")
  1051.   (scroll-up (- (* (window-height) num) 2)))
  1052.  
  1053. (defun beginning-of-window nil
  1054.   "Home cursor to top of window."
  1055.   (interactive)
  1056.   (move-to-window-line 0))
  1057.  
  1058. (defun line-to-bottom-of-window nil
  1059.   "Move the current line to the bottom of the window."
  1060.   (interactive)
  1061.   (recenter -1))
  1062.  
  1063. (defun line-to-top-of-window nil
  1064.   "Move the current line to the top of the window."
  1065.   (interactive)
  1066.   (recenter 0))
  1067.  
  1068. ;;;
  1069. ;;;  Keyboard-style specific
  1070. ;;;
  1071. (defun DEC-mode nil
  1072.   "Defines the DEC style keyboard."
  1073.   (interactive)
  1074.   (define-key global-map "\C-h" 'next-beginning-of-line)        ; ^H (BS)
  1075.   (define-key CSI-map "C" 'backward-char)                       ; right
  1076.   (define-key CSI-map "D" 'forward-char)                        ; left
  1077.   )
  1078. (defun SGI-mode nil
  1079.   "Defines the SGI style keyboard."
  1080.   (interactive)
  1081.   (define-key global-map "\C-h" 'backward-delete-char)          ; ^H (BS)
  1082.   (define-key CSI-map "C" 'forward-char)                        ; left
  1083.   (define-key CSI-map "D" 'backward-char)                       ; right
  1084.   (define-key CSI-map "001q" 'bob-expand)                       ; F1 IRIS4D
  1085.   )
  1086.  
  1087. ;;;
  1088. ;;;  Direction
  1089. ;;;
  1090. (defun advance-direction nil
  1091.   "Set TPU Advance mode so keypad commands move forward."
  1092.   (interactive)
  1093.   (setq tpu-direction-string " advance")
  1094.   (define-key CSI-map "1~" 'isearch-forward)                    ; Find
  1095.   (define-key SS3-map "R" 'search-again-forward)                ; PF3
  1096.   (define-key APPLE-map "J\C-M" 'search-again-forward)          ; Apple F11
  1097.   (define-key SS3-map "p" 'forward-line)                        ; KP0
  1098.   (define-key SS3-map "q" 'forward-to-word)                     ; KP1
  1099.   (define-key SS3-map "r" 'next-end-of-line)                    ; KP2
  1100.   (define-key SS3-map "s" 'forward-char)                        ; KP3
  1101.   (define-key SS3-map "w" 'next-paragraph)                      ; KP7
  1102.   (define-key SS3-map "x" 'scroll-window-up)                    ; KP8
  1103.   (define-key GOLD-map "'" 'isearch-forward-regexp)             ; '
  1104.   (define-key GOLD-map "\"" 'isearch-forward-regexp)            ; "
  1105.   (define-key GOLD-SS3-map "R" 'tpu-search-forward)             ; PF3
  1106.   (define-key GOLD-APPLE-map "J\C-M" 'tpu-search-forward)       ; Apple F11
  1107.   (update-mode-line))
  1108.  
  1109. (defun backup-direction nil
  1110.   "Set TPU Backup mode so keypad commands move backward."
  1111.   (interactive)
  1112.   (setq tpu-direction-string " backup")
  1113.   (define-key CSI-map "1~" 'isearch-backward)                   ; Find
  1114.   (define-key SS3-map "R" 'search-again-backward)               ; PF3
  1115.   (define-key APPLE-map "J\C-M" 'search-again-backward)         ; Apple F11
  1116.   (define-key SS3-map "p" 'backward-line)                       ; KP0
  1117.   (define-key SS3-map "q" 'backward-to-word)                    ; KP1
  1118.   (define-key SS3-map "r" 'previous-end-of-line)                ; KP2
  1119.   (define-key SS3-map "s" 'backward-char)                       ; KP3
  1120.   (define-key SS3-map "w" 'previous-paragraph)                  ; KP7
  1121.   (define-key SS3-map "x" 'scroll-window-down)                  ; KP8
  1122.   (define-key GOLD-map "'" 'isearch-backward-regexp)            ; '
  1123.   (define-key GOLD-map "\"" 'isearch-backward-regexp)           ; "
  1124.   (define-key GOLD-SS3-map "R" 'tpu-search-backward)            ; PF3
  1125.   (define-key GOLD-APPLE-map "J\C-M" 'tpu-search-backward)      ; Apple F11
  1126.   (update-mode-line))
  1127.  
  1128.  
  1129. ;;;
  1130. ;;;  APPLE-map key definitions
  1131. ;;;
  1132. (define-key APPLE-map "@\C-M" 'undo)                            ; APPLE F1
  1133. (define-key APPLE-map "A\C-M" 'kill-region)                     ; APPLE F2
  1134. (define-key APPLE-map "B\C-M" 'copy-region-as-kill)             ; APPLE F3
  1135. (define-key APPLE-map "C\C-M" 'yank)                            ; APPLE F4
  1136. (define-key APPLE-map "D\C-M" 'goto-breadcrumb-2)               ; APPLE F5
  1137. (define-key APPLE-map "E\C-M" 'goto-breadcrumb-3)               ; APPLE F6
  1138. (define-key APPLE-map "F\C-M" 'goto-breadcrumb-4)               ; APPLE F7
  1139. (define-key APPLE-map "G\C-M" 'goto-breadcrumb-5)               ; APPLE F8
  1140. ;                                                               ; APPLE F9
  1141. (define-key APPLE-map "I\C-M" 'describe-key)                    ; APPLE F10
  1142. ;                                                               ; APPLE F11
  1143. (define-key APPLE-map "K\C-M" 'delete-current-line)             ; APPLE F12
  1144. (define-key APPLE-map "L\C-M" nil)                              ; APPLE F13
  1145. (define-key APPLE-map "M\C-M" nil)                              ; APPLE F14
  1146. (define-key APPLE-map "N\C-M" nil)                              ; APPLE F15
  1147. (define-key APPLE-map "O\C-M" 'backward-delete-char)            ; APPLE Del
  1148. (define-key APPLE-map "P\C-M" 'move-to-end)                     ; APPLE End
  1149. (define-key APPLE-map "Q\C-M" 'scroll-window-up)                ; APPLE Page Down
  1150. (define-key APPLE-map "R\C-M" 'apropos)                         ; APPLE Help
  1151. (define-key APPLE-map "S\C-M" 'move-to-beginning)               ; APPLE Home
  1152. (define-key APPLE-map "T\C-M" 'scroll-window-down)              ; APPLE Page Up
  1153.  
  1154.  
  1155. ;;;
  1156. ;;;  GOLD-APPLE-map key definitions
  1157. ;;;
  1158. (define-key GOLD-APPLE-map "@\C-M" nil)                         ; APPLE F1
  1159. (define-key GOLD-APPLE-map "A\C-M" nil)                         ; APPLE F2
  1160. (define-key GOLD-APPLE-map "B\C-M" nil)                         ; APPLE F3
  1161. (define-key GOLD-APPLE-map "C\C-M" nil)                         ; APPLE F4
  1162. (define-key GOLD-APPLE-map "D\C-M" 'drop-breadcrumb-2)          ; APPLE F5
  1163. (define-key GOLD-APPLE-map "E\C-M" 'drop-breadcrumb-3)          ; APPLE F6
  1164. (define-key GOLD-APPLE-map "F\C-M" 'drop-breadcrumb-4)          ; APPLE F7
  1165. (define-key GOLD-APPLE-map "G\C-M" 'drop-breadcrumb-5)          ; APPLE F8
  1166. (define-key GOLD-APPLE-map "H\C-M" 'mark-section-wisely)        ; APPLE F9
  1167. (define-key GOLD-APPLE-map "I\C-M" 'eval-expression)            ; APPLE F10
  1168. ;                                                               ; APPLE F11
  1169. (define-key GOLD-APPLE-map "K\C-M" 'undelete-lines)             ; APPLE F12
  1170. (define-key GOLD-APPLE-map "L\C-M" nil)                         ; APPLE F13
  1171. (define-key GOLD-APPLE-map "M\C-M" nil)                         ; APPLE F14
  1172. (define-key GOLD-APPLE-map "N\C-M" nil)                         ; APPLE F15
  1173. (define-key GOLD-APPLE-map "O\C-M" 'backward-delete-char)       ; APPLE Del
  1174. (define-key GOLD-APPLE-map "P\C-M" 'move-to-end)                ; APPLE End
  1175. (define-key GOLD-APPLE-map "Q\C-M" 'scroll-window-up)           ; APPLE Page Down
  1176. (define-key GOLD-APPLE-map "R\C-M" 'apropos)                    ; APPLE Help
  1177. (define-key GOLD-APPLE-map "S\C-M" 'move-to-beginning)          ; APPLE Home
  1178. (define-key GOLD-APPLE-map "T\C-M" 'scroll-window-down)         ; APPLE Page Up
  1179.  
  1180.  
  1181. ;;;
  1182. ;;;  CSI-map key definitions
  1183. ;;;
  1184. (define-key CSI-map "A" 'previous-line)                         ; up
  1185. (define-key CSI-map "B" 'next-line)                             ; down
  1186. ;; left and right are defined in DEC-mode and SGI-mode
  1187. (define-key CSI-map "H" 'move-to-beginning)                     ; Home IRIS4D
  1188. (define-key CSI-map "P" 'backward-delete-char)                  ; Delete IRIS4D
  1189. (define-key CSI-map "2~" 'yank)                                 ; Insert Here
  1190. (define-key CSI-map "3~" 'kill-region)                          ; Remove
  1191. (define-key CSI-map "4~" 'set-mark-command)                     ; Select
  1192. (define-key CSI-map "5~" 'scroll-window-down)                   ; Prev Screen
  1193. (define-key CSI-map "6~" 'scroll-window-up)                     ; Next Screen
  1194. (define-key CSI-map "11~" 'nil)                                 ; F1
  1195. (define-key CSI-map "12~" 'nil)                                 ; F2
  1196. (define-key CSI-map "13~" 'nil)                                 ; F3
  1197. (define-key CSI-map "14~" 'nil)                                 ; F4
  1198. (define-key CSI-map "15~" 'nil)                                 ; F5
  1199. (define-key CSI-map "17~" 'nil)                                 ; F6
  1200. (define-key CSI-map "18~" 'nil)                                 ; F7
  1201. (define-key CSI-map "19~" 'nil)                                 ; F8
  1202. (define-key CSI-map "20~" 'nil)                                 ; F9
  1203. (define-key CSI-map "21~" 'nil)                                 ; F10
  1204. (define-key CSI-map "23~" 'insert-escape)                       ; F11 (ESC)
  1205. (define-key CSI-map "24~" 'next-beginning-of-line)              ; F12 (BS)
  1206. (define-key CSI-map "25~" 'delete-previous-word)                ; F13 (LF)
  1207. (define-key CSI-map "26~" 'nil)                                 ; F14
  1208. (define-key CSI-map "28~" 'apropos)                             ; HELP
  1209. (define-key CSI-map "29~" 'bob-expand)                          ; DO
  1210. (define-key CSI-map "31~" 'goto-breadcrumb-2)                   ; F17
  1211. (define-key CSI-map "32~" 'goto-breadcrumb-3)                   ; F18
  1212. (define-key CSI-map "33~" 'goto-breadcrumb-4)                   ; F19
  1213. (define-key CSI-map "34~" 'goto-breadcrumb-5)                   ; F20
  1214. (define-key CSI-map "001q" 'SGI-mode)                           ; F1 IRIS4D
  1215. (define-key CSI-map "002q" nil)                                 ; F2 IRIS4D
  1216. (define-key CSI-map "003q" nil)                                 ; F3 IRIS4D
  1217. (define-key CSI-map "004q" nil)                                 ; F4 IRIS4D
  1218. (define-key CSI-map "005q" nil)                                 ; F5 IRIS4D
  1219. (define-key CSI-map "006q" nil)                                 ; F6 IRIS4D
  1220. (define-key CSI-map "007q" nil)                                 ; F7 IRIS4D
  1221. (define-key CSI-map "008q" nil)                                 ; F8 IRIS4D
  1222. (define-key CSI-map "009q" nil)                                 ; F9 IRIS4D*
  1223. (define-key CSI-map "010q" nil)                                 ; F10 IRIS4D*
  1224. (define-key CSI-map "011q" nil)                                 ; F11 IRIS4D*
  1225. (define-key CSI-map "012q" nil)                                 ; F12 IRIS4D*
  1226. (define-key CSI-map "139q" 'yank)                               ; Insert IRIS4D
  1227. (define-key CSI-map "146q" 'move-to-end)                        ; End IRIS4D
  1228. (define-key CSI-map "150q" 'scroll-window-down)                 ; PgUp IRIS4D
  1229. (define-key CSI-map "154q" 'scroll-window-up)                   ; PgDn IRIS4D
  1230. (define-key CSI-map "209q" nil)                                 ; PrScr IRIS4D
  1231. (define-key CSI-map "213q" nil)                                 ; ScrLck IRIS4D
  1232. (define-key CSI-map "217q" nil)                                 ; Pause IRIS4D
  1233.  
  1234.  
  1235. ;;;
  1236. ;;;  SS3-map key definitions
  1237. ;;;
  1238. (define-key SS3-map "A" 'previous-line)                         ; up
  1239. (define-key SS3-map "B" 'next-line)                             ; down
  1240. (define-key SS3-map "C" 'forward-char)                          ; right
  1241. (define-key SS3-map "D" 'backward-char)                         ; left
  1242. (define-key SS3-map "Q" 'describe-key)                          ; PF2
  1243. (define-key SS3-map "S" 'delete-current-line)                   ; PF4
  1244. (define-key SS3-map "X" 'describe-key)                          ; Apple KP=
  1245. (define-key SS3-map "j" 'delete-current-line)                   ; Apple KP*
  1246. (define-key SS3-map "k" 'delete-current-char)                   ; Apple KP+
  1247. (define-key SS3-map "l" 'delete-current-char)                   ; KP,
  1248. (define-key SS3-map "m" 'delete-current-word)                   ; KP-
  1249. (define-key SS3-map "n" 'set-mark-command)                      ; KP.
  1250. (define-key SS3-map "t" 'advance-direction)                     ; KP4
  1251. (define-key SS3-map "u" 'backup-direction)                      ; KP5
  1252. (define-key SS3-map "v" 'kill-region)                           ; KP6
  1253. (define-key SS3-map "y" 'append-region)                         ; KP9
  1254.  
  1255.  
  1256. ;;;
  1257. ;;;  GOLD-map key definitions
  1258. ;;;
  1259. ;(define-key GOLD-map "\C-A" 'nil)                               ; ^A
  1260. (define-key GOLD-map "\C-B" 'nil)                               ; ^B
  1261. (define-key GOLD-map "\C-C" 'nil)                               ; ^C
  1262. (define-key GOLD-map "\C-D" 'nil)                               ; ^D
  1263. (define-key GOLD-map "\C-E" 'nil)                               ; ^E
  1264. (define-key GOLD-map "\C-F" 'nil)                               ; ^F
  1265. (define-key GOLD-map "\C-g" 'keyboard-quit)                     ; safety first
  1266. (define-key GOLD-map "\C-h" 'delete-other-windows)              ; BS
  1267. (define-key GOLD-map "\C-i" 'other-window)                      ; TAB
  1268. ;(define-key GOLD-map "\C-J" 'nil)                               ; ^J
  1269. (define-key GOLD-map "\C-K" 'nil)                               ; ^K
  1270. (define-key GOLD-map "\C-l" 'downcase-region)                   ; ^L
  1271. (define-key GOLD-map "\C-M" 'nil)                               ; ^M
  1272. (define-key GOLD-map "\C-N" 'nil)                               ; ^N
  1273. (define-key GOLD-map "\C-O" 'nil)                               ; ^O
  1274. (define-key GOLD-map "\C-P" 'nil)                               ; ^P
  1275. (define-key GOLD-map "\C-Q" 'nil)                               ; ^Q
  1276. (define-key GOLD-map "\C-R" 'nil)                               ; ^R
  1277. (define-key GOLD-map "\C-S" 'nil)                               ; ^S
  1278. (define-key GOLD-map "\C-T" 'nil)                               ; ^T
  1279. (define-key GOLD-map "\C-u" 'upcase-region)                     ; ^U
  1280. (define-key GOLD-map "\C-V" 'nil)                               ; ^V
  1281. (define-key GOLD-map "\C-w" 'write-current-buffers)             ; ^W
  1282. (define-key GOLD-map "\C-X" 'nil)                               ; ^X
  1283. (define-key GOLD-map "\C-Y" 'nil)                               ; ^Y
  1284. (define-key GOLD-map "\C-Z" 'nil)                               ; ^Z
  1285. (define-key GOLD-map " " 'undo)                                 ; SPC
  1286. (define-key GOLD-map "!" 'change-counter-format)                ; !
  1287. (define-key GOLD-map "#" 'insert-counter)                       ; #
  1288. (define-key GOLD-map "$" nil)                                   ; $
  1289. (define-key GOLD-map "%" 'goto-percent)                         ; %
  1290. (define-key GOLD-map "&" nil)                                   ; &
  1291. (define-key GOLD-map "(" nil)                                   ; (
  1292. (define-key GOLD-map ")" nil)                                   ; )
  1293. (define-key GOLD-map "*" 'insert-counter-as-char)               ; *
  1294. (define-key GOLD-map "+" 'region-length-to-counter)             ; +
  1295. (define-key GOLD-map "," 'goto-breadcrumb)                      ; ,
  1296. (define-key GOLD-map "-" 'repeat-command--)                     ; -
  1297. (define-key GOLD-map "." 'drop-breadcrumb)                      ; .
  1298. (define-key GOLD-map "/" 'query-replace)                        ; /
  1299. (define-key GOLD-map "0" 'repeat-command-0)                     ; 0
  1300. (define-key GOLD-map "1" 'repeat-command-1)                     ; 1
  1301. (define-key GOLD-map "2" 'repeat-command-2)                     ; 2
  1302. (define-key GOLD-map "3" 'repeat-command-3)                     ; 3
  1303. (define-key GOLD-map "4" 'repeat-command-4)                     ; 4
  1304. (define-key GOLD-map "5" 'repeat-command-5)                     ; 5
  1305. (define-key GOLD-map "6" 'repeat-command-6)                     ; 6
  1306. (define-key GOLD-map "7" 'repeat-command-7)                     ; 7
  1307. (define-key GOLD-map "8" 'repeat-command-8)                     ; 8
  1308. (define-key GOLD-map "9" 'repeat-command-9)                     ; 9
  1309. (define-key GOLD-map ":" nil)                                   ; :
  1310. (define-key GOLD-map ";" nil)                                   ; ;
  1311. (define-key GOLD-map "<" 'decr-counter)                         ; <
  1312. (define-key GOLD-map "=" 'set-counter)                          ; =
  1313. (define-key GOLD-map ">" 'incr-counter)                         ; >
  1314. (define-key GOLD-map "?" 'spell-check)                          ; ?
  1315. (define-key GOLD-map "A" 'toggle-newline-and-indent)            ; A
  1316. (define-key GOLD-map "B" 'buffer-menu)                          ; B
  1317. (define-key GOLD-map "D" 'shell-command)                        ; D
  1318. (define-key GOLD-map "E" 'find-file-other-window)               ; E
  1319. (define-key GOLD-map "F" 'switch-to-buffer-other-window)        ; F
  1320. (define-key GOLD-map "H" 'bob-unexpand)                         ; H
  1321. (define-key GOLD-map "I" 'insert-file)                          ; I
  1322. (define-key GOLD-map "K" 'kill-this-buffer-now)                 ; K
  1323. (define-key GOLD-map "L" 'report-position)                      ; L
  1324. (define-key GOLD-map "M" 'switch-to-last-buffer)                ; M
  1325. (define-key GOLD-map "N" 'next-error)                           ; N
  1326. (define-key GOLD-map "O" 'shell-command)                        ; O
  1327. (define-key GOLD-map "P" 'lpr-buffer)                           ; P
  1328. (define-key GOLD-map "Q" 'quit-emacs-now)                       ; Q
  1329. (define-key GOLD-map "R" 'revert-file)                          ; R
  1330. (define-key GOLD-map "S" 'replace-string)                       ; S
  1331. (define-key GOLD-map "U" 'set-buffer-clean)                     ; U
  1332. (define-key GOLD-map "V" 'find-file-other-window)               ; V
  1333. (define-key GOLD-map "W" 'other-window)                         ; W
  1334. (define-key GOLD-map "X" 'save-buffers-kill-emacs)              ; X
  1335. (define-key GOLD-map "Y" 'copy-region-as-kill)                  ; Y
  1336. (define-key GOLD-map "Z" 'suspend-emacs)                        ; Z
  1337. (define-key GOLD-map "[" 'blink-matching-open)                  ; [
  1338. (define-key GOLD-map "\\" nil)                                  ; \
  1339. (define-key GOLD-map "]" 'blink-matching-open)                  ; ]
  1340. (define-key GOLD-map "^" nil)                                   ; ^
  1341. (define-key GOLD-map "_" 'split-window-vertically)              ; -
  1342. (define-key GOLD-map "`" 'what-line)                            ; `
  1343. (define-key GOLD-map "a" 'toggle-newline-and-indent)            ; a
  1344. (define-key GOLD-map "b" 'buffer-menu)                          ; b
  1345. (define-key GOLD-map "d" 'shell-command)                        ; d
  1346. (define-key GOLD-map "e" 'find-file)                            ; e
  1347. (define-key GOLD-map "f" 'switch-to-buffer)                     ; f
  1348. (define-key GOLD-map "h" 'bob-expand)                           ; h
  1349. (define-key GOLD-map "i" 'insert-file)                          ; i
  1350. (define-key GOLD-map "k" 'kill-this-buffer)                     ; k
  1351. (define-key GOLD-map "l" 'goto-line)                            ; l
  1352. (define-key GOLD-map "m" 'switch-to-last-buffer)                ; m
  1353. (define-key GOLD-map "n" 'next-error)                           ; n
  1354. (define-key GOLD-map "o" 'shell-command)                        ; o
  1355. (define-key GOLD-map "p" 'lpr-region)                           ; p
  1356. (define-key GOLD-map "q" 'kill-emacs)                           ; q
  1357. (define-key GOLD-map "r" 'revert-file)                          ; r
  1358. (define-key GOLD-map "s" 'query-replace)                        ; s
  1359. (define-key GOLD-map "u" 'set-buffer-clean)                     ; u
  1360. (define-key GOLD-map "v" 'find-file-other-window)               ; v
  1361. (define-key GOLD-map "w" 'next-buffer)                          ; w
  1362. (define-key GOLD-map "x" 'save-all-buffers-kill-emacs)          ; x
  1363. (define-key GOLD-map "y" 'copy-region-as-kill)                  ; y
  1364. (define-key GOLD-map "z" 'suspend-emacs)                        ; z
  1365. (define-key GOLD-map "{" 'nil)                                  ; {
  1366. (define-key GOLD-map "|" 'split-window-horizontally)            ; |
  1367. (define-key GOLD-map "}" 'nil)                                  ; }
  1368. (define-key GOLD-map "~" 'exchange-point-and-mark)              ; ~
  1369. (define-key GOLD-map "\177" 'delete-window)                     ; <X]
  1370.  
  1371. ;;;
  1372. ;;;  GOLD-CSI-map key definitions
  1373. ;;;
  1374. (define-key GOLD-CSI-map "11~" 'nil)                            ; F1
  1375. (define-key GOLD-CSI-map "12~" 'nil)                            ; F2
  1376. (define-key GOLD-CSI-map "13~" 'nil)                            ; F3
  1377. (define-key GOLD-CSI-map "14~" 'nil)                            ; F4
  1378. (define-key GOLD-CSI-map "16~" 'nil)                            ; F5
  1379. (define-key GOLD-CSI-map "17~" 'nil)                            ; F6
  1380. (define-key GOLD-CSI-map "18~" 'nil)                            ; F7
  1381. (define-key GOLD-CSI-map "19~" 'nil)                            ; F8
  1382. (define-key GOLD-CSI-map "20~" 'nil)                            ; F9
  1383. (define-key GOLD-CSI-map "21~" 'nil)                            ; F10
  1384. (define-key GOLD-CSI-map "23~" 'nil)                            ; F11
  1385. (define-key GOLD-CSI-map "24~" 'nil)                            ; F12
  1386. (define-key GOLD-CSI-map "25~" 'nil)                            ; F13
  1387. (define-key GOLD-CSI-map "26~" 'nil)                            ; F14
  1388. (define-key GOLD-CSI-map "28~" 'nil)                            ; HELP
  1389. (define-key GOLD-CSI-map "29~" 'bob-unexpand)                   ; DO
  1390. (define-key GOLD-CSI-map "31~" 'drop-breadcrumb-2)              ; F17
  1391. (define-key GOLD-CSI-map "32~" 'drop-breadcrumb-3)              ; F18
  1392. (define-key GOLD-CSI-map "33~" 'drop-breadcrumb-4)              ; F19
  1393. (define-key GOLD-CSI-map "34~" 'drop-breadcrumb-5)              ; F20
  1394. (define-key GOLD-CSI-map "A" 'scroll-window-down)               ; up-arrow
  1395. (define-key GOLD-CSI-map "B" 'scroll-window-up)                 ; down-arrow
  1396. (define-key GOLD-CSI-map "C" 'reset-screen-size)                ; right-arrow
  1397. (define-key GOLD-CSI-map "D" 'reset-screen-size)                ; left-arrow
  1398. (define-key GOLD-CSI-map "H" 'move-to-beginning)                ; Home IRIS4D
  1399. (define-key GOLD-CSI-map "P" 'backward-delete-char)             ; Delete IRIS4D
  1400. (define-key GOLD-CSI-map "001q" 'bob-unexpand)                  ; F1 IRIS4D
  1401. (define-key GOLD-CSI-map "002q" nil)                            ; F2 IRIS4D
  1402. (define-key GOLD-CSI-map "003q" nil)                            ; F3 IRIS4D
  1403. (define-key GOLD-CSI-map "004q" nil)                            ; F4 IRIS4D
  1404. (define-key GOLD-CSI-map "005q" nil)                            ; F5 IRIS4D
  1405. (define-key GOLD-CSI-map "006q" nil)                            ; F6 IRIS4D
  1406. (define-key GOLD-CSI-map "007q" nil)                            ; F7 IRIS4D
  1407. (define-key GOLD-CSI-map "008q" nil)                            ; F8 IRIS4D
  1408. (define-key GOLD-CSI-map "009q" nil)                            ; F9 IRIS4D*
  1409. (define-key GOLD-CSI-map "010q" nil)                            ; F10 IRIS4D*
  1410. (define-key GOLD-CSI-map "011q" nil)                            ; F11 IRIS4D*
  1411. (define-key GOLD-CSI-map "012q" nil)                            ; F12 IRIS4D*
  1412. (define-key GOLD-CSI-map "139q" 'yank)                          ; Insert IRIS4D
  1413. (define-key GOLD-CSI-map "146q" 'move-to-end)                   ; End IRIS4D
  1414. (define-key GOLD-CSI-map "150q" 'scroll-window-down)            ; PgUp IRIS4D
  1415. (define-key GOLD-CSI-map "154q" 'scroll-window-up)              ; PgDn IRIS4D
  1416. (define-key GOLD-CSI-map "209q" nil)                            ; PrScr IRIS4D
  1417. (define-key GOLD-CSI-map "213q" nil)                            ; ScrLck IRIS4D
  1418. (define-key GOLD-CSI-map "217q" nil)                            ; Pause IRIS4D
  1419.  
  1420. ;;;
  1421. ;;;  GOLD-SS3-map key definitions
  1422. ;;;
  1423. (define-key GOLD-SS3-map "A" 'scroll-window-down)               ; up-arrow
  1424. (define-key GOLD-SS3-map "B" 'scroll-window-up)                 ; down-arrow
  1425. (define-key GOLD-SS3-map "C" 'reset-screen-size)                ; right-arrow
  1426. (define-key GOLD-SS3-map "D" 'reset-screen-size)                ; left-arrow
  1427. (define-key GOLD-SS3-map "P" 'mark-section-wisely)              ; PF1
  1428. (define-key GOLD-SS3-map "Q" 'eval-expression)                  ; PF2
  1429. (define-key GOLD-SS3-map "X" 'eval-expression)                  ; PF2
  1430. (define-key GOLD-SS3-map "S" 'undelete-lines)                   ; PF4
  1431. (define-key GOLD-SS3-map "j" 'undelete-lines)                   ; PF4
  1432. (define-key GOLD-SS3-map "p" 'open-line)                        ; KP0
  1433. (define-key GOLD-SS3-map "q" 'case-flip)                        ; KP1
  1434. (define-key GOLD-SS3-map "r" 'delete-to-eol)                    ; KP2
  1435. (define-key GOLD-SS3-map "s" 'copy-region-as-kill)              ; KP3
  1436. (define-key GOLD-SS3-map "t" 'move-to-end)                      ; KP4
  1437. (define-key GOLD-SS3-map "u" 'move-to-beginning)                ; KP5
  1438. (define-key GOLD-SS3-map "v" 'yank)                             ; KP6
  1439. (define-key GOLD-SS3-map "w" 'execute-extended-command)         ; KP7
  1440. (define-key GOLD-SS3-map "x" 'indent-or-fill-region)            ; KP8
  1441. (define-key GOLD-SS3-map "y" 'replace)                          ; KP9
  1442. (define-key GOLD-SS3-map "m" 'undelete-words)                   ; KP-
  1443. (define-key GOLD-SS3-map "l" 'undelete-chars)                   ; KP,
  1444. (define-key GOLD-SS3-map "k" 'undelete-chars)                   ; KP,
  1445. (define-key GOLD-SS3-map "n" 'unset-mark-command)               ; KP.
  1446.  
  1447. (defun use-tpu nil
  1448.   "Sets bob tpu emulation on."
  1449.   (interactive)
  1450.   (replace-global-key "\e[" CSI-map)
  1451.   (replace-global-key "\eP" DCS-map)
  1452.   (replace-global-key "\eO" SS3-map)
  1453.   (replace-global-key "\C-a" APPLE-map)
  1454.   (replace-global-key "\C-\\" 'quoted-insert)                  ; ^\
  1455.   (replace-global-key "\177" 'delete-previous-char)            ; <X]
  1456.   (replace-global-key "\C-f" 'rename-buffer)                   ; ^F
  1457.   (replace-global-key "\C-j" 'delete-previous-word)            ; ^J (LF)
  1458.   (replace-global-key "\C-k" 'define-macro-key)                ; ^K
  1459.   (replace-global-key "\C-l" 'insert-formfeed)                 ; ^L (FF)
  1460.   (replace-global-key "\C-r" 'recenter)                        ; ^R
  1461.   (replace-global-key "\C-u" 'delete-to-bol)                   ; ^U
  1462.   (define-key SS3-map "P" GOLD-map)
  1463.   (define-key APPLE-map "H\C-M" GOLD-map)
  1464.   (define-key GOLD-map "\e[" GOLD-CSI-map)
  1465.   (define-key GOLD-map "\eO" GOLD-SS3-map)
  1466.   (define-key GOLD-map "\C-A" GOLD-APPLE-map)
  1467.   (DEC-mode)
  1468.   (advance-direction)
  1469.   ;; Make direction of motion show in mode line
  1470.   ;; while TPU emulation is turned on.
  1471.   ;; Note that the keypad is always turned on when in Emacs.
  1472.   (or (assq 'tpu-direction-string minor-mode-alist)
  1473.       (setq minor-mode-alist (cons '(tpu-direction-string tpu-direction-string)
  1474.                    minor-mode-alist)))
  1475.   (or (assq 'newline-and-indent-p minor-mode-alist)
  1476.       (setq minor-mode-alist 
  1477.         (cons '(newline-and-indent-p newline-and-indent-p-string)
  1478.           minor-mode-alist))))
  1479.  
  1480. (defun cancel-tpu nil
  1481.   "Sets bob tpu emulation off."
  1482.   (interactive)
  1483.   (restore-global-key "\e[")
  1484.   (restore-global-key "\eP")
  1485.   (restore-global-key "\eO")
  1486.   (restore-global-key "\C-a")
  1487.   (restore-global-key "\C-\\")
  1488.   (restore-global-key "\177")
  1489.   (restore-global-key "\C-f")
  1490.   (restore-global-key "\C-h")
  1491.   (restore-global-key "\C-j")
  1492.   (restore-global-key "\C-k")
  1493.   (restore-global-key "\C-l")
  1494.   (restore-global-key "\C-r")
  1495.   (restore-global-key "\C-u")
  1496.   (setq tpu-direction-string nil))
  1497.  
  1498. (use-tpu)
  1499.  
  1500. ;;;
  1501. ;;;  Expansions for Bob-expand
  1502. ;;;
  1503. ;;;;
  1504. ;;;;  Expansions for HOOPS
  1505. ;;;;
  1506. (setq tpu-expansions 
  1507.       (list
  1508.        (list "HC_Abort_Program" "HC_Abort_Program();" -2)
  1509.        (list "HC_Append_Modelling_Matrix" "HC_Append_Modelling_Matrix();" -2)
  1510.        (list "HC_Await_Event" "HC_Await_Event();" -2)
  1511.        (list "HC_Bring_To_Front" "HC_Bring_To_Front();" -2)
  1512.        (list "HC_Bring_To_Front_By_Key" "HC_Bring_To_Front_By_Key();" -2)
  1513.        (list "HC_Check_For_Events" "HC_Check_For_Events();" -2)
  1514.        (list "HC_Clear_Display" "HC_Clear_Display();" -2)
  1515.        (list "HC_Close_Segment" "HC_Close_Segment();" -2)
  1516.        (list "HC_Copy_Segment" "HC_Copy_Segment(, );" -4)
  1517.        (list "HC_Create_Segment" "HC_Create_Segment();" -2)
  1518.        (list "HC_Define_Alias" "HC_Define_Alias(, );" -4)
  1519.        (list "HC_Define_Color" "HC_Define_Color(, , , );" -8)
  1520.        (list "HC_Define_Color_Name" "HC_Define_Color_Name(, , , );" -8)
  1521.        (list "HC_Define_Error_Handler" "HC_Define_Error_Handler();" -2)
  1522.        (list "HC_Define_Exit_Handler" "HC_Define_Exit_Handler();" -2)
  1523.        (list "HC_Delete_By_Key" "HC_Delete_By_Key();" -2)
  1524.        (list "HC_Delete_Segment" "HC_Delete_Segment();" -2)
  1525.        (list "HC_Disable_Button_Events" "HC_Disable_Button_Events(, );" -4)
  1526.        (list "HC_Disable_Location_Events" "HC_Disable_Location_Events(, , );" -6)
  1527.        (list "HC_Disable_Selection_Events" "HC_Disable_Selection_Events(, );" -4)
  1528.        (list "HC_Disable_String_Events" "HC_Disable_String_Events(, );" -4)
  1529.        (list "HC_Disable_Wakeup_Events" "HC_Disable_Wakeup_Events();" -2)
  1530.        (list "HC_Dolly_Camera" "HC_Dolly_Camera(, , );" -6)
  1531.        (list "HC_Edit_Pixel_Array" "HC_Edit_Pixel_Array(, , , , , );" -12)
  1532.        (list "HC_Edit_Polygon" "HC_Edit_Polygon(, , , , );" -10)
  1533.        (list "HC_Edit_Polyline" "HC_Edit_Polyline(, , , , );" -10)
  1534.        (list "HC_Edit_Text" "HC_Edit_Text(, , , , , );" -12)
  1535.        (list "HC_Enable_Button_Events" "HC_Enable_Button_Events(, );" -4)
  1536.        (list "HC_Enable_Location_Events" "HC_Enable_Location_Events(, , );" -6)
  1537.        (list "HC_Enable_Selection_Events" "HC_Enable_Selection_Events(, );" -4)
  1538.        (list "HC_Enable_String_Events" "HC_Enable_String_Events(, );" -4)
  1539.        (list "HC_Enable_Wakeup_Events" "HC_Enable_Wakeup_Events();" -2)
  1540.        (list "HC_Exit_Program" "HC_Exit_Program();" -2)
  1541.        (list "HC_Flush_All_Events" "HC_Flush_All_Events();" -2)
  1542.        (list "HC_Flush_By_Key" "HC_Flush_By_Key();" -2)
  1543.        (list "HC_Flush_Segment" "HC_Flush_Segment();" -2)
  1544.        (list "HC_Get_Button" "HC_Get_Button();" -2)
  1545.        (list "HC_Get_Location" "HC_Get_Location(, );" -4)
  1546.        (list "HC_Get_Selection" "HC_Get_Selection();" -2)
  1547.        (list "HC_Get_String" "HC_Get_String(, );" -4)
  1548.        (list "HC_Get_Wakeup" "HC_Get_Wakeup();" -2)
  1549.        (list "HC_Include_Segment" "HC_Include_Segment();" -2)
  1550.        (list "HC_Insert_Ink" "HC_Insert_Ink(, , );" -6)
  1551.        (list "HC_Insert_Line" "HC_Insert_Line(, , , , , );" -12)
  1552.        (list "HC_Insert_Marker" "HC_Insert_Marker(, , );" -6)
  1553.        (list "HC_Insert_Polygon" "HC_Insert_Polygon(, );" -4)
  1554.        (list "HC_Insert_Polyline" "HC_Insert_Polyline(, );" -4)
  1555.        (list "HC_Insert_Polygon_With_Normals" "HC_Insert_Polygon_With_Normals(, , );" -6)
  1556.        (list "HC_Insert_Text" "HC_Insert_Text(, , , );" -8)
  1557.        (list "HC_Insert_Distant_Light" "HC_Insert_Distant_Light(, , );" -6)
  1558.        (list "HC_Insert_Pixel_Array" "HC_Insert_Pixel_Array(, , , , , );" -12)
  1559.        (list "HC_Insert_Pixel_Array_By_Ref" "HC_Insert_Pixel_Array_By_Ref(, , , , , );" -12)
  1560.        (list "HC_KCopy_Segment" "HC_KCopy_Segment(, );" -4)
  1561.        (list "HC_KCreate_Segment" "HC_KCreate_Segment();" -2)
  1562.        (list "HC_KInclude_Segment" "HC_KInclude_Segment();" -2)
  1563.        (list "HC_KInsert_Ink" "HC_KInsert_Ink(, , );" -6)
  1564.        (list "HC_KInsert_Line" "HC_KInsert_Line(, , , , , );" -12)
  1565.        (list "HC_KInsert_Marker" "HC_KInsert_Marker(, , );" -6)
  1566.        (list "HC_KInsert_Polygon" "HC_KInsert_Polygon(, );" -4)
  1567.        (list "HC_KInsert_Polyline" "HC_KInsert_Polyline(, );" -4)
  1568.        (list "HC_KInsert_Polygon_With_Normals" "HC_KInsert_Polygon_With_Normals(, , );" -6)
  1569.        (list "HC_KInsert_String_Cursor" "HC_KInsert_String_Cursor(, , );" -6)
  1570.        (list "HC_KInsert_Text" "HC_KInsert_Text(, , , );" -8)
  1571.        (list "HC_KInsert_Block_Text" "HC_KInsert_Block_Text(, , , , );" -10)
  1572.        (list "HC_KInsert_Distant_Light" "HC_KInsert_Distant_Light(, , );" -6)
  1573.        (list "HC_KInsert_Pixel_Array" "HC_KInsert_Pixel_Array(, , , , , );" -12)
  1574.        (list "HC_KInsert_Pixel_Array_By_Ref" "HC_KInsert_Pixel_Array_By_Ref(, , , , , );" -12)
  1575.        (list "HC_KShow_Owner_By_Key" "HC_KShow_Owner_By_Key();" -2)
  1576.        (list "HC_Modify_Color_Map" "HC_Modify_Color_Map(, );" -4)
  1577.        (list "HC_Modify_Color_Map_By_Value" "HC_Modify_Color_Map_By_Value(, , , );" -8)
  1578.        (list "HC_Move_By_Key" "HC_Move_By_Key(, );" -4)
  1579.        (list "HC_Move_Distant_Light" "HC_Move_Distant_Light(, , , );" -8)
  1580.        (list "HC_Move_Pixel_Array" "HC_Move_Pixel_Array(, , , );" -8)
  1581.        (list "HC_Move_Segment" "HC_Move_Segment(, );" -4)
  1582.        (list "HC_Move_String_Cursor" "HC_Move_String_Cursor(, , );" -6)
  1583.        (list "HC_Open_Segment" "HC_Open_Segment();" -2)
  1584.        (list "HC_KOpen_Segment" "HC_KOpen_Segment();" -2)
  1585.        (list "HC_Open_Segment_By_Key" "HC_Open_Segment_By_Key();" -2)
  1586.        (list "HC_Orbit_Camera" "HC_Orbit_Camera(, );" -4)
  1587.        (list "HC_Pan_Camera" "HC_Pan_Camera(, );" -4)
  1588.        (list "HC_Parse_String" "HC_Parse_String(, , , );" -8)
  1589.        (list "HC_Pause" "HC_Pause();" -2)
  1590.        (list "HC_Print_Version" "HC_Print_Version();" -2)
  1591.        (list "HC_Queue_Special_Event" "HC_Queue_Special_Event(, );" -4)
  1592.        (list "HC_Rename_Segment" "HC_Rename_Segment(, );" -4)
  1593.        (list "HC_Render_Text" "HC_Render_Text(, , , );" -8)
  1594.        (list "HC_Report_Error" "HC_Report_Error(, , , , );" -10)
  1595.        (list "HC_Request_Location" "HC_Request_Location(, );" -4)
  1596.        (list "HC_Requeue_Event" "HC_Requeue_Event();" -2)
  1597.        (list "HC_Reset_System" "HC_Reset_System();" -2)
  1598.        (list "HC_Restart_Ink" "HC_Restart_Ink();" -2)
  1599.        (list "HC_Roll_Camera" "HC_Roll_Camera();" -2)
  1600.        (list "HC_Rotate_Object" "HC_Rotate_Object(, , );" -6)
  1601.        (list "HC_Rotate_Object_Offaxis" "HC_Rotate_Object_Offaxis(, , , );" -8)
  1602.        (list "HC_Scale_Object" "HC_Scale_Object(, , );" -6)
  1603.        (list "HC_Scroll_Text" "HC_Scroll_Text(, , );" -6)
  1604.        (list "HC_Set_Camera" "HC_Set_Camera(, , , , , );" -12)
  1605.        (list "HC_Set_Camera_By_Volume" "HC_Set_Camera_By_Volume(, , , , );" -10)
  1606.        (list "HC_Set_Camera_Field" "HC_Set_Camera_Field(, );" -4)
  1607.        (list "HC_Set_Camera_Position" "HC_Set_Camera_Position(, , );" -6)
  1608.        (list "HC_Set_Camera_Projection" "HC_Set_Camera_Projection();" -2)
  1609.        (list "HC_Set_Camera_Target" "HC_Set_Camera_Target(, , );" -6)
  1610.        (list "HC_Set_Camera_Up_Vector" "HC_Set_Camera_Up_Vector(, , );" -6)
  1611.        (list "HC_Set_Color" "HC_Set_Color();" -2)
  1612.        (list "HC_Set_Color_By_Index" "HC_Set_Color_By_Index(, );" -4)
  1613.        (list "HC_Set_Color_By_Value" "HC_Set_Color_By_Value(, , , , );" -10)
  1614.        (list "HC_Set_Color_Map" "HC_Set_Color_Map();" -2)
  1615.        (list "HC_Set_Color_Map_By_Value" "HC_Set_Color_Map_By_Value(, , );" -6)
  1616.        (list "HC_Set_Driver_Options" "HC_Set_Driver_Options();" -2)
  1617.        (list "HC_Set_Edge_Pattern" "HC_Set_Edge_Pattern();" -2)
  1618.        (list "HC_Set_Edge_Weight" "HC_Set_Edge_Weight();" -2)
  1619.        (list "HC_Set_Face_Pattern" "HC_Set_Face_Pattern();" -2)
  1620.        (list "HC_Set_Handedness" "HC_Set_Handedness();" -2)
  1621.        (list "HC_Set_Heuristics" "HC_Set_Heuristics();" -2)
  1622.        (list "HC_Set_Line_Pattern" "HC_Set_Line_Pattern();" -2)
  1623.        (list "HC_Set_Line_Weight" "HC_Set_Line_Weight();" -2)
  1624.        (list "HC_Set_Marker_Size" "HC_Set_Marker_Size();" -2)
  1625.        (list "HC_Set_Marker_Symbol" "HC_Set_Marker_Symbol();" -2)
  1626.        (list "HC_Set_Metafile" "HC_Set_Metafile();" -2)
  1627.        (list "HC_Set_Modelling_Matrix" "HC_Set_Modelling_Matrix();" -2)
  1628.        (list "HC_Set_Selectability" "HC_Set_Selectability();" -2)
  1629.        (list "HC_Set_Streaming_Mode" "HC_Set_Streaming_Mode();" -2)
  1630.        (list "HC_Set_Text_Alignment" "HC_Set_Text_Alignment();" -2)
  1631.        (list "HC_Set_Text_Font" "HC_Set_Text_Font();" -2)
  1632.        (list "HC_Set_Text_Path" "HC_Set_Text_Path(, , );" -6)
  1633.        (list "HC_Set_Text_Size" "HC_Set_Text_Size();" -2)
  1634.        (list "HC_Set_Text_Spacing" "HC_Set_Text_Spacing();" -2)
  1635.        (list "HC_Set_User_Options" "HC_Set_User_Options();" -2)
  1636.        (list "HC_Set_User_Value" "HC_Set_User_Value();" -2)
  1637.        (list "HC_Set_Visibility" "HC_Set_Visibility();" -2)
  1638.        (list "HC_Set_Window" "HC_Set_Window(, , , );" -8)
  1639.        (list "HC_Set_Window_Frame" "HC_Set_Window_Frame();" -2)
  1640.        (list "HC_Set_Window_Pattern" "HC_Set_Window_Pattern();" -2)
  1641.        (list "HC_Show_Alias" "HC_Show_Alias(, );" -4)
  1642.        (list "HC_Show_Alias_Count" "HC_Show_Alias_Count();" -2)
  1643.        (list "HC_Show_Button" "HC_Show_Button();" -2)
  1644.        (list "HC_Show_Button_Source" "HC_Show_Button_Source(, , );" -6)
  1645.        (list "HC_Show_Camera" "HC_Show_Camera(, , , , , );" -12)
  1646.        (list "HC_Show_Camera_By_Volume" "HC_Show_Camera_By_Volume(, , , , );" -10)
  1647.        (list "HC_Show_Camera_Field" "HC_Show_Camera_Field(, );" -4)
  1648.        (list "HC_Show_Camera_Position" "HC_Show_Camera_Position(, , );" -6)
  1649.        (list "HC_Show_Camera_Projection" "HC_Show_Camera_Projection();" -2)
  1650.        (list "HC_Show_Camera_Target" "HC_Show_Camera_Target(, , );" -6)
  1651.        (list "HC_Show_Camera_Up_Vector" "HC_Show_Camera_Up_Vector(, , );" -6)
  1652.        (list "HC_Show_Color" "HC_Show_Color();" -2)
  1653.        (list "HC_Show_Color_By_Index" "HC_Show_Color_By_Index(, );" -4)
  1654.        (list "HC_Show_Color_By_Value" "HC_Show_Color_By_Value(, , , , );" -10)
  1655.        (list "HC_Show_Color_Map" "HC_Show_Color_Map();" -2)
  1656.        (list "HC_Show_Color_Map_By_Value" "HC_Show_Color_Map_By_Value(, , );" -6)
  1657.        (list "HC_Show_Color_Map_Count" "HC_Show_Color_Map_Count();" -2)
  1658.        (list "HC_Show_Color_Name" "HC_Show_Color_Name(, );" -4)
  1659.        (list "HC_Show_Color_Name_Count" "HC_Show_Color_Name_Count();" -2)
  1660.        (list "HC_Show_Contents_Count" "HC_Show_Contents_Count();" -2)
  1661.        (list "HC_Show_Device_Info" "HC_Show_Device_Info(, , );" -6)
  1662.        (list "HC_Show_Distant_Light" "HC_Show_Distant_Light(, , , );" -8)
  1663.        (list "HC_Show_Driver_Options" "HC_Show_Driver_Options();" -2)
  1664.        (list "HC_Show_Edge_Pattern" "HC_Show_Edge_Pattern();" -2)
  1665.        (list "HC_Show_Edge_Weight" "HC_Show_Edge_Weight();" -2)
  1666.        (list "HC_Show_Environment" "HC_Show_Environment(, );" -4)
  1667.        (list "HC_Show_Face_Pattern" "HC_Show_Face_Pattern();" -2)
  1668.        (list "HC_Show_Handedness" "HC_Show_Handedness();" -2)
  1669.        (list "HC_Show_Heuristics" "HC_Show_Heuristics();" -2)
  1670.        (list "HC_Show_Include_Segment" "HC_Show_Include_Segment(, );" -4)
  1671.        (list "HC_Show_Key_Type" "HC_Show_Key_Type(, );" -4)
  1672.        (list "HC_Show_Line" "HC_Show_Line(, , , , , , );" -14)
  1673.        (list "HC_Show_Line_Pattern" "HC_Show_Line_Pattern();" -2)
  1674.        (list "HC_Show_Line_Weight" "HC_Show_Line_Weight();" -2)
  1675.        (list "HC_Show_Location" "HC_Show_Location(, );" -4)
  1676.        (list "HC_Show_Location_Source" "HC_Show_Location_Source(, , , );" -8)
  1677.        (list "HC_Show_Location_Status" "HC_Show_Location_Status();" -2)
  1678.        (list "HC_Show_Marker" "HC_Show_Marker(, , , );" -8)
  1679.        (list "HC_Show_Marker_Size" "HC_Show_Marker_Size();" -2)
  1680.        (list "HC_Show_Marker_Symbol" "HC_Show_Marker_Symbol();" -2)
  1681.        (list "HC_Show_Memory_Usage" "HC_Show_Memory_Usage(, );" -4)
  1682.        (list "HC_Show_Metafile" "HC_Show_Metafile();" -2)
  1683.        (list "HC_Show_Modelling_Matrix" "HC_Show_Modelling_Matrix();" -2)
  1684.        (list "HC_Show_Net_Camera" "HC_Show_Net_Camera(, , , , , );" -12)
  1685.        (list "HC_Show_Net_Camera_By_Volume" "HC_Show_Net_Camera_By_Volume(, , , , );" -10)
  1686.        (list "HC_Show_Net_Camera_Field" "HC_Show_Net_Camera_Field(, );" -4)
  1687.        (list "HC_Show_Net_Camera_Position" "HC_Show_Net_Camera_Position(, , );" -6)
  1688.        (list "HC_Show_Net_Camera_Projection" "HC_Show_Net_Camera_Projection();" -2)
  1689.        (list "HC_Show_Net_Camera_Target" "HC_Show_Net_Camera_Target(, , );" -6)
  1690.        (list "HC_Show_Net_Camera_Up_Vector" "HC_Show_Net_Camera_Up_Vector(, , );" -6)
  1691.        (list "HC_Show_Net_Color" "HC_Show_Net_Color();" -2)
  1692.        (list "HC_Show_Net_Color_By_Index" "HC_Show_Net_Color_By_Index(, );" -4)
  1693.        (list "HC_Show_Net_Color_By_Value" "HC_Show_Net_Color_By_Value(, , , , );" -10)
  1694.        (list "HC_Show_Net_Color_Map" "HC_Show_Net_Color_Map();" -2)
  1695.        (list "HC_Show_Net_Color_Map_By_Value" "HC_Show_Net_Color_Map_By_Value(, , );" -6)
  1696.        (list "HC_Show_Net_Color_Map_Count" "HC_Show_Net_Color_Map_Count();" -2)
  1697.        (list "HC_Show_Net_Driver_Options" "HC_Show_Net_Driver_Options();" -2)
  1698.        (list "HC_Show_Net_Edge_Pattern" "HC_Show_Net_Edge_Pattern();" -2)
  1699.        (list "HC_Show_Net_Edge_Weight" "HC_Show_Net_Edge_Weight();" -2)
  1700.        (list "HC_Show_Net_Face_Pattern" "HC_Show_Net_Face_Pattern();" -2)
  1701.        (list "HC_Show_Net_Handedness" "HC_Show_Net_Handedness();" -2)
  1702.        (list "HC_Show_Net_Heuristics" "HC_Show_Net_Heuristics();" -2)
  1703.        (list "HC_Show_Net_Line_Pattern" "HC_Show_Net_Line_Pattern();" -2)
  1704.        (list "HC_Show_Net_Line_Weight" "HC_Show_Net_Line_Weight();" -2)
  1705.        (list "HC_Show_Net_Marker_Size" "HC_Show_Net_Marker_Size();" -2)
  1706.        (list "HC_Show_Net_Marker_Symbol" "HC_Show_Net_Marker_Symbol();" -2)
  1707.        (list "HC_Show_Net_Metafile" "HC_Show_Net_Metafile();" -2)
  1708.        (list "HC_Show_Net_Modelling_Matrix" "HC_Show_Net_Modelling_Matrix();" -2)
  1709.        (list "HC_Show_Net_Selectability" "HC_Show_Net_Selectability();" -2)
  1710.        (list "HC_Show_Net_Streaming_Mode" "HC_Show_Net_Streaming_Mode();" -2)
  1711.        (list "HC_Show_Net_Text_Alignment" "HC_Show_Net_Text_Alignment();" -2)
  1712.        (list "HC_Show_Net_Text_Font" "HC_Show_Net_Text_Font();" -2)
  1713.        (list "HC_Show_Net_Text_Path" "HC_Show_Net_Text_Path(, , );" -6)
  1714.        (list "HC_Show_Net_Text_Size" "HC_Show_Net_Text_Size();" -2)
  1715.        (list "HC_Show_Net_Text_Spacing" "HC_Show_Net_Text_Spacing();" -2)
  1716.        (list "HC_Show_Net_User_Options" "HC_Show_Net_User_Options();" -2)
  1717.        (list "HC_Show_Net_User_Value" "HC_Show_Net_User_Value();" -2)
  1718.        (list "HC_Show_Net_Visibility" "HC_Show_Net_Visibility();" -2)
  1719.        (list "HC_Show_Net_Window" "HC_Show_Net_Window(, , , );" -8)
  1720.        (list "HC_Show_Net_Window_Frame" "HC_Show_Net_Window_Frame();" -2)
  1721.        (list "HC_Show_Net_Window_Pattern" "HC_Show_Net_Window_Pattern();" -2)
  1722.        (list "HC_Show_One_Color" "HC_Show_One_Color(, );" -4)
  1723.        (list "HC_Show_One_Color_By_Index" "HC_Show_One_Color_By_Index(, );" -4)
  1724.        (list "HC_Show_One_Color_By_Value" "HC_Show_One_Color_By_Value(, , , , );" -10)
  1725.        (list "HC_Show_One_Color_Map" "HC_Show_One_Color_Map(, );" -4)
  1726.        (list "HC_Show_One_Color_Map_By_Value" "HC_Show_One_Color_Map_By_Value(, , , , );" -10)
  1727.        (list "HC_Show_One_Driver_Option" "HC_Show_One_Driver_Option(, );" -4)
  1728.        (list "HC_Show_One_Heuristic" "HC_Show_One_Heuristic(, );" -4)
  1729.        (list "HC_Show_One_Net_Color" "HC_Show_One_Net_Color(, );" -4)
  1730.        (list "HC_Show_One_Net_Color_By_Index" "HC_Show_One_Net_Color_By_Index(, );" -4)
  1731.        (list "HC_Show_One_Net_Color_By_Value" "HC_Show_One_Net_Color_By_Value(, , , , );" -10)
  1732.        (list "HC_Show_One_Net_Color_Map" "HC_Show_One_Net_Color_Map(, );" -4)
  1733.        (list "HC_Show_One_Net_Color_Map_By_V" "HC_Show_One_Net_Color_Map_By_V(, , , , );" -10)
  1734.        (list "HC_Show_One_Net_Driver_Option" "HC_Show_One_Net_Driver_Option(, );" -4)
  1735.        (list "HC_Show_One_Net_Heuristic" "HC_Show_One_Net_Heuristic(, );" -4)
  1736.        (list "HC_Show_One_Net_Selectability" "HC_Show_One_Net_Selectability(, );" -4)
  1737.        (list "HC_Show_One_Net_Visibility" "HC_Show_One_Net_Visibility(, );" -4)
  1738.        (list "HC_Show_One_Selectability" "HC_Show_One_Selectability(, );" -4)
  1739.        (list "HC_Show_One_Visibility" "HC_Show_One_Visibility(, );" -4)
  1740.        (list "HC_Show_Open_Segment_Count" "HC_Show_Open_Segment_Count();" -2)
  1741.        (list "HC_Show_Owner" "HC_Show_Owner(, );" -4)
  1742.        (list "HC_Show_Owner_By_Key" "HC_Show_Owner_By_Key(, );" -4)
  1743.        (list "HC_Show_Partial_Pixel_Array" "HC_Show_Partial_Pixel_Array(, , , , , );" -12)
  1744.        (list "HC_Show_Partial_Polygon" "HC_Show_Partial_Polygon(, , , );" -8)
  1745.        (list "HC_Show_Partial_Polyline" "HC_Show_Partial_Polyline(, , , );" -8)
  1746.        (list "HC_Show_Pathname_Expansion" "HC_Show_Pathname_Expansion(, );" -4)
  1747.        (list "HC_Show_Pixel_Array" "HC_Show_Pixel_Array(, , , , , , );" -14)
  1748.        (list "HC_Show_Pixel_Array_Size" "HC_Show_Pixel_Array_Size(, , , , , );" -12)
  1749.        (list "HC_Show_Polygon" "HC_Show_Polygon(, , );" -6)
  1750.        (list "HC_Show_Polygon_Count" "HC_Show_Polygon_Count(, );" -4)
  1751.        (list "HC_Show_Polyline" "HC_Show_Polyline(, , );" -6)
  1752.        (list "HC_Show_Polyline_Count" "HC_Show_Polyline_Count(, );" -4)
  1753.        (list "HC_Show_Segment" "HC_Show_Segment(, );" -4)
  1754.        (list "HC_Show_Segment_Count" "HC_Show_Segment_Count();" -2)
  1755.        (list "HC_Show_Selectability" "HC_Show_Selectability();" -2)
  1756.        (list "HC_Show_Selection" "HC_Show_Selection();" -2)
  1757.        (list "HC_Show_Selection_Item" "HC_Show_Selection_Item(, , );" -6)
  1758.        (list "HC_Show_Selection_Location" "HC_Show_Selection_Location(, , , , );" -10)
  1759.        (list "HC_Show_Selection_Pathname" "HC_Show_Selection_Pathname();" -2)
  1760.        (list "HC_Show_Selection_Source" "HC_Show_Selection_Source(, , , );" -8)
  1761.        (list "HC_Show_Special_Event" "HC_Show_Special_Event(, );" -4)
  1762.        (list "HC_Show_Streaming_Mode" "HC_Show_Streaming_Mode();" -2)
  1763.        (list "HC_Show_String" "HC_Show_String();" -2)
  1764.        (list "HC_Show_String_Source" "HC_Show_String_Source(, );" -4)
  1765.        (list "HC_Show_Style_Segment" "HC_Show_Style_Segment(, );" -4)
  1766.        (list "HC_Show_Text" "HC_Show_Text(, , , , );" -10)
  1767.        (list "HC_Show_Text_Alignment" "HC_Show_Text_Alignment();" -2)
  1768.        (list "HC_Show_Text_Font" "HC_Show_Text_Font();" -2)
  1769.        (list "HC_Show_Text_Length" "HC_Show_Text_Length(, );" -4)
  1770.        (list "HC_Show_Text_Path" "HC_Show_Text_Path(, , );" -6)
  1771.        (list "HC_Show_Text_Size" "HC_Show_Text_Size();" -2)
  1772.        (list "HC_Show_Text_Spacing" "HC_Show_Text_Spacing();" -2)
  1773.        (list "HC_Show_Time" "HC_Show_Time();" -2)
  1774.        (list "HC_Show_User_Options" "HC_Show_User_Options();" -2)
  1775.        (list "HC_Show_User_Value" "HC_Show_User_Value();" -2)
  1776.        (list "HC_Show_Visibility" "HC_Show_Visibility();" -2)
  1777.        (list "HC_Show_Wakeup" "HC_Show_Wakeup();" -2)
  1778.        (list "HC_Show_Window" "HC_Show_Window(, , , );" -8)
  1779.        (list "HC_Show_Window_Frame" "HC_Show_Window_Frame();" -2)
  1780.        (list "HC_Show_Window_Pattern" "HC_Show_Window_Pattern();" -2)
  1781.        (list "HC_Style_Segment" "HC_Style_Segment();" -2)
  1782.        (list "HC_KStyle_Segment" "HC_KStyle_Segment();" -2)
  1783.        (list "HC_Translate_Object" "HC_Translate_Object(, , );" -6)
  1784.        (list "HC_UnDefine_Alias" "HC_UnDefine_Alias();" -2)
  1785.        (list "HC_UnDefine_Color" "HC_UnDefine_Color();" -2)
  1786.        (list "HC_UnDefine_Color_Name" "HC_UnDefine_Color_Name();" -2)
  1787.        (list "HC_UnDefine_Error_Handler" "HC_UnDefine_Error_Handler();" -2)
  1788.        (list "HC_UnDefine_Exit_Handler" "HC_UnDefine_Exit_Handler();" -2)
  1789.        (list "HC_UnSet_Camera" "HC_UnSet_Camera();" -2)
  1790.        (list "HC_UnSet_Color" "HC_UnSet_Color();" -2)
  1791.        (list "HC_UnSet_Color_Map" "HC_UnSet_Color_Map();" -2)
  1792.        (list "HC_UnSet_Driver_Options" "HC_UnSet_Driver_Options();" -2)
  1793.        (list "HC_UnSet_Edge_Pattern" "HC_UnSet_Edge_Pattern();" -2)
  1794.        (list "HC_UnSet_Edge_Weight" "HC_UnSet_Edge_Weight();" -2)
  1795.        (list "HC_UnSet_Face_Pattern" "HC_UnSet_Face_Pattern();" -2)
  1796.        (list "HC_UnSet_Handedness" "HC_UnSet_Handedness();" -2)
  1797.        (list "HC_UnSet_Heuristics" "HC_UnSet_Heuristics();" -2)
  1798.        (list "HC_UnSet_Line_Pattern" "HC_UnSet_Line_Pattern();" -2)
  1799.        (list "HC_UnSet_Line_Weight" "HC_UnSet_Line_Weight();" -2)
  1800.        (list "HC_UnSet_Marker_Size" "HC_UnSet_Marker_Size();" -2)
  1801.        (list "HC_UnSet_Marker_Symbol" "HC_UnSet_Marker_Symbol();" -2)
  1802.        (list "HC_UnSet_Metafile" "HC_UnSet_Metafile();" -2)
  1803.        (list "HC_UnSet_Modelling_Matrix" "HC_UnSet_Modelling_Matrix();" -2)
  1804.        (list "HC_UnSet_Selectability" "HC_UnSet_Selectability();" -2)
  1805.        (list "HC_UnSet_Streaming_Mode" "HC_UnSet_Streaming_Mode();" -2)
  1806.        (list "HC_UnSet_Text_Alignment" "HC_UnSet_Text_Alignment();" -2)
  1807.        (list "HC_UnSet_Text_Font" "HC_UnSet_Text_Font();" -2)
  1808.        (list "HC_UnSet_Text_Path" "HC_UnSet_Text_Path();" -2)
  1809.        (list "HC_UnSet_Text_Size" "HC_UnSet_Text_Size();" -2)
  1810.        (list "HC_UnSet_Text_Spacing" "HC_UnSet_Text_Spacing();" -2)
  1811.        (list "HC_UnSet_User_Options" "HC_UnSet_User_Options();" -2)
  1812.        (list "HC_UnSet_User_Value" "HC_UnSet_User_Value();" -2)
  1813.        (list "HC_UnSet_Visibility" "HC_UnSet_Visibility();" -2)
  1814.        (list "HC_UnSet_Window" "HC_UnSet_Window();" -2)
  1815.        (list "HC_UnSet_Window_Frame" "HC_UnSet_Window_Frame();" -2)
  1816.        (list "HC_UnSet_Window_Pattern" "HC_UnSet_Window_Pattern();" -2)
  1817.        (list "HC_Update_Display" "HC_Update_Display();" -2)
  1818.        (list "HC_Zoom_Camera" "HC_Zoom_Camera();" -2)
  1819.        (list "HC_QAppend_Modelling_Matrix" "HC_QAppend_Modelling_Matrix(, );" -4)
  1820.        (list "HC_QDolly_Camera" "HC_QDolly_Camera(, , , );" -8)
  1821.        (list "HC_QModify_Color_Map" "HC_QModify_Color_Map(, , );" -6)
  1822.        (list "HC_QModify_Color_Map_By_Value" "HC_QModify_Color_Map_By_Value(, , , , );" -10)
  1823.        (list "HC_QOrbit_Camera" "HC_QOrbit_Camera(, , );" -6)
  1824.        (list "HC_QPan_Camera" "HC_QPan_Camera(, , );" -6)
  1825.        (list "HC_QRoll_Camera" "HC_QRoll_Camera(, );" -4)
  1826.        (list "HC_QRotate_Object" "HC_QRotate_Object(, , , );" -8)
  1827.        (list "HC_QRotate_Object_Offaxis" "HC_QRotate_Object_Offaxis(, , , , );" -10)
  1828.        (list "HC_QScale_Object" "HC_QScale_Object(, , , );" -8)
  1829.        (list "HC_QSet_Camera" "HC_QSet_Camera(, , , , , , );" -14)
  1830.        (list "HC_QSet_Camera_By_Volume" "HC_QSet_Camera_By_Volume(, , , , , );" -12)
  1831.        (list "HC_QSet_Camera_Field" "HC_QSet_Camera_Field(, , );" -6)
  1832.        (list "HC_QSet_Camera_Position" "HC_QSet_Camera_Position(, , , );" -8)
  1833.        (list "HC_QSet_Camera_Projection" "HC_QSet_Camera_Projection(, );" -4)
  1834.        (list "HC_QSet_Camera_Target" "HC_QSet_Camera_Target(, , , );" -8)
  1835.        (list "HC_QSet_Camera_Up_Vector" "HC_QSet_Camera_Up_Vector(, , , );" -8)
  1836.        (list "HC_QSet_Color" "HC_QSet_Color(, );" -4)
  1837.        (list "HC_QSet_Color_By_Index" "HC_QSet_Color_By_Index(, , );" -6)
  1838.        (list "HC_QSet_Color_By_Value" "HC_QSet_Color_By_Value(, , , , , );" -12)
  1839.        (list "HC_QSet_Color_Map" "HC_QSet_Color_Map(, );" -4)
  1840.        (list "HC_QSet_Color_Map_By_Value" "HC_QSet_Color_Map_By_Value(, , , );" -8)
  1841.        (list "HC_QSet_Driver_Options" "HC_QSet_Driver_Options(, );" -4)
  1842.        (list "HC_QSet_Edge_Pattern" "HC_QSet_Edge_Pattern(, );" -4)
  1843.        (list "HC_QSet_Edge_Weight" "HC_QSet_Edge_Weight(, );" -4)
  1844.        (list "HC_QSet_Face_Pattern" "HC_QSet_Face_Pattern(, );" -4)
  1845.        (list "HC_QSet_Handedness" "HC_QSet_Handedness(, );" -4)
  1846.        (list "HC_QSet_Heuristics" "HC_QSet_Heuristics(, );" -4)
  1847.        (list "HC_QSet_Line_Pattern" "HC_QSet_Line_Pattern(, );" -4)
  1848.        (list "HC_QSet_Line_Weight" "HC_QSet_Line_Weight(, );" -4)
  1849.        (list "HC_QSet_Marker_Size" "HC_QSet_Marker_Size(, );" -4)
  1850.        (list "HC_QSet_Marker_Symbol" "HC_QSet_Marker_Symbol(, );" -4)
  1851.        (list "HC_QSet_Metafile" "HC_QSet_Metafile(, );" -4)
  1852.        (list "HC_QSet_Modelling_Matrix" "HC_QSet_Modelling_Matrix(, );" -4)
  1853.        (list "HC_QSet_Selectability" "HC_QSet_Selectability(, );" -4)
  1854.        (list "HC_QSet_Streaming_Mode" "HC_QSet_Streaming_Mode(, );" -4)
  1855.        (list "HC_QSet_Text_Alignment" "HC_QSet_Text_Alignment(, );" -4)
  1856.        (list "HC_QSet_Text_Font" "HC_QSet_Text_Font(, );" -4)
  1857.        (list "HC_QSet_Text_Path" "HC_QSet_Text_Path(, , , );" -8)
  1858.        (list "HC_QSet_Text_Size" "HC_QSet_Text_Size(, );" -4)
  1859.        (list "HC_QSet_Text_Spacing" "HC_QSet_Text_Spacing(, );" -4)
  1860.        (list "HC_QSet_User_Options" "HC_QSet_User_Options(, );" -4)
  1861.        (list "HC_QSet_User_Value" "HC_QSet_User_Value(, );" -4)
  1862.        (list "HC_QSet_Visibility" "HC_QSet_Visibility(, );" -4)
  1863.        (list "HC_QSet_Window" "HC_QSet_Window(, , , , );" -10)
  1864.        (list "HC_QSet_Window_Frame" "HC_QSet_Window_Frame(, );" -4)
  1865.        (list "HC_QSet_Window_Pattern" "HC_QSet_Window_Pattern(, );" -4)
  1866.        (list "HC_QShow_Camera" "HC_QShow_Camera(, , , , , , );" -14)
  1867.        (list "HC_QShow_Camera_By_Volume" "HC_QShow_Camera_By_Volume(, , , , , );" -12)
  1868.        (list "HC_QShow_Camera_Field" "HC_QShow_Camera_Field(, , );" -6)
  1869.        (list "HC_QShow_Camera_Position" "HC_QShow_Camera_Position(, , , );" -8)
  1870.        (list "HC_QShow_Camera_Projection" "HC_QShow_Camera_Projection(, );" -4)
  1871.        (list "HC_QShow_Camera_Target" "HC_QShow_Camera_Target(, , , );" -8)
  1872.        (list "HC_QShow_Camera_Up_Vector" "HC_QShow_Camera_Up_Vector(, , , );" -8)
  1873.        (list "HC_QShow_Color" "HC_QShow_Color(, );" -4)
  1874.        (list "HC_QShow_Color_By_Index" "HC_QShow_Color_By_Index(, , );" -6)
  1875.        (list "HC_QShow_Color_By_Value" "HC_QShow_Color_By_Value(, , , , , );" -12)
  1876.        (list "HC_QShow_Color_Map" "HC_QShow_Color_Map(, );" -4)
  1877.        (list "HC_QShow_Color_Map_By_Value" "HC_QShow_Color_Map_By_Value(, , , );" -8)
  1878.        (list "HC_QShow_Color_Map_Count" "HC_QShow_Color_Map_Count(, );" -4)
  1879.        (list "HC_QShow_Driver_Options" "HC_QShow_Driver_Options(, );" -4)
  1880.        (list "HC_QShow_Edge_Pattern" "HC_QShow_Edge_Pattern(, );" -4)
  1881.        (list "HC_QShow_Edge_Weight" "HC_QShow_Edge_Weight(, );" -4)
  1882.        (list "HC_QShow_Face_Pattern" "HC_QShow_Face_Pattern(, );" -4)
  1883.        (list "HC_QShow_Handedness" "HC_QShow_Handedness(, );" -4)
  1884.        (list "HC_QShow_Heuristics" "HC_QShow_Heuristics(, );" -4)
  1885.        (list "HC_QShow_Line_Pattern" "HC_QShow_Line_Pattern(, );" -4)
  1886.        (list "HC_QShow_Line_Weight" "HC_QShow_Line_Weight(, );" -4)
  1887.        (list "HC_QShow_Marker_Size" "HC_QShow_Marker_Size(, );" -4)
  1888.        (list "HC_QShow_Marker_Symbol" "HC_QShow_Marker_Symbol(, );" -4)
  1889.        (list "HC_QShow_Metafile" "HC_QShow_Metafile(, );" -4)
  1890.        (list "HC_QShow_Modelling_Matrix" "HC_QShow_Modelling_Matrix(, );" -4)
  1891.        (list "HC_QShow_Net_Camera" "HC_QShow_Net_Camera(, , , , , , );" -14)
  1892.        (list "HC_QShow_Net_Camera_By_Volume" "HC_QShow_Net_Camera_By_Volume(, , , , , );" -12)
  1893.        (list "HC_QShow_Net_Camera_Field" "HC_QShow_Net_Camera_Field(, , );" -6)
  1894.        (list "HC_QShow_Net_Camera_Position" "HC_QShow_Net_Camera_Position(, , , );" -8)
  1895.        (list "HC_QShow_Net_Camera_Projection" "HC_QShow_Net_Camera_Projection(, );" -4)
  1896.        (list "HC_QShow_Net_Camera_Target" "HC_QShow_Net_Camera_Target(, , , );" -8)
  1897.        (list "HC_QShow_Net_Camera_Up_Vector" "HC_QShow_Net_Camera_Up_Vector(, , , );" -8)
  1898.        (list "HC_QShow_Net_Color" "HC_QShow_Net_Color(, );" -4)
  1899.        (list "HC_QShow_Net_Color_By_Index" "HC_QShow_Net_Color_By_Index(, , );" -6)
  1900.        (list "HC_QShow_Net_Color_By_Value" "HC_QShow_Net_Color_By_Value(, , , , , );" -12)
  1901.        (list "HC_QShow_Net_Color_Map" "HC_QShow_Net_Color_Map(, );" -4)
  1902.        (list "HC_QShow_Net_Color_Map_By_Value" "HC_QShow_Net_Color_Map_By_Value(, , , );" -8)
  1903.        (list "HC_QShow_Net_Color_Map_Count" "HC_QShow_Net_Color_Map_Count(, );" -4)
  1904.        (list "HC_QShow_Net_Driver_Options" "HC_QShow_Net_Driver_Options(, );" -4)
  1905.        (list "HC_QShow_Net_Edge_Pattern" "HC_QShow_Net_Edge_Pattern(, );" -4)
  1906.        (list "HC_QShow_Net_Edge_Weight" "HC_QShow_Net_Edge_Weight(, );" -4)
  1907.        (list "HC_QShow_Net_Face_Pattern" "HC_QShow_Net_Face_Pattern(, );" -4)
  1908.        (list "HC_QShow_Net_Handedness" "HC_QShow_Net_Handedness(, );" -4)
  1909.        (list "HC_QShow_Net_Heuristics" "HC_QShow_Net_Heuristics(, );" -4)
  1910.        (list "HC_QShow_Net_Line_Pattern" "HC_QShow_Net_Line_Pattern(, );" -4)
  1911.        (list "HC_QShow_Net_Line_Weight" "HC_QShow_Net_Line_Weight(, );" -4)
  1912.        (list "HC_QShow_Net_Marker_Size" "HC_QShow_Net_Marker_Size(, );" -4)
  1913.        (list "HC_QShow_Net_Marker_Symbol" "HC_QShow_Net_Marker_Symbol(, );" -4)
  1914.        (list "HC_QShow_Net_Metafile" "HC_QShow_Net_Metafile(, );" -4)
  1915.        (list "HC_QShow_Net_Modelling_Matrix" "HC_QShow_Net_Modelling_Matrix(, );" -4)
  1916.        (list "HC_QShow_Net_Selectability" "HC_QShow_Net_Selectability(, );" -4)
  1917.        (list "HC_QShow_Net_Streaming_Mode" "HC_QShow_Net_Streaming_Mode(, );" -4)
  1918.        (list "HC_QShow_Net_Text_Alignment" "HC_QShow_Net_Text_Alignment(, );" -4)
  1919.        (list "HC_QShow_Net_Text_Font" "HC_QShow_Net_Text_Font(, );" -4)
  1920.        (list "HC_QShow_Net_Text_Path" "HC_QShow_Net_Text_Path(, , , );" -8)
  1921.        (list "HC_QShow_Net_Text_Size" "HC_QShow_Net_Text_Size(, );" -4)
  1922.        (list "HC_QShow_Net_Text_Spacing" "HC_QShow_Net_Text_Spacing(, );" -4)
  1923.        (list "HC_QShow_Net_User_Options" "HC_QShow_Net_User_Options(, );" -4)
  1924.        (list "HC_QShow_Net_User_Value" "HC_QShow_Net_User_Value(, );" -4)
  1925.        (list "HC_QShow_Net_Visibility" "HC_QShow_Net_Visibility(, );" -4)
  1926.        (list "HC_QShow_Net_Window" "HC_QShow_Net_Window(, , , , );" -10)
  1927.        (list "HC_QShow_Net_Window_Frame" "HC_QShow_Net_Window_Frame(, );" -4)
  1928.        (list "HC_QShow_Net_Window_Pattern" "HC_QShow_Net_Window_Pattern(, );" -4)
  1929.        (list "HC_QShow_One_Color" "HC_QShow_One_Color(, , );" -6)
  1930.        (list "HC_QShow_One_Color_By_Index" "HC_QShow_One_Color_By_Index(, , );" -6)
  1931.        (list "HC_QShow_One_Color_By_Value" "HC_QShow_One_Color_By_Value(, , , , , );" -12)
  1932.        (list "HC_QShow_One_Color_Map" "HC_QShow_One_Color_Map(, , );" -6)
  1933.        (list "HC_QShow_One_Color_Map_By_Value" "HC_QShow_One_Color_Map_By_Value(, , , , , );" -12)
  1934.        (list "HC_QShow_One_Driver_Option" "HC_QShow_One_Driver_Option(, , );" -6)
  1935.        (list "HC_QShow_One_Heuristic" "HC_QShow_One_Heuristic(, , );" -6)
  1936.        (list "HC_QShow_One_Net_Color" "HC_QShow_One_Net_Color(, , );" -6)
  1937.        (list "HC_QShow_One_Net_Color_By_Index" "HC_QShow_One_Net_Color_By_Index(, , );" -6)
  1938.        (list "HC_QShow_One_Net_Color_By_Value" "HC_QShow_One_Net_Color_By_Value(, , , , , );" -12)
  1939.        (list "HC_QShow_One_Net_Color_Map" "HC_QShow_One_Net_Color_Map(, , );" -6)
  1940.        (list "HC_QShow_One_Net_Color_Map_By_V" "HC_QShow_One_Net_Color_Map_By_V(, , , , , );" -12)
  1941.        (list "HC_QShow_One_Net_Driver_Option" "HC_QShow_One_Net_Driver_Option(, , );" -6)
  1942.        (list "HC_QShow_One_Net_Heuristic" "HC_QShow_One_Net_Heuristic(, , );" -6)
  1943.        (list "HC_QShow_One_Net_Selectability" "HC_QShow_One_Net_Selectability(, , );" -6)
  1944.        (list "HC_QShow_One_Net_Visibility" "HC_QShow_One_Net_Visibility(, , );" -6)
  1945.        (list "HC_QShow_One_Selectability" "HC_QShow_One_Selectability(, , );" -6)
  1946.        (list "HC_QShow_One_Visibility" "HC_QShow_One_Visibility(, , );" -6)
  1947.        (list "HC_QShow_Selectability" "HC_QShow_Selectability(, );" -4)
  1948.        (list "HC_QShow_Streaming_Mode" "HC_QShow_Streaming_Mode(, );" -4)
  1949.        (list "HC_QShow_Text_Alignment" "HC_QShow_Text_Alignment(, );" -4)
  1950.        (list "HC_QShow_Text_Font" "HC_QShow_Text_Font(, );" -4)
  1951.        (list "HC_QShow_Text_Path" "HC_QShow_Text_Path(, , , );" -8)
  1952.        (list "HC_QShow_Text_Size" "HC_QShow_Text_Size(, );" -4)
  1953.        (list "HC_QShow_Text_Spacing" "HC_QShow_Text_Spacing(, );" -4)
  1954.        (list "HC_QShow_User_Options" "HC_QShow_User_Options(, );" -4)
  1955.        (list "HC_QShow_User_Value" "HC_QShow_User_Value(, );" -4)
  1956.        (list "HC_QShow_Visibility" "HC_QShow_Visibility(, );" -4)
  1957.        (list "HC_QShow_Window" "HC_QShow_Window(, , , , );" -10)
  1958.        (list "HC_QShow_Window_Frame" "HC_QShow_Window_Frame(, );" -4)
  1959.        (list "HC_QShow_Window_Pattern" "HC_QShow_Window_Pattern(, );" -4)
  1960.        (list "HC_QTranslate_Object" "HC_QTranslate_Object(, , , );" -8)
  1961.        (list "HC_QUnSet_Camera" "HC_QUnSet_Camera();" -2)
  1962.        (list "HC_QUnSet_Color" "HC_QUnSet_Color();" -2)
  1963.        (list "HC_QUnSet_Color_Map" "HC_QUnSet_Color_Map();" -2)
  1964.        (list "HC_QUnSet_Driver_Options" "HC_QUnSet_Driver_Options();" -2)
  1965.        (list "HC_QUnSet_Edge_Pattern" "HC_QUnSet_Edge_Pattern();" -2)
  1966.        (list "HC_QUnSet_Edge_Weight" "HC_QUnSet_Edge_Weight();" -2)
  1967.        (list "HC_QUnSet_Face_Pattern" "HC_QUnSet_Face_Pattern();" -2)
  1968.        (list "HC_QUnSet_Handedness" "HC_QUnSet_Handedness();" -2)
  1969.        (list "HC_QUnSet_Heuristics" "HC_QUnSet_Heuristics();" -2)
  1970.        (list "HC_QUnSet_Line_Pattern" "HC_QUnSet_Line_Pattern();" -2)
  1971.        (list "HC_QUnSet_Line_Weight" "HC_QUnSet_Line_Weight();" -2)
  1972.        (list "HC_QUnSet_Marker_Size" "HC_QUnSet_Marker_Size();" -2)
  1973.        (list "HC_QUnSet_Marker_Symbol" "HC_QUnSet_Marker_Symbol();" -2)
  1974.        (list "HC_QUnSet_Metafile" "HC_QUnSet_Metafile();" -2)
  1975.        (list "HC_QUnSet_Modelling_Matrix" "HC_QUnSet_Modelling_Matrix();" -2)
  1976.        (list "HC_QUnSet_Selectability" "HC_QUnSet_Selectability();" -2)
  1977.        (list "HC_QUnSet_Streaming_Mode" "HC_QUnSet_Streaming_Mode();" -2)
  1978.        (list "HC_QUnSet_Text_Alignment" "HC_QUnSet_Text_Alignment();" -2)
  1979.        (list "HC_QUnSet_Text_Font" "HC_QUnSet_Text_Font();" -2)
  1980.        (list "HC_QUnSet_Text_Path" "HC_QUnSet_Text_Path();" -2)
  1981.        (list "HC_QUnSet_Text_Size" "HC_QUnSet_Text_Size();" -2)
  1982.        (list "HC_QUnSet_Text_Spacing" "HC_QUnSet_Text_Spacing();" -2)
  1983.        (list "HC_QUnSet_User_Options" "HC_QUnSet_User_Options();" -2)
  1984.        (list "HC_QUnSet_User_Value" "HC_QUnSet_User_Value();" -2)
  1985.        (list "HC_QUnSet_Visibility" "HC_QUnSet_Visibility();" -2)
  1986.        (list "HC_QUnSet_Window" "HC_QUnSet_Window();" -2)
  1987.        (list "HC_QUnSet_Window_Frame" "HC_QUnSet_Window_Frame();" -2)
  1988.        (list "HC_QUnSet_Window_Pattern" "HC_QUnSet_Window_Pattern();" -2)
  1989.        (list "HC_QZoom_Camera" "HC_QZoom_Camera(, );" -4)
  1990.        (list "HC_Set_Driver" "HC_Set_Driver();" -2)
  1991.        (list "HC_Show_Driver" "HC_Show_Driver();" -2)
  1992.        (list "HC_Show_Net_Driver" "HC_Show_Net_Driver();" -2)
  1993.        (list "HC_UnSet_Driver" "HC_UnSet_Driver();" -2)
  1994.        (list "HC_QSet_Driver" "HC_QSet_Driver(, );" -4)
  1995.        (list "HC_QShow_Driver" "HC_QShow_Driver(, );" -4)
  1996.        (list "HC_QShow_Net_Driver" "HC_QShow_Net_Driver(, );" -4)
  1997.        (list "HC_QUnSet_Driver" "HC_QUnSet_Driver();" -2)
  1998.        (list "HC_Begin_Alias_Search" "HC_Begin_Alias_Search();" -2)
  1999.        (list "HC_Begin_Color_Name_Search" "HC_Begin_Color_Name_Search();" -2)
  2000.        (list "HC_Begin_Contents_Search" "HC_Begin_Contents_Search(, );" -4)
  2001.        (list "HC_Begin_Open_Segment_Search" "HC_Begin_Open_Segment_Search();" -2)
  2002.        (list "HC_Begin_Segment_Search" "HC_Begin_Segment_Search();" -2)
  2003.        (list "HC_Find_Alias" "HC_Find_Alias();" -2)
  2004.        (list "HC_Find_Color_Name" "HC_Find_Color_Name(, , );" -6)
  2005.        (list "HC_Find_Contents" "HC_Find_Contents(, );" -4)
  2006.        (list "HC_Find_Open_Segment" "HC_Find_Open_Segment();" -2)
  2007.        (list "HC_Find_Segment" "HC_Find_Segment();" -2)
  2008.        (list "HC_End_Alias_Search" "HC_End_Alias_Search();" -2)
  2009.        (list "HC_End_Color_Name_Search" "HC_End_Color_Name_Search();" -2)
  2010.        (list "HC_End_Contents_Search" "HC_End_Contents_Search();" -2)
  2011.        (list "HC_End_Open_Segment_Search" "HC_End_Open_Segment_Search();" -2)
  2012.        (list "HC_End_Segment_Search" "HC_End_Segment_Search();" -2)
  2013. ;;;;
  2014. ;;;; Expansions for BobGadgets
  2015. ;;;;
  2016.        (list "GB_Set_Defaults" "GB_Set_Defaults();" -2)
  2017.        (list "GB_Set_Colors" "GB_Set_Colors(, , , , , , , );" -16)
  2018.        (list "GB_Push_Colors" "GB_Push_Colors();" -2)
  2019.        (list "GB_Pop_Colors" "GB_Pop_Colors();" -2)
  2020.        (list "GB_Set_Bar_Size" "GB_Set_Bar_Size(, );" -4)
  2021.        (list "GB_Push_Bar_Size" "GB_Push_Bar_Size();" -2)
  2022.        (list "GB_Pop_Bar_Size" "GB_Pop_Bar_Size();" -2)
  2023.        (list "GB_Draw_Edged_Window" "GB_Draw_Edged_Window();" -2)
  2024.        (list "GB_Hilite_Edged_Window" "GB_Hilite_Edged_Window();" -2)
  2025.        (list "GB_Draw_Plain_Window" "GB_Draw_Plain_Window();" -2)
  2026.        (list "GB_Hilite_Plain_Window" "GB_Hilite_Plain_Window();" -2)
  2027.        (list "GB_Make_Button" "GB_Make_Button(, , , , , , , , , );" -20)
  2028.        (list "GB_Make_Slider" "GB_Make_Slider(, , , , , , , , );" -18)
  2029.        (list "GB_Make_Icon" "GB_Make_Icon(, , , , , , , );" -16)
  2030.        (list "GB_Make_Sizable_Window" "GB_Make_Sizable_Window(, , , , , );" -12)
  2031.        (list "GB_Make_Closable_Sizable_Window" "GB_Make_Closable_Sizable_Window(, , , , , , );" -14)
  2032.        (list "GB_Make_Titled_Window" "GB_Make_Titled_Window(, , , , , , );" -14)
  2033.        (list "GB_Make_Weird_Window" "GB_Make_Weird_Window(, , , , , , );" -14)
  2034.        (list "GB_Draw_Edged_Scroll_Up" "GB_Draw_Edged_Scroll_Up();" -2)
  2035.        (list "GB_Draw_Edged_Scroll_Down" "GB_Draw_Edged_Scroll_Down();" -2)
  2036.        (list "GB_Scroll_Up" "GB_Scroll_Up(, );" -4)
  2037.        (list "GB_Scroll_Down" "GB_Scroll_Down(, );" -4)
  2038.        (list "GB_Add_To_Spreadsheet" "GB_Add_To_Spreadsheet(, , );" -6)
  2039.        (list "GB_Clear_Spreadsheet" "GB_Clear_Spreadsheet();" -2)
  2040.        (list "GB_Update_Spreadsheet" "GB_Update_Spreadsheet();" -2)
  2041.        (list "GB_Update_Base_Spreadsheet" "GB_Update_Base_Spreadsheet();" -2)
  2042.        (list "GB_Resize_Spreadsheet" "GB_Resize_Spreadsheet(, );" -4)
  2043.        (list "GB_Resize_Base_Spreadsheet" "GB_Resize_Base_Spreadsheet(, );" -4)
  2044.        (list "GB_Update_Input_And_Send" "GB_Update_Input_And_Send(, );" -4)
  2045.        (list "GB_Make_Spreadsheet" "GB_Make_Spreadsheet(, , , , , , , , , , , , , , , , , );" -36)
  2046.        (list "GB_Make_Selector" "GB_Make_Selector(, , , , , , , );" -16)
  2047.        (list "GB_Make_Circular_Selector" "GB_Make_Circular_Selector(, , , , , , , );" -16)
  2048.        (list "GB_Add_To_Text_List" "GB_Add_To_Text_List(, , );" -6)
  2049.        (list "GB_Clear_Text_List" "GB_Clear_Text_List();" -2)
  2050.        (list "GB_Update_Selector_List" "GB_Update_Selector_List();" -2)
  2051.        (list "GB_Resize_Selector_List" "GB_Resize_Selector_List(, );" -4)
  2052.        (list "GB_Draw_Slider" "GB_Draw_Slider();" -2)
  2053.        (list "GB_Make_Titled_Slider_Window" "GB_Make_Titled_Slider_Window(, , , , , , , , , );" -20)
  2054.        (list "GS_Toggle" "GS_Toggle(, );" -4)
  2055.        (list "GS_Action" "GS_Action(, );" -4)
  2056.        (list "GS_Confirm" "GS_Confirm(, );" -4)
  2057.        (list "GS_Blender" "GS_Blender(, );" -4)
  2058.        (list "GS_Drag" "GS_Drag(, );" -4)
  2059.        (list "GS_Resize" "GS_Resize(, );" -4)
  2060.        (list "GS_Icon" "GS_Icon(, );" -4)
  2061.        (list "GS_Icon_Drag" "GS_Icon_Drag(, );" -4)
  2062.        (list "GS_Open_Close" "GS_Open_Close(, );" -4)
  2063.        (list "GS_Delete_Single" "GS_Delete_Single(, );" -4)
  2064.        (list "GS_Delete_Multiple" "GS_Delete_Multiple(, );" -4)
  2065.        (list "GS_Edit_Text" "GS_Edit_Text(, );" -4)
  2066.        (list "GS_Send_Text" "GS_Send_Text(, );" -4)
  2067.        (list "GS_Continuous_Action" "GS_Continuous_Action(, );" -4)
  2068.        (list "GS_Change_Action" "GS_Change_Action(, );" -4)
  2069.        (list "GS_Slider" "GS_Slider(, );" -4)
  2070.        (list "GI_Free_Gadget" "GI_Free_Gadget(, );" -4)
  2071.        (list "GI_Free_Gadget_Now" "GI_Free_Gadget_Now(, );" -4)
  2072.        (list "GI_Free_Deferred_Gadgets" "GI_Free_Deferred_Gadgets();" -2)
  2073.        (list "GI_Set_Draw_Routines" "GI_Set_Draw_Routines(, );" -4)
  2074.        (list "GI_Push_Draw_Routines" "GI_Push_Draw_Routines();" -2)
  2075.        (list "GI_Pop_Draw_Routines" "GI_Pop_Draw_Routines();" -2)
  2076.        (list "GI_Enable_Updates" "GI_Enable_Updates();" -2)
  2077.        (list "GI_Disable_Updates" "GI_Disable_Updates();" -2)
  2078.        (list "GI_Make_Gadget" "GI_Make_Gadget(, , , , , , , , );" -18)
  2079.        (list "GI_Show_Gadget" "GI_Show_Gadget();" -2)
  2080.        (list "GI_Show_Gadget_Data" "GI_Show_Gadget_Data();" -2)
  2081.        (list "GI_Set_Gadget_Data" "GI_Set_Gadget_Data(, );" -4)
  2082.        (list "GI_Set_Gadget_Default_Color" "GI_Set_Gadget_Default_Color(, );" -4)
  2083.        (list "GI_Set_Gadget_Active_Color" "GI_Set_Gadget_Active_Color(, );" -4)
  2084.        (list "GI_Set_Gadget_Default_Text" "GI_Set_Gadget_Default_Text(, );" -4)
  2085.        (list "GI_Set_Gadget_Active_Text" "GI_Set_Gadget_Active_Text(, );" -4)
  2086.        (list "GI_Set_Gadget_Internal_Routine" "GI_Set_Gadget_Internal_Routine(, );" -4)
  2087.        (list "GI_Set_Gadget_Service_Routine" "GI_Set_Gadget_Service_Routine(, );" -4)
  2088.        (list "GI_Set_Button_Routine" "GI_Set_Button_Routine();" -2)
  2089.        (list "GI_Set_Idle_Routine" "GI_Set_Idle_Routine();" -2)
  2090.        (list "Go_Go_Gadget" "Go_Go_Gadget();" -2)
  2091.        (list "Go_Gadget" "Go_Gadget();" -2)
  2092.        (list "Go_Idle" "Go_Idle();" -2)
  2093.        (list "GU_strchr" "GU_strchr(, );" -4)
  2094.        (list "GU_strrchr" "GU_strrchr(, );" -4)
  2095.        (list "GU_Load_String" "GU_Load_String(, );" -4)
  2096.        (list "GU_Set_Color" "GU_Set_Color(, );" -4)
  2097.        (list "GU_Remap_Coordinates" "GU_Remap_Coordinates(, , , , , );" -12)
  2098.        (list "GU_Generate_Generic_Names" "GU_Generate_Generic_Names(, , );" -6)
  2099.        (list "GU_Find_Gadget_Set_Extent" "GU_Find_Gadget_Set_Extent(, , , , );" -10)
  2100.        (list "GU_HC_Outline_Rectangle" "GU_HC_Outline_Rectangle(, , , );" -8)
  2101.        (list "GU_Show_Limited_Selection_Loc" "GU_Show_Limited_Selection_Loc(, , );" -6)
  2102.        (list "GU_Show_Limited_Location" "GU_Show_Limited_Location(, , );" -6)
  2103.        (list "GU_Delete_Gadget" "GU_Delete_Gadget();" -2)
  2104.        (list "GU_Delete_Gadget_Now" "GU_Delete_Gadget_Now();" -2)
  2105.        (list "GU_Resize_Gadget" "GU_Resize_Gadget(, , , , );" -10)
  2106.        (list "GU_Bring_Gadget_To_Front" "GU_Bring_Gadget_To_Front();" -2)
  2107.        (list "GU_Update_Slider" "GU_Update_Slider(, );" -4)
  2108.        (list "GU_File_List" "GU_File_List(, );" -4)
  2109.        (list "GU_Fetch_Text" "GU_Fetch_Text(, , );" -6)))
  2110.  
  2111.  
  2112.