home *** CD-ROM | disk | FTP | other *** search
/ Frozen Fish 1: Amiga / FrozenFish-Apr94.iso / bbs / alib / d1xx / d131 / mg1b.lha / Mg1b / Source / readme.tgr < prev    next >
Text File  |  1988-03-14  |  12KB  |  322 lines

  1. First, a list of the modifications I had to make.  I added
  2. the ability to bind a keyboard macro to a key, which makes
  3. it semi-permenant (instead of the typically temporary
  4. keyboard macros.)  These macros can call other macros; this
  5. was essential for the next part.  I have introduced a
  6. `command language' with which you can instruct mg, either
  7. in a startup file (default is s:.mg), by using the
  8. eval-expression extended macro, or by REXX.  This command
  9. language is exactly what you would type to mg to get it
  10. to do what you have in mind, but in a format suitable for
  11. a text file.
  12.  
  13. Here it comes.  Control characters are represented by
  14. preceding them by a ^.  The escape key is represented by
  15. $.  Whitespace is ignored, except within strings.  A string
  16. can either be delimited by "", or ''.  The latter should
  17. only be used in anticipation of keyboard queries, as they
  18. get null terminated, which only makes sense to mg if it
  19. asked a question.  Function keys are represented by
  20. \f1 through \f20 or some such.  Backslash can escape any
  21. character, including itself.  In addition, keys can be
  22. specified literally by using \ddd, in octal.
  23.  
  24. For instance, to save the current buffer and then go back
  25. to the top of the file, you can type
  26.  
  27.     ^X^S $<
  28.  
  29. or (using the extended named commands)
  30.  
  31.     $x 'save-buffer' $x 'beginning-of-buffer'
  32.  
  33. which are idential (except the former takes a lot less macro
  34. space and executes more quickly.)  You can even define
  35. keyboard macros, ala
  36.  
  37.     ^X( ^X^S $< ^X)
  38.  
  39. which puts the above in the keyboard macro.  Then, you can
  40. bind this macro into another key (this must be a separate
  41. command):
  42.  
  43.     $x 'global-set-key-macro' \f1
  44.  
  45. to put it in f1, for instance.  You might want to do something
  46. like the following, for using TeX and REXX and mg all together:
  47.  
  48.     ^X( $x 'rexx' 'texify' ^X)
  49.     $x 'global-set-key-macro' \f2
  50.  
  51. mg opens a port by the name of 'mg'.  It uses REXX strictly
  52. as a server, so you shouldn't throw messages at it unless
  53. it asks you first.  This is essential!  In any case, there
  54. is a new extended command, rexx, which prompts for a command
  55. line and shoves the thing at REXX.  Now, the rexx program which
  56. is invoked (which has a default extension of .mg) can send
  57. whatever commands it wants at mg.  The keyboard is ignored
  58. during the rexx processing.  Eventually things should come
  59. back, though.
  60.  
  61. This is a list of extended commands supported by mg, and
  62. their normal keyboard equivalents.
  63.  
  64. #auto-fill-mode
  65.     Toggles word-wrap at fill-column, after space is typed.
  66. #!auto-indent-mode
  67.     Toggles indenting to first whitespace after a newline.
  68. #backward-char            [C-b]
  69.     Move point left ARG characters (right if ARG negative).
  70.     On reaching end of buffer, stop and signal error.
  71. #backward-delete-char        [DEL]
  72.     Delete characters backwards. Delete ARG chars, and save in
  73.     kill buffer if ARG was specified
  74. #backward-kill-word        [ESC DEL]
  75.     Kill characters backward until encountering the end of a word.
  76.     With argument, do this that many times.
  77. #backward-paragraph        [ESC [ ]
  78.     Move backward to start of paragraph.  With arg, do it arg times.
  79. #backward-word            [ESC b]
  80.     Move backward until encountering the end of a word.
  81.     With argument, do this that many times.
  82. #beginning-of-buffer        [ESC < ]
  83.     Move point to the beginning of the buffer; leave mark at
  84.     previous position.
  85. #beginning-of-line        [C-a]
  86.     Move point to beginning of current line.
  87. #bsmap-mode
  88.     Toggles a mode that maps ^H to del and del to ^H, where the
  89.     editor can't see it.
  90. #call-last-kbd-macro        [C-x e]
  91.     Call the last keyboard macro that you defined with C-x (.
  92. #capitalize-word        [ESC c]
  93.     Convert following word (or ARG words) to upper case, moving over.
  94. #copy-region-as-kill        [ESC w]
  95.     Save the region as if killed, but don't kill it.
  96. #ctrlx-four-hack
  97.     Exists to support the Ctl-x 4 <things> code.
  98. #delete-blank-lines        [C-x C-o]
  99.     On blank line, delete all surrounding blank lines, leaving just one.
  100. #delete-char            [C-d]
  101.     Delete the following ARG characters (previous, with negative arg).
  102.     If ARG is specified, appends deleted characters to the kill buffer.
  103. #delete-horizontal-space    [ESC \]
  104.     Delete all spaces and tabs around point.
  105. #delete-other-windows        [C-x 1]
  106.     Make current window fill the screen.
  107. #delete-window            [C-x 0]
  108.     Remove current window from the display.
  109. #describe-bindings        [C-h b]
  110.     Show a list of all defined keys, and their definitions.
  111.     The list is put in a buffer, which is displayed.
  112. #describe-key-briefly        [C-h c]
  113.     Print the name of the function KEY invokes.
  114. #downcase-region        [C-x C-l]
  115.     Convert the region to lower case.
  116. #downcase-word            [ESC l]
  117.     Convert following word (or ARG words) to lower case, moving over.
  118. #emacs-version
  119.     Print string describing the version of Emacs that is running.
  120. #end-kbd-macro            [C-x ) ]
  121.     Finish defining a keyboard macro.
  122.     The definition was started by C-x (.
  123.     The macro is now available for use via C-x e,
  124. #end-of-buffer            [ESC > ]
  125.     Move point to the end of the buffer; leave mark at previous position.
  126. #end-of-line            [C-e]
  127.     Move point to end of current line.
  128. #enlarge-window            [C-x ^]
  129.     Make current window ARG lines bigger.
  130. #eval-current-buffer
  131.     Execute the current buffer as an Emacs command file.
  132. #eval-expression
  133.     Get Emacs command and evaluate.
  134. #exchange-point-and-mark    [C-x C-x]
  135.     Put the mark where point is now, and point where the mark is now.
  136. #execute-extended-command
  137.     Read function name, then read its arguments and call it.
  138. #fill-paragraph            [ESC q]
  139.     Fill paragraph at or after point.
  140. #find-file            [C-x C-f]
  141.     Edit file FILENAME.
  142.     Switch to a buffer visiting file FILENAME,
  143.     creating one if none already exists.
  144. #find-file-other-window        [C-x 4 f] [C-x 4 C-f]
  145.     Edit file FILENAME, in another window.
  146.     May create a new window, or reuse an existing one;
  147. #flow-mode
  148.     Toggles a mode that maps ^\ to ^S and ^^ to ^Q and silently
  149.     eats ^S and ^Q at a level where the editor can't see it.
  150. #forward-char            [C-f]
  151.     Move point right ARG characters (left if ARG negative).
  152.     On reaching end of buffer, stop and signal error.
  153. #forward-paragraph        [ESC ] ]
  154.     Move forward to end of paragraph.  With arg, do it arg times.
  155. #forward-word            [ESC f]
  156.     Move point forward ARG words (backward if ARG is negative).
  157. #global-set-key
  158.     Give KEY a definition of COMMAND.
  159. #global-set-key-macro
  160.     Binds KEY to a copy of the current keyboard macro.
  161. #global-unset-key
  162.     Remove global definition of KEY.
  163. #goto-line
  164.     goto LINE in the current buffer.
  165. #help                [C-h]
  166.     Prompt user to find out what kind of help to supply
  167. #insert-file            [C-x i]
  168.     Insert contents of file FILENAME into buffer after point.
  169.     Set mark after the inserted text.
  170. #insert-newline        [RET]
  171.     Bound to newline so that it does the right things.  Usually
  172.     ignorable.
  173. #insert-with-wrap
  174.     Bound to space in auto-fill-mode. Check current column, and adds
  175.     a newline if past it.
  176. #isearch-backward        [C-r]
  177.     Do incremental search backward.
  178.     See isearch-forward for more information.
  179. #isearch-forward        [C-s]
  180.     Do incremental search forward.
  181.     As you type characters, they add to the search string and are found.
  182.     Type Delete to cancel characters from end of search string.
  183.     Type ESC to exit, leaving point at location found.
  184.     Type C-S to search again forward, C-R to search again backward.
  185.     Type C-Q to quote control character to search for it.
  186.     C-G while searching or when search has failed
  187.     cancels input back to what has been found successfully.
  188.     C-G when search is successful aborts and moves point to starting point.
  189.     Other control and meta characters terminate the search
  190.      and are then executed normally.
  191. #just-one-space            [ESC SPC]
  192. #keyboard-quit            [C-g]
  193.     Terminate the current function with an quit condition.
  194. #kill-buffer            [C-x k]
  195.     Get rid of the specified buffer.
  196. #kill-line            [C-k]
  197.     Kill the rest of the current line; before a newline, kill the newline.
  198.     With prefix argument, kill that many lines from point.
  199.     Negative arguments kill lines backward.
  200. #kill-paragraph
  201.     Kill current paragraph.
  202. #kill-region            [C-w]
  203.     Kill between point and mark.
  204.     The text is deleted but saved in the kill buffer.
  205.     The command C-y can retrieve it from there.
  206. #kill-word            [ESC d]
  207.     Kill characters forward until encountering the end of a word.
  208.     With argument, do this that many times.
  209. #list-buffers
  210.     Display a list of names of existing buffers.
  211.     Inserts it in buffer *Buffer List* and displays that.
  212. #load
  213.     Execute a file of Emacs commands.
  214. #newline-and-indent        [C-j]
  215.     Insert a newline, then indent.
  216. #next-line            [C-n]
  217.     Move cursor vertically down ARG lines.
  218. #next-window
  219.     Move to the next window down the screen.
  220. #no-tab-mode
  221.     Toggles a mode that treat tabs like most other control characters,
  222.     and rebinds tab to space-to-tabstop.
  223. #not-modified            [ESC ~]
  224.     Clear buffer modified flag.
  225. #open-line            [C-o]
  226.     Insert a newline and leave point before it.
  227.     With arg, inserts that many newlines.
  228. #post-line
  229.     Put the current line in the REXX cliplist under the variables
  230.     "mg.DotLine" and "mg.DotPos".
  231. #prefix-region
  232.     Prepend a string (set by set-prefix-string) to each line
  233.     in the curernt region.  If given an argument, prompts
  234.     you for the string to use.
  235. #previous-line            [C-p]
  236.     Move cursor vertically up ARG lines.
  237. #previous-window
  238.     Move to the next window up the screen.
  239. #query-replace            [ESC % ]
  240.     Replace some occurrences of FROM-STRING with TO-STRING.
  241.     As each match is found, the user must type a character saying
  242.     what to do with it.
  243.     Type Help char within query-replace for directions.
  244. #quoted-insert            [C-q]
  245.     Read next input character and insert it.
  246.     Useful for inserting control characters.
  247. #recenter            [C-l]
  248.     Center point in window and redisplay screen.  With ARG, put point
  249.     on line ARG.  The desired position of point is always relative
  250.     to the current window.  Also forces full screen refresh.
  251. #rexx
  252.     Sends a command to rexx.  Default extension is .mg.
  253. #save-buffer            [C-x C-s]
  254.     Save current buffer in visited file.
  255. #save-buffers-kill-emacs    [C-x C-c]
  256.     Offer to save each buffer, then kill this Emacs.
  257. #save-some-buffers        [C-x s]
  258.     Save some modified file-visiting buffers.  Asks user about each one.
  259.     With argument, saves all with no questions.
  260. #scroll-down            [ESC v]
  261.     Scroll text of current window downward ARG lines; or near full
  262.     screen if no ARG.
  263. #scroll-other-window        [ESC C-v]
  264.     Scroll text of next window upward ARG lines; or near full screen
  265.     if no ARG. The next window is the one below the current one; or
  266.     the one at the top if the current one is at the bottom.
  267. #scroll-up            [C-v]
  268.     Scroll text of current window upward ARG lines; or near full
  269.     screen if no ARG.
  270. #search-again
  271.     Handy to have around for function keys/menus, etc.
  272. #search-backward        [ESC r]
  273.     Search backward from point for STRING.
  274. #search-forward            [ESC s]
  275.     Search forward from point for STRING.
  276.     see search-backward
  277. #self-insert-command        [All printing characters and tab]
  278.     Insert this character.
  279. #set-fill-column        [C-x f]
  280.     Set fill-column to current column, or to argument if given.
  281. #set-mark-command        [C-@]
  282.     Set mark to where point is.
  283. #set-prefix-string
  284.     Set string used by prefix-region to put in front of each line text.
  285. #shrink-window
  286.     Make the current window ARG lines smaller.
  287. #space-to-tabstop
  288.     Insert spaces to the next tabstop.  With a positive argument,
  289. #split-window-vertically    [C-x 2]
  290.     Split current window into two windows, one above the other.
  291. #start-kbd-macro        [C-x ( ]
  292.     Record subsequent keyboard input, defining a keyboard macro.
  293.     The commands are recorded even as they are executed.
  294. #suspend-emacs            [C-z] [C-x C-z]
  295.     Get a shell.  Exactly what shell depends on the system you
  296.     are on.
  297. #switch-to-buffer        [C-x b]
  298.     Select the specified buffer in the current window.
  299. #switch-to-buffer-other-window    [C-x 4 b]
  300.     Switch to specified buffer in another window.
  301. #transpose-chars        [C-t]
  302.     Interchange characters around point, moving forward one character.
  303. #upcase-region            [C-x C-u]
  304.     Convert the region to upper case.
  305. #upcase-word            [ESC u]
  306.     Convert the following word (or ARG words) to upper case, moving over.
  307. #what-cursor-position        [C-x =]
  308.     Print info on cursor position.
  309. #window-to-front
  310.     Make the Emacs window come to the front
  311. #window-to-back
  312.     Push the Emacs window back
  313. #write-file            [C-x C-w]
  314.     Write current buffer into file FILENAME. Makes FILENAME the file for
  315.     the current buffer.
  316. #yank
  317.     Reinsert the last stretch of killed text.
  318.  
  319.  
  320.  
  321.  
  322.