home *** CD-ROM | disk | FTP | other *** search
/ BCI NET 2 / BCI NET 2.iso / archives / programming / source / a2.0bemacs-src.lha / Emacs-19.25 / lisp / macros.elc < prev    next >
Emacs Compiled Lisp  |  1994-05-04  |  5.4 KB

open in: MacOS 8.1     |     Win98     |     DOS

view JSON data     |     view as text


This file was processed as: Emacs Compiled Lisp (other/emacsCompiledLisp).
This format is not currently supported by dexvert.

ConfidenceProgramDetectionMatch TypeSupport
1% dexvert Emacs Compiled Lisp (other/emacsCompiledLisp) magic Unsupported
100% file Emacs/XEmacs v19 byte-compiled Lisp data default
99% file data default
55% TrID Emacs/XEmacs byte-compiled Lisp (generic) default
44% TrID Summation Document Image Information Load File default (weak)



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 3b 45 4c 43 13 00 00 00 | 0a 3b 3b 3b 20 63 6f 6d |;ELC....|.;;; com|
|00000010| 70 69 6c 65 64 20 62 79 | 20 6b 77 7a 68 40 68 61 |piled by| kwzh@ha|
|00000020| 6c 2e 67 6e 75 2e 61 69 | 2e 6d 69 74 2e 65 64 75 |l.gnu.ai|.mit.edu|
|00000030| 20 6f 6e 20 54 75 65 20 | 4d 61 79 20 20 33 20 32 | on Tue |May 3 2|
|00000040| 31 3a 35 31 3a 34 37 20 | 31 39 39 34 0a 3b 3b 3b |1:51:47 |1994.;;;|
|00000050| 20 66 72 6f 6d 20 66 69 | 6c 65 20 2f 67 64 2f 67 | from fi|le /gd/g|
|00000060| 6e 75 2f 65 6d 61 63 73 | 2f 31 39 2e 30 2f 6c 69 |nu/emacs|/19.0/li|
|00000070| 73 70 2f 6d 61 63 72 6f | 73 2e 65 6c 0a 3b 3b 3b |sp/macro|s.el.;;;|
|00000080| 20 65 6d 61 63 73 20 76 | 65 72 73 69 6f 6e 20 31 | emacs v|ersion 1|
|00000090| 39 2e 32 32 2e 39 32 2e | 32 2e 0a 3b 3b 3b 20 62 |9.22.92.|2..;;; b|
|000000a0| 79 74 65 63 6f 6d 70 20 | 76 65 72 73 69 6f 6e 20 |ytecomp |version |
|000000b0| 46 53 46 20 32 2e 31 30 | 0a 3b 3b 3b 20 6f 70 74 |FSF 2.10|.;;; opt|
|000000c0| 69 6d 69 7a 61 74 69 6f | 6e 20 69 73 20 6f 6e 2e |imizatio|n is on.|
|000000d0| 0a 3b 3b 3b 20 74 68 69 | 73 20 66 69 6c 65 20 75 |.;;; thi|s file u|
|000000e0| 73 65 73 20 6f 70 63 6f | 64 65 73 20 77 68 69 63 |ses opco|des whic|
|000000f0| 68 20 64 6f 20 6e 6f 74 | 20 65 78 69 73 74 20 69 |h do not| exist i|
|00000100| 6e 20 45 6d 61 63 73 20 | 31 38 2e 0a 0a 28 69 66 |n Emacs |18...(if|
|00000110| 20 28 61 6e 64 20 28 62 | 6f 75 6e 64 70 20 27 65 | (and (b|oundp 'e|
|00000120| 6d 61 63 73 2d 76 65 72 | 73 69 6f 6e 29 0a 09 20 |macs-ver|sion).. |
|00000130| 28 6f 72 20 28 61 6e 64 | 20 28 62 6f 75 6e 64 70 |(or (and| (boundp|
|00000140| 20 27 65 70 6f 63 68 3a | 3a 76 65 72 73 69 6f 6e | 'epoch:|:version|
|00000150| 29 20 65 70 6f 63 68 3a | 3a 76 65 72 73 69 6f 6e |) epoch:|:version|
|00000160| 29 0a 09 20 20 20 20 20 | 28 73 74 72 69 6e 67 2d |).. |(string-|
|00000170| 6c 65 73 73 70 20 65 6d | 61 63 73 2d 76 65 72 73 |lessp em|acs-vers|
|00000180| 69 6f 6e 20 22 31 39 22 | 29 29 29 0a 20 20 20 20 |ion "19"|))). |
|00000190| 28 65 72 72 6f 72 20 22 | 60 2f 67 64 2f 67 6e 75 |(error "|`/gd/gnu|
|000001a0| 2f 65 6d 61 63 73 2f 31 | 39 2e 30 2f 6c 69 73 70 |/emacs/1|9.0/lisp|
|000001b0| 2f 6d 61 63 72 6f 73 2e | 65 6c 27 20 77 61 73 20 |/macros.|el' was |
|000001c0| 63 6f 6d 70 69 6c 65 64 | 20 66 6f 72 20 45 6d 61 |compiled| for Ema|
|000001d0| 63 73 20 31 39 22 29 29 | 0a 0a 28 64 65 66 61 6c |cs 19"))|..(defal|
|000001e0| 69 61 73 20 27 6e 61 6d | 65 2d 6c 61 73 74 2d 6b |ias 'nam|e-last-k|
|000001f0| 62 64 2d 6d 61 63 72 6f | 20 23 5b 28 73 79 6d 62 |bd-macro| #[(symb|
|00000200| 6f 6c 29 20 22 08 84 08 | 00 c1 c2 21 88 c3 5c 66 |ol) "...|...!..\f|
|00000210| 21 83 20 00 5c 66 4b 3b | 84 20 00 c5 5c 66 4b 21 |!. .\fK;|. ..\fK!|
|00000220| 84 20 00 c1 c6 5c 66 5c | 22 88 5c 66 08 4d 87 22 |. ...\f\|".\f.M."|
|00000230| 20 5b 6c 61 73 74 2d 6b | 62 64 2d 6d 61 63 72 6f | [last-k|bd-macro|
|00000240| 20 65 72 72 6f 72 20 22 | 4e 6f 20 6b 65 79 62 6f | error "|No keybo|
|00000250| 61 72 64 20 6d 61 63 72 | 6f 20 64 65 66 69 6e 65 |ard macr|o define|
|00000260| 64 22 20 66 62 6f 75 6e | 64 70 20 73 79 6d 62 6f |d" fboun|dp symbo|
|00000270| 6c 20 76 65 63 74 6f 72 | 70 20 22 46 75 6e 63 74 |l vector|p "Funct|
|00000280| 69 6f 6e 20 25 73 20 69 | 73 20 61 6c 72 65 61 64 |ion %s i|s alread|
|00000290| 79 20 64 65 66 69 6e 65 | 64 20 61 6e 64 20 6e 6f |y define|d and no|
|000002a0| 74 20 61 20 6b 65 79 62 | 6f 61 72 64 20 6d 61 63 |t a keyb|oard mac|
|000002b0| 72 6f 2e 22 5d 20 33 20 | 22 5c 0a 41 73 73 69 67 |ro."] 3 |"\.Assig|
|000002c0| 6e 20 61 20 6e 61 6d 65 | 20 74 6f 20 74 68 65 20 |n a name| to the |
|000002d0| 6c 61 73 74 20 6b 65 79 | 62 6f 61 72 64 20 6d 61 |last key|board ma|
|000002e0| 63 72 6f 20 64 65 66 69 | 6e 65 64 2e 0a 41 72 67 |cro defi|ned..Arg|
|000002f0| 75 6d 65 6e 74 20 53 59 | 4d 42 4f 4c 20 69 73 20 |ument SY|MBOL is |
|00000300| 74 68 65 20 6e 61 6d 65 | 20 74 6f 20 64 65 66 69 |the name| to defi|
|00000310| 6e 65 2e 0a 54 68 65 20 | 73 79 6d 62 6f 6c 27 73 |ne..The |symbol's|
|00000320| 20 66 75 6e 63 74 69 6f | 6e 20 64 65 66 69 6e 69 | functio|n defini|
|00000330| 74 69 6f 6e 20 62 65 63 | 6f 6d 65 73 20 74 68 65 |tion bec|omes the|
|00000340| 20 6b 65 79 62 6f 61 72 | 64 20 6d 61 63 72 6f 20 | keyboar|d macro |
|00000350| 73 74 72 69 6e 67 2e 0a | 53 75 63 68 20 61 20 5c |string..|Such a \|
|00000360| 22 66 75 6e 63 74 69 6f | 6e 5c 22 20 63 61 6e 6e |"functio|n\" cann|
|00000370| 6f 74 20 62 65 20 63 61 | 6c 6c 65 64 20 66 72 6f |ot be ca|lled fro|
|00000380| 6d 20 4c 69 73 70 2c 20 | 62 75 74 20 69 74 20 69 |m Lisp, |but it i|
|00000390| 73 20 61 20 76 61 6c 69 | 64 20 65 64 69 74 6f 72 |s a vali|d editor|
|000003a0| 20 63 6f 6d 6d 61 6e 64 | 2e 22 20 22 53 4e 61 6d | command|." "SNam|
|000003b0| 65 20 66 6f 72 20 6c 61 | 73 74 20 6b 62 64 20 6d |e for la|st kbd m|
|000003c0| 61 63 72 6f 3a 20 22 5d | 29 0a 28 64 65 66 61 6c |acro: "]|).(defal|
|000003d0| 69 61 73 20 27 69 6e 73 | 65 72 74 2d 6b 62 64 2d |ias 'ins|ert-kbd-|
|000003e0| 6d 61 63 72 6f 20 23 5b | 28 6d 61 63 72 6f 6e 61 |macro #[|(macrona|
|000003f0| 6d 65 20 26 6f 70 74 69 | 6f 6e 61 6c 20 6b 65 79 |me &opti|onal key|
|00000400| 73 29 20 22 c0 19 c2 0b | 21 c4 98 83 14 00 c5 13 |s) "....|!.......|
|00000410| 0d 11 c6 63 88 82 1a 00 | 0b 4b 11 c7 63 88 c8 0b |...c....|.K..c...|
|00000420| 70 5c 22 88 c9 63 88 60 | c0 1e 5c 6e 1e 0b c8 09 |p\"..c.`|..\n....|
|00000430| 70 5c 22 88 cc 20 16 5c | 6e 0e 0b 62 88 60 0e 5c |p\".. .\|n..b.`.\|
|00000440| 6e 57 83 07 01 67 89 1e | 0d ce 55 83 50 00 60 60 |nW...g..|..U.P.``|
|00000450| 54 7c 88 cf 63 88 82 03 | 01 0e 0d d0 57 83 67 00 |T|..c...|....W.g.|
|00000460| 60 60 54 7c 88 d1 0e 0d | d2 5c 5c b1 02 88 82 03 |``T|....|.\\.....|
|00000470| 01 0e 0d d3 57 83 7e 00 | 60 60 54 7c 88 d1 0e 0d |....W.~.|``T|....|
|00000480| d4 5c 5c b1 02 88 82 03 | 01 0e 0d d5 57 83 8b 00 |.\\.....|....W...|
|00000490| d6 75 88 82 03 01 0e 0d | d5 55 83 9d 00 60 60 54 |.u......|.U...``T|
|000004a0| 7c 88 d7 63 88 82 03 01 | 0e 0d d8 55 83 af 00 60 ||..c....|...U...`|
|000004b0| 60 54 7c 88 d9 63 88 82 | 03 01 0e 0d da 57 83 c6 |`T|..c..|.....W..|
|000004c0| 00 60 60 54 7c 88 db 0e | 0d d3 5a b1 02 88 82 03 |.``T|...|..Z.....|
|000004d0| 01 0e 0d dc 57 83 dd 00 | 60 60 54 7c 88 db 0e 0d |....W...|``T|....|
|000004e0| d4 5a b1 02 88 82 03 01 | 0e 0d dd 57 83 f4 00 60 |.Z......|...W...`|
|000004f0| 60 54 7c 88 de 0e 0d d8 | 5a b1 02 88 82 03 01 0e |`T|.....|Z.......|
|00000500| 0d dd 55 83 03 01 60 60 | 54 7c 88 df 63 88 29 82 |..U...``|T|..c.).|
|00000510| 35 00 2a e0 63 88 0e 21 | 85 3a 01 e2 0b e3 5c 22 |5.*.c..!|.:....\"|
|00000520| 89 1e 21 85 39 01 e4 63 | 88 c8 0e 21 40 70 5c 22 |..!.9..c|...!@p\"|
|00000530| 88 e5 63 88 c8 0b 70 5c | 22 88 e0 63 88 0e 21 41 |..c...p\|"..c..!A|
|00000540| 89 16 21 84 1a 01 c0 29 | 29 87 22 20 5b 6e 69 6c |..!....)|)." [nil|
|00000550| 20 64 65 66 69 6e 69 74 | 69 6f 6e 20 73 79 6d 62 | definit|ion symb|
|00000560| 6f 6c 2d 6e 61 6d 65 20 | 6d 61 63 72 6f 6e 61 6d |ol-name |macronam|
|00000570| 65 20 22 22 20 6c 61 73 | 74 2d 6b 62 64 2d 6d 61 |e "" las|t-kbd-ma|
|00000580| 63 72 6f 20 22 28 73 65 | 74 71 20 22 20 22 28 66 |cro "(se|tq " "(f|
|00000590| 73 65 74 20 27 22 20 70 | 72 69 6e 31 20 22 5c 6e |set '" p|rin1 "\n|
|000005a0| 20 20 20 22 20 65 6e 64 | 20 62 65 67 20 70 6f 69 | " end| beg poi|
|000005b0| 6e 74 2d 6d 61 72 6b 65 | 72 20 63 68 61 72 20 30 |nt-marke|r char 0|
|000005c0| 20 22 5c 5c 43 2d 40 22 | 20 32 37 20 22 5c 5c 43 | "\\C-@"| 27 "\\C|
|000005d0| 2d 22 20 39 36 20 33 32 | 20 36 34 20 31 32 37 20 |-" 96 32| 64 127 |
|000005e0| 31 20 22 5c 5c 43 2d 3f | 22 20 31 32 38 20 22 5c |1 "\\C-?|" 128 "\|
|000005f0| 5c 4d 2d 5c 5c 43 2d 40 | 22 20 31 35 35 20 22 5c |\M-\\C-@|" 155 "\|
|00000600| 5c 4d 2d 5c 5c 43 2d 22 | 20 31 36 30 20 32 35 35 |\M-\\C-"| 160 255|
|00000610| 20 22 5c 5c 4d 2d 22 20 | 22 5c 5c 4d 2d 5c 5c 43 | "\\M-" |"\\M-\\C|
|00000620| 2d 3f 22 20 22 29 5c 6e | 22 20 6b 65 79 73 20 77 |-?" ")\n|" keys w|
|00000630| 68 65 72 65 2d 69 73 2d | 69 6e 74 65 72 6e 61 6c |here-is-|internal|
|00000640| 20 28 6b 65 79 6d 61 70 | 29 20 22 28 67 6c 6f 62 | (keymap|) "(glob|
|00000650| 61 6c 2d 73 65 74 2d 6b | 65 79 20 22 20 22 20 27 |al-set-k|ey " " '|
|00000660| 22 5d 20 34 20 22 5c 0a | 49 6e 73 65 72 74 20 69 |"] 4 "\.|Insert i|
|00000670| 6e 20 62 75 66 66 65 72 | 20 74 68 65 20 64 65 66 |n buffer| the def|
|00000680| 69 6e 69 74 69 6f 6e 20 | 6f 66 20 6b 62 64 20 6d |inition |of kbd m|
|00000690| 61 63 72 6f 20 4e 41 4d | 45 2c 20 61 73 20 4c 69 |acro NAM|E, as Li|
|000006a0| 73 70 20 63 6f 64 65 2e | 0a 4f 70 74 69 6f 6e 61 |sp code.|.Optiona|
|000006b0| 6c 20 73 65 63 6f 6e 64 | 20 61 72 67 20 4b 45 59 |l second| arg KEY|
|000006c0| 53 20 6d 65 61 6e 73 20 | 61 6c 73 6f 20 72 65 63 |S means |also rec|
|000006d0| 6f 72 64 20 74 68 65 20 | 6b 65 79 73 20 69 74 20 |ord the |keys it |
|000006e0| 69 73 20 6f 6e 0a 28 74 | 68 69 73 20 69 73 20 74 |is on.(t|his is t|
|000006f0| 68 65 20 70 72 65 66 69 | 78 20 61 72 67 75 6d 65 |he prefi|x argume|
|00000700| 6e 74 2c 20 77 68 65 6e | 20 63 61 6c 6c 69 6e 67 |nt, when| calling|
|00000710| 20 69 6e 74 65 72 61 63 | 74 69 76 65 6c 79 29 2e | interac|tively).|
|00000720| 0a 0a 54 68 69 73 20 4c | 69 73 70 20 63 6f 64 65 |..This L|isp code|
|00000730| 20 77 69 6c 6c 2c 20 77 | 68 65 6e 20 65 78 65 63 | will, w|hen exec|
|00000740| 75 74 65 64 2c 20 64 65 | 66 69 6e 65 20 74 68 65 |uted, de|fine the|
|00000750| 20 6b 62 64 20 6d 61 63 | 72 6f 20 77 69 74 68 20 | kbd mac|ro with |
|00000760| 74 68 65 20 73 61 6d 65 | 0a 64 65 66 69 6e 69 74 |the same|.definit|
|00000770| 69 6f 6e 20 69 74 20 68 | 61 73 20 6e 6f 77 2e 20 |ion it h|as now. |
|00000780| 20 49 66 20 79 6f 75 20 | 73 61 79 20 74 6f 20 72 | If you |say to r|
|00000790| 65 63 6f 72 64 20 74 68 | 65 20 6b 65 79 73 2c 20 |ecord th|e keys, |
|000007a0| 74 68 65 20 4c 69 73 70 | 20 63 6f 64 65 0a 77 69 |the Lisp| code.wi|
|000007b0| 6c 6c 20 61 6c 73 6f 20 | 72 65 62 69 6e 64 20 74 |ll also |rebind t|
|000007c0| 68 6f 73 65 20 6b 65 79 | 73 20 74 6f 20 74 68 65 |hose key|s to the|
|000007d0| 20 6d 61 63 72 6f 2e 20 | 20 4f 6e 6c 79 20 67 6c | macro. | Only gl|
|000007e0| 6f 62 61 6c 20 6b 65 79 | 20 62 69 6e 64 69 6e 67 |obal key| binding|
|000007f0| 73 0a 61 72 65 20 72 65 | 63 6f 72 64 65 64 20 73 |s.are re|corded s|
|00000800| 69 6e 63 65 20 65 78 65 | 63 75 74 69 6e 67 20 74 |ince exe|cuting t|
|00000810| 68 69 73 20 4c 69 73 70 | 20 63 6f 64 65 20 61 6c |his Lisp| code al|
|00000820| 77 61 79 73 20 6d 61 6b | 65 73 20 67 6c 6f 62 61 |ways mak|es globa|
|00000830| 6c 0a 62 69 6e 64 69 6e | 67 73 2e 0a 0a 54 6f 20 |l.bindin|gs...To |
|00000840| 73 61 76 65 20 61 20 6b | 62 64 20 6d 61 63 72 6f |save a k|bd macro|
|00000850| 2c 20 76 69 73 69 74 20 | 61 20 66 69 6c 65 20 6f |, visit |a file o|
|00000860| 66 20 4c 69 73 70 20 63 | 6f 64 65 20 73 75 63 68 |f Lisp c|ode such|
|00000870| 20 61 73 20 79 6f 75 72 | 20 60 7e 2f 2e 65 6d 61 | as your| `~/.ema|
|00000880| 63 73 27 2c 0a 75 73 65 | 20 74 68 69 73 20 63 6f |cs',.use| this co|
|00000890| 6d 6d 61 6e 64 2c 20 61 | 6e 64 20 74 68 65 6e 20 |mmand, a|nd then |
|000008a0| 73 61 76 65 20 74 68 65 | 20 66 69 6c 65 2e 22 20 |save the| file." |
|000008b0| 22 43 49 6e 73 65 72 74 | 20 6b 62 64 20 6d 61 63 |"CInsert| kbd mac|
|000008c0| 72 6f 20 28 6e 61 6d 65 | 29 3a 20 5c 6e 50 22 5d |ro (name|): \nP"]|
|000008d0| 29 0a 28 64 65 66 61 6c | 69 61 73 20 27 6b 62 64 |).(defal|ias 'kbd|
|000008e0| 2d 6d 61 63 72 6f 2d 71 | 75 65 72 79 20 23 5b 28 |-macro-q|uery #[(|
|000008f0| 66 6c 61 67 29 20 22 08 | 84 5c 66 00 09 84 5c 66 |flag) ".|.\f...\f|
|00000900| 00 c2 c3 21 88 5c 66 83 | 18 00 c5 89 19 18 c6 20 |...!.\f.|....... |
|00000910| 2a 87 08 3f 3f 85 b9 00 | c7 c8 c9 21 1e 5c 6e 1e |*..??...|...!.\n.|
|00000920| 0b 0e 0b 85 b8 00 c5 89 | 19 18 cc 0e 5c 6e 21 88 |........|....\n!.|
|00000930| cd 20 2a c5 1e 0e 1e 0f | d0 0e 0f 21 16 0f d1 0e |. *.....|...!....|
|00000940| 12 0e 0f 5c 22 89 16 0e | d3 3d 83 56 00 c5 16 0b |...\"...|.=.V....|
|00000950| 82 b4 00 0e 0e d4 3d 83 | 65 00 c5 16 0b d5 10 82 |......=.|e.......|
|00000960| b4 00 0e 0e d6 3d 83 74 | 00 c5 16 0b c7 10 82 b4 |.....=.t|........|
|00000970| 00 0e 0e d7 3d 83 82 00 | d7 c5 21 88 82 b4 00 0e |....=...|..!.....|
|00000980| 0e d8 3d 83 94 00 c5 89 | 19 18 c6 20 88 2a 82 b4 |..=.....|... .*..|
|00000990| 00 0e 0e d9 3d 83 a1 00 | c7 16 1a 82 b4 00 0e 0e |....=...|........|
|000009a0| db 3d 84 ab 00 dc 20 88 | dd 90 de c8 df 21 21 91 |.=.... .|.....!!.|
|000009b0| 88 2a 82 26 00 2a 87 22 | 20 5b 65 78 65 63 75 74 |.*.&.*."| [execut|
|000009c0| 69 6e 67 2d 6d 61 63 72 | 6f 20 64 65 66 69 6e 69 |ing-macr|o defini|
|000009d0| 6e 67 2d 6b 62 64 2d 6d | 61 63 72 6f 20 65 72 72 |ng-kbd-m|acro err|
|000009e0| 6f 72 20 22 4e 6f 74 20 | 64 65 66 69 6e 69 6e 67 |or "Not |defining|
|000009f0| 20 6f 72 20 65 78 65 63 | 75 74 69 6e 67 20 6b 62 | or exec|uting kb|
|00000a00| 64 20 6d 61 63 72 6f 22 | 20 66 6c 61 67 20 6e 69 |d macro"| flag ni|
|00000a10| 6c 20 72 65 63 75 72 73 | 69 76 65 2d 65 64 69 74 |l recurs|ive-edit|
|00000a20| 20 74 20 73 75 62 73 74 | 69 74 75 74 65 2d 63 6f | t subst|itute-co|
|00000a30| 6d 6d 61 6e 64 2d 6b 65 | 79 73 20 22 50 72 6f 63 |mmand-ke|ys "Proc|
|00000a40| 65 65 64 20 77 69 74 68 | 20 6d 61 63 72 6f 3f 5c |eed with| macro?\|
|00000a50| 5c 3c 71 75 65 72 79 2d | 72 65 70 6c 61 63 65 2d |\<query-|replace-|
|00000a60| 6d 61 70 3e 20 28 5c 5c | 5b 61 63 74 5d 2c 20 5c |map> (\\|[act], \|
|00000a70| 5c 5b 73 6b 69 70 5d 2c | 20 5c 5c 5b 65 78 69 74 |\[skip],| \\[exit|
|00000a80| 5d 2c 20 5c 5c 5b 72 65 | 63 65 6e 74 65 72 5d 2c |], \\[re|center],|
|00000a90| 20 5c 5c 5b 65 64 69 74 | 5d 29 20 22 20 6d 73 67 | \\[edit|]) " msg|
|00000aa0| 20 6c 6f 6f 70 20 6d 65 | 73 73 61 67 65 20 72 65 | loop me|ssage re|
|00000ab0| 61 64 2d 65 76 65 6e 74 | 20 64 65 66 20 6b 65 79 |ad-event| def key|
|00000ac0| 20 76 65 63 74 6f 72 20 | 6c 6f 6f 6b 75 70 2d 6b | vector |lookup-k|
|00000ad0| 65 79 20 71 75 65 72 79 | 2d 72 65 70 6c 61 63 65 |ey query|-replace|
|00000ae0| 2d 6d 61 70 20 61 63 74 | 20 73 6b 69 70 20 22 22 |-map act| skip ""|
|00000af0| 20 65 78 69 74 20 72 65 | 63 65 6e 74 65 72 20 65 | exit re|center e|
|00000b00| 64 69 74 20 71 75 69 74 | 20 71 75 69 74 2d 66 6c |dit quit| quit-fl|
|00000b10| 61 67 20 68 65 6c 70 20 | 64 69 6e 67 20 22 2a 48 |ag help |ding "*H|
|00000b20| 65 6c 70 2a 22 20 70 72 | 69 6e 63 20 22 53 70 65 |elp*" pr|inc "Spe|
|00000b30| 63 69 66 79 20 68 6f 77 | 20 74 6f 20 70 72 6f 63 |cify how| to proc|
|00000b40| 65 65 64 20 77 69 74 68 | 20 6b 65 79 62 6f 61 72 |eed with| keyboar|
|00000b50| 64 20 6d 61 63 72 6f 20 | 65 78 65 63 75 74 69 6f |d macro |executio|
|00000b60| 6e 2e 5c 6e 50 6f 73 73 | 69 62 69 6c 69 74 69 65 |n.\nPoss|ibilitie|
|00000b70| 73 3a 20 5c 5c 3c 71 75 | 65 72 79 2d 72 65 70 6c |s: \\<qu|ery-repl|
|00000b80| 61 63 65 2d 6d 61 70 3e | 5c 6e 5c 5c 5b 61 63 74 |ace-map>|\n\\[act|
|00000b90| 5d 09 46 69 6e 69 73 68 | 20 74 68 69 73 20 69 74 |].Finish| this it|
|00000ba0| 65 72 61 74 69 6f 6e 20 | 6e 6f 72 6d 61 6c 6c 79 |eration |normally|
|00000bb0| 20 61 6e 64 20 63 6f 6e | 74 69 6e 75 65 20 77 69 | and con|tinue wi|
|00000bc0| 74 68 20 74 68 65 20 6e | 65 78 74 2e 5c 6e 5c 5c |th the n|ext.\n\\|
|00000bd0| 5b 73 6b 69 70 5d 09 53 | 6b 69 70 20 74 68 65 20 |[skip].S|kip the |
|00000be0| 72 65 73 74 20 6f 66 20 | 74 68 69 73 20 69 74 65 |rest of |this ite|
|00000bf0| 72 61 74 69 6f 6e 2c 20 | 61 6e 64 20 73 74 61 72 |ration, |and star|
|00000c00| 74 20 74 68 65 20 6e 65 | 78 74 2e 5c 6e 5c 5c 5b |t the ne|xt.\n\\[|
|00000c10| 65 78 69 74 5d 09 53 74 | 6f 70 20 74 68 65 20 6d |exit].St|op the m|
|00000c20| 61 63 72 6f 20 65 6e 74 | 69 72 65 6c 79 20 72 69 |acro ent|irely ri|
|00000c30| 67 68 74 20 6e 6f 77 2e | 5c 6e 5c 5c 5b 72 65 63 |ght now.|\n\\[rec|
|00000c40| 65 6e 74 65 72 5d 09 52 | 65 64 69 73 70 6c 61 79 |enter].R|edisplay|
|00000c50| 20 74 68 65 20 73 63 72 | 65 65 6e 2c 20 74 68 65 | the scr|een, the|
|00000c60| 6e 20 61 73 6b 20 61 67 | 61 69 6e 2e 5c 6e 5c 5c |n ask ag|ain.\n\\|
|00000c70| 5b 65 64 69 74 5d 09 45 | 6e 74 65 72 20 72 65 63 |[edit].E|nter rec|
|00000c80| 75 72 73 69 76 65 20 65 | 64 69 74 3b 20 61 73 6b |ursive e|dit; ask|
|00000c90| 20 61 67 61 69 6e 20 77 | 68 65 6e 20 79 6f 75 20 | again w|hen you |
|00000ca0| 65 78 69 74 20 66 72 6f | 6d 20 74 68 61 74 2e 22 |exit fro|m that."|
|00000cb0| 5d 20 35 20 22 5c 0a 51 | 75 65 72 79 20 75 73 65 |] 5 "\.Q|uery use|
|00000cc0| 72 20 64 75 72 69 6e 67 | 20 6b 62 64 20 6d 61 63 |r during| kbd mac|
|00000cd0| 72 6f 20 65 78 65 63 75 | 74 69 6f 6e 2e 0a 20 20 |ro execu|tion.. |
|00000ce0| 57 69 74 68 20 70 72 65 | 66 69 78 20 61 72 67 75 |With pre|fix argu|
|00000cf0| 6d 65 6e 74 2c 20 65 6e | 74 65 72 73 20 72 65 63 |ment, en|ters rec|
|00000d00| 75 72 73 69 76 65 20 65 | 64 69 74 2c 20 72 65 61 |ursive e|dit, rea|
|00000d10| 64 69 6e 67 20 6b 65 79 | 62 6f 61 72 64 0a 63 6f |ding key|board.co|
|00000d20| 6d 6d 61 6e 64 73 20 65 | 76 65 6e 20 77 69 74 68 |mmands e|ven with|
|00000d30| 69 6e 20 61 20 6b 62 64 | 20 6d 61 63 72 6f 2e 20 |in a kbd| macro. |
|00000d40| 20 59 6f 75 20 63 61 6e | 20 67 69 76 65 20 64 69 | You can| give di|
|00000d50| 66 66 65 72 65 6e 74 20 | 63 6f 6d 6d 61 6e 64 73 |fferent |commands|
|00000d60| 0a 65 61 63 68 20 74 69 | 6d 65 20 74 68 65 20 6d |.each ti|me the m|
|00000d70| 61 63 72 6f 20 65 78 65 | 63 75 74 65 73 2e 0a 20 |acro exe|cutes.. |
|00000d80| 20 57 69 74 68 6f 75 74 | 20 70 72 65 66 69 78 20 | Without| prefix |
|00000d90| 61 72 67 75 6d 65 6e 74 | 2c 20 61 73 6b 73 20 77 |argument|, asks w|
|00000da0| 68 65 74 68 65 72 20 74 | 6f 20 63 6f 6e 74 69 6e |hether t|o contin|
|00000db0| 75 65 20 72 75 6e 6e 69 | 6e 67 20 74 68 65 20 6d |ue runni|ng the m|
|00000dc0| 61 63 72 6f 2e 0a 59 6f | 75 72 20 6f 70 74 69 6f |acro..Yo|ur optio|
|00000dd0| 6e 73 20 61 72 65 3a 20 | 5c 5c 3c 71 75 65 72 79 |ns are: |\\<query|
|00000de0| 2d 72 65 70 6c 61 63 65 | 2d 6d 61 70 3e 0a 5c 5c |-replace|-map>.\\|
|00000df0| 5b 61 63 74 5d 09 46 69 | 6e 69 73 68 20 74 68 69 |[act].Fi|nish thi|
|00000e00| 73 20 69 74 65 72 61 74 | 69 6f 6e 20 6e 6f 72 6d |s iterat|ion norm|
|00000e10| 61 6c 6c 79 20 61 6e 64 | 20 63 6f 6e 74 69 6e 75 |ally and| continu|
|00000e20| 65 20 77 69 74 68 20 74 | 68 65 20 6e 65 78 74 2e |e with t|he next.|
|00000e30| 0a 5c 5c 5b 73 6b 69 70 | 5d 09 53 6b 69 70 20 74 |.\\[skip|].Skip t|
|00000e40| 68 65 20 72 65 73 74 20 | 6f 66 20 74 68 69 73 20 |he rest |of this |
|00000e50| 69 74 65 72 61 74 69 6f | 6e 2c 20 61 6e 64 20 73 |iteratio|n, and s|
|00000e60| 74 61 72 74 20 74 68 65 | 20 6e 65 78 74 2e 0a 5c |tart the| next..\|
|00000e70| 5c 5b 65 78 69 74 5d 09 | 53 74 6f 70 20 74 68 65 |\[exit].|Stop the|
|00000e80| 20 6d 61 63 72 6f 20 65 | 6e 74 69 72 65 6c 79 20 | macro e|ntirely |
|00000e90| 72 69 67 68 74 20 6e 6f | 77 2e 0a 5c 5c 5b 72 65 |right no|w..\\[re|
|00000ea0| 63 65 6e 74 65 72 5d 09 | 52 65 64 69 73 70 6c 61 |center].|Redispla|
|00000eb0| 79 20 74 68 65 20 73 63 | 72 65 65 6e 2c 20 74 68 |y the sc|reen, th|
|00000ec0| 65 6e 20 61 73 6b 20 61 | 67 61 69 6e 2e 0a 5c 5c |en ask a|gain..\\|
|00000ed0| 5b 65 64 69 74 5d 09 45 | 6e 74 65 72 20 72 65 63 |[edit].E|nter rec|
|00000ee0| 75 72 73 69 76 65 20 65 | 64 69 74 3b 20 61 73 6b |ursive e|dit; ask|
|00000ef0| 20 61 67 61 69 6e 20 77 | 68 65 6e 20 79 6f 75 20 | again w|hen you |
|00000f00| 65 78 69 74 20 66 72 6f | 6d 20 74 68 61 74 2e 22 |exit fro|m that."|
|00000f10| 20 22 50 22 5d 29 0a 28 | 64 65 66 61 6c 69 61 73 | "P"]).(|defalias|
|00000f20| 20 27 61 70 70 6c 79 2d | 6d 61 63 72 6f 2d 74 6f | 'apply-|macro-to|
|00000f30| 2d 72 65 67 69 6f 6e 2d | 6c 69 6e 65 73 20 23 5b |-region-|lines #[|
|00000f40| 28 74 6f 70 20 62 6f 74 | 74 6f 6d 20 26 6f 70 74 |(top bot|tom &opt|
|00000f50| 69 6f 6e 61 6c 20 6d 61 | 63 72 6f 29 20 22 08 84 |ional ma|cro) "..|
|00000f60| 0e 00 09 84 5c 66 00 c2 | c3 21 88 09 10 8a 5c 66 |....\f..|.!....\f|
|00000f70| 62 88 c5 79 88 c6 20 c7 | 1e 08 1e 09 0e 5c 6e 62 |b..y.. .|.....\nb|
|00000f80| 88 6e 84 27 00 cb 79 88 | c6 20 16 08 0e 08 0e 09 |.n.'..y.|. ......|
|00000f90| 57 83 4f 00 0e 08 62 88 | 8a cb 79 88 0e 08 60 c7 |W.O...b.|..y...`.|
|00000fa0| 93 88 29 8a cc 08 86 49 | 00 09 21 88 29 82 2b 00 |..)....I|..!.).+.|
|00000fb0| 0e 09 c7 89 93 88 0e 08 | c7 89 93 2b 87 22 20 5b |........|...+." [|
|00000fc0| 6d 61 63 72 6f 20 6c 61 | 73 74 2d 6b 62 64 2d 6d |macro la|st-kbd-m|
|00000fd0| 61 63 72 6f 20 65 72 72 | 6f 72 20 22 4e 6f 20 6b |acro err|or "No k|
|00000fe0| 65 79 62 6f 61 72 64 20 | 6d 61 63 72 6f 20 68 61 |eyboard |macro ha|
|00000ff0| 73 20 62 65 65 6e 20 64 | 65 66 69 6e 65 64 2e 22 |s been d|efined."|
|00001000| 20 62 6f 74 74 6f 6d 20 | 30 20 70 6f 69 6e 74 2d | bottom |0 point-|
|00001010| 6d 61 72 6b 65 72 20 6e | 69 6c 20 6e 65 78 74 2d |marker n|il next-|
|00001020| 6c 69 6e 65 2d 6d 61 72 | 6b 65 72 20 65 6e 64 2d |line-mar|ker end-|
|00001030| 6d 61 72 6b 65 72 20 74 | 6f 70 20 31 20 65 78 65 |marker t|op 1 exe|
|00001040| 63 75 74 65 2d 6b 62 64 | 2d 6d 61 63 72 6f 5d 20 |cute-kbd|-macro] |
|00001050| 33 20 22 5c 0a 46 6f 72 | 20 65 61 63 68 20 63 6f |3 "\.For| each co|
|00001060| 6d 70 6c 65 74 65 20 6c | 69 6e 65 20 62 65 74 77 |mplete l|ine betw|
|00001070| 65 65 6e 20 70 6f 69 6e | 74 20 61 6e 64 20 6d 61 |een poin|t and ma|
|00001080| 72 6b 2c 20 6d 6f 76 65 | 20 74 6f 20 74 68 65 20 |rk, move| to the |
|00001090| 62 65 67 69 6e 6e 69 6e | 67 0a 6f 66 20 74 68 65 |beginnin|g.of the|
|000010a0| 20 6c 69 6e 65 2c 20 61 | 6e 64 20 72 75 6e 20 74 | line, a|nd run t|
|000010b0| 68 65 20 6c 61 73 74 20 | 6b 65 79 62 6f 61 72 64 |he last |keyboard|
|000010c0| 20 6d 61 63 72 6f 2e 0a | 0a 57 68 65 6e 20 63 61 | macro..|.When ca|
|000010d0| 6c 6c 65 64 20 66 72 6f | 6d 20 6c 69 73 70 2c 20 |lled fro|m lisp, |
|000010e0| 74 68 69 73 20 66 75 6e | 63 74 69 6f 6e 20 74 61 |this fun|ction ta|
|000010f0| 6b 65 73 20 74 77 6f 20 | 61 72 67 75 6d 65 6e 74 |kes two |argument|
|00001100| 73 20 54 4f 50 20 61 6e | 64 0a 42 4f 54 54 4f 4d |s TOP an|d.BOTTOM|
|00001110| 2c 20 64 65 73 63 72 69 | 62 69 6e 67 20 74 68 65 |, descri|bing the|
|00001120| 20 63 75 72 72 65 6e 74 | 20 72 65 67 69 6f 6e 2e | current| region.|
|00001130| 20 20 54 4f 50 20 6d 75 | 73 74 20 62 65 20 62 65 | TOP mu|st be be|
|00001140| 66 6f 72 65 20 42 4f 54 | 54 4f 4d 2e 0a 54 68 65 |fore BOT|TOM..The|
|00001150| 20 6f 70 74 69 6f 6e 61 | 6c 20 74 68 69 72 64 20 | optiona|l third |
|00001160| 61 72 67 75 6d 65 6e 74 | 20 4d 41 43 52 4f 20 73 |argument| MACRO s|
|00001170| 70 65 63 69 66 69 65 73 | 20 61 20 6b 65 79 62 6f |pecifies| a keybo|
|00001180| 61 72 64 20 6d 61 63 72 | 6f 20 74 6f 0a 65 78 65 |ard macr|o to.exe|
|00001190| 63 75 74 65 2e 0a 0a 54 | 68 69 73 20 69 73 20 75 |cute...T|his is u|
|000011a0| 73 65 66 75 6c 20 66 6f | 72 20 71 75 6f 74 69 6e |seful fo|r quotin|
|000011b0| 67 20 6f 72 20 75 6e 71 | 75 6f 74 69 6e 67 20 69 |g or unq|uoting i|
|000011c0| 6e 63 6c 75 64 65 64 20 | 74 65 78 74 2c 20 61 64 |ncluded |text, ad|
|000011d0| 64 69 6e 67 20 61 6e 64 | 0a 72 65 6d 6f 76 69 6e |ding and|.removin|
|000011e0| 67 20 63 6f 6d 6d 65 6e | 74 73 2c 20 6f 72 20 70 |g commen|ts, or p|
|000011f0| 72 6f 64 75 63 69 6e 67 | 20 74 61 62 6c 65 73 20 |roducing| tables |
|00001200| 77 68 65 72 65 20 74 68 | 65 20 65 6e 74 72 69 65 |where th|e entrie|
|00001210| 73 20 61 72 65 20 72 65 | 67 75 6c 61 72 2e 0a 0a |s are re|gular...|
|00001220| 46 6f 72 20 65 78 61 6d | 70 6c 65 2c 20 69 6e 20 |For exam|ple, in |
|00001230| 55 73 65 6e 65 74 20 61 | 72 74 69 63 6c 65 73 2c |Usenet a|rticles,|
|00001240| 20 73 65 63 74 69 6f 6e | 73 20 6f 66 20 74 65 78 | section|s of tex|
|00001250| 74 20 71 75 6f 74 65 64 | 20 66 72 6f 6d 20 61 6e |t quoted| from an|
|00001260| 6f 74 68 65 72 0a 61 75 | 74 68 6f 72 20 61 72 65 |other.au|thor are|
|00001270| 20 69 6e 64 65 6e 74 65 | 64 2c 20 6f 72 20 68 61 | indente|d, or ha|
|00001280| 76 65 20 65 61 63 68 20 | 6c 69 6e 65 20 73 74 61 |ve each |line sta|
|00001290| 72 74 20 77 69 74 68 20 | 60 3e 27 2e 20 20 54 6f |rt with |`>'. To|
|000012a0| 20 71 75 6f 74 65 20 61 | 0a 73 65 63 74 69 6f 6e | quote a|.section|
|000012b0| 20 6f 66 20 74 65 78 74 | 2c 20 64 65 66 69 6e 65 | of text|, define|
|000012c0| 20 61 20 6b 65 79 62 6f | 61 72 64 20 6d 61 63 72 | a keybo|ard macr|
|000012d0| 6f 20 77 68 69 63 68 20 | 69 6e 73 65 72 74 73 20 |o which |inserts |
|000012e0| 60 3e 27 2c 20 70 75 74 | 20 70 6f 69 6e 74 0a 61 |`>', put| point.a|
|000012f0| 6e 64 20 6d 61 72 6b 20 | 61 74 20 6f 70 70 6f 73 |nd mark |at oppos|
|00001300| 69 74 65 20 65 6e 64 73 | 20 6f 66 20 74 68 65 20 |ite ends| of the |
|00001310| 71 75 6f 74 65 64 20 73 | 65 63 74 69 6f 6e 2c 20 |quoted s|ection, |
|00001320| 61 6e 64 20 75 73 65 0a | 60 5c 5c 5b 61 70 70 6c |and use.|`\\[appl|
|00001330| 79 2d 6d 61 63 72 6f 2d | 74 6f 2d 72 65 67 69 6f |y-macro-|to-regio|
|00001340| 6e 2d 6c 69 6e 65 73 5d | 27 20 74 6f 20 6d 61 72 |n-lines]|' to mar|
|00001350| 6b 20 74 68 65 20 65 6e | 74 69 72 65 20 73 65 63 |k the en|tire sec|
|00001360| 74 69 6f 6e 2e 0a 0a 53 | 75 70 70 6f 73 65 20 79 |tion...S|uppose y|
|00001370| 6f 75 20 77 61 6e 74 65 | 64 20 74 6f 20 62 75 69 |ou wante|d to bui|
|00001380| 6c 64 20 61 20 6b 65 79 | 77 6f 72 64 20 74 61 62 |ld a key|word tab|
|00001390| 6c 65 20 69 6e 20 43 20 | 77 68 65 72 65 20 65 61 |le in C |where ea|
|000013a0| 63 68 20 65 6e 74 72 79 | 0a 6c 6f 6f 6b 65 64 20 |ch entry|.looked |
|000013b0| 6c 69 6b 65 20 74 68 69 | 73 3a 0a 0a 20 20 20 20 |like thi|s:.. |
|000013c0| 7b 20 5c 22 66 6f 6f 5c | 22 2c 20 66 6f 6f 5f 64 |{ \"foo\|", foo_d|
|000013d0| 61 74 61 2c 20 66 6f 6f | 5f 66 75 6e 63 74 69 6f |ata, foo|_functio|
|000013e0| 6e 20 7d 2c 20 0a 20 20 | 20 20 7b 20 5c 22 62 61 |n }, . | { \"ba|
|000013f0| 72 5c 22 2c 20 62 61 72 | 5f 64 61 74 61 2c 20 62 |r\", bar|_data, b|
|00001400| 61 72 5f 66 75 6e 63 74 | 69 6f 6e 20 7d 2c 0a 20 |ar_funct|ion },. |
|00001410| 20 20 20 7b 20 5c 22 62 | 61 7a 5c 22 2c 20 62 61 | { \"b|az\", ba|
|00001420| 7a 5f 64 61 74 61 2c 20 | 62 61 7a 5f 66 75 6e 63 |z_data, |baz_func|
|00001430| 74 69 6f 6e 20 7d 2c 0a | 0a 59 6f 75 20 63 6f 75 |tion },.|.You cou|
|00001440| 6c 64 20 65 6e 74 65 72 | 20 74 68 65 20 6e 61 6d |ld enter| the nam|
|00001450| 65 73 20 69 6e 20 74 68 | 69 73 20 66 6f 72 6d 61 |es in th|is forma|
|00001460| 74 3a 0a 0a 20 20 20 20 | 66 6f 6f 0a 20 20 20 20 |t:.. |foo. |
|00001470| 62 61 72 0a 20 20 20 20 | 62 61 7a 0a 0a 61 6e 64 |bar. |baz..and|
|00001480| 20 77 72 69 74 65 20 61 | 20 6d 61 63 72 6f 20 74 | write a| macro t|
|00001490| 6f 20 6d 61 73 73 61 67 | 65 20 61 20 77 6f 72 64 |o massag|e a word|
|000014a0| 20 69 6e 74 6f 20 61 20 | 74 61 62 6c 65 20 65 6e | into a |table en|
|000014b0| 74 72 79 3a 0a 0a 20 20 | 20 20 5c 5c 43 2d 78 20 |try:.. | \\C-x |
|000014c0| 28 0a 20 20 20 20 20 20 | 20 5c 5c 4d 2d 64 20 7b |(. | \\M-d {|
|000014d0| 20 5c 22 5c 5c 43 2d 79 | 5c 22 2c 20 5c 5c 43 2d | \"\\C-y|\", \\C-|
|000014e0| 79 5f 64 61 74 61 2c 20 | 5c 5c 43 2d 79 5f 66 75 |y_data, |\\C-y_fu|
|000014f0| 6e 63 74 69 6f 6e 20 7d | 2c 0a 20 20 20 20 5c 5c |nction }|,. \\|
|00001500| 43 2d 78 20 29 0a 0a 61 | 6e 64 20 74 68 65 6e 20 |C-x )..a|nd then |
|00001510| 73 65 6c 65 63 74 20 74 | 68 65 20 72 65 67 69 6f |select t|he regio|
|00001520| 6e 20 6f 66 20 75 6e 2d | 74 61 62 6c 69 66 69 65 |n of un-|tablifie|
|00001530| 64 20 6e 61 6d 65 73 20 | 61 6e 64 20 75 73 65 0a |d names |and use.|
|00001540| 60 5c 5c 5b 61 70 70 6c | 79 2d 6d 61 63 72 6f 2d |`\\[appl|y-macro-|
|00001550| 74 6f 2d 72 65 67 69 6f | 6e 2d 6c 69 6e 65 73 5d |to-regio|n-lines]|
|00001560| 27 20 74 6f 20 62 75 69 | 6c 64 20 74 68 65 20 74 |' to bui|ld the t|
|00001570| 61 62 6c 65 20 66 72 6f | 6d 20 74 68 65 20 6e 61 |able fro|m the na|
|00001580| 6d 65 73 2e 0a 22 20 22 | 72 22 5d 29 0a |mes.." "|r"]). |
+--------+-------------------------+-------------------------+--------+--------+