diff options
author | Karl Heuer <kwzh@gnu.org> | 1995-03-08 01:25:04 +0000 |
---|---|---|
committer | Karl Heuer <kwzh@gnu.org> | 1995-03-08 01:25:04 +0000 |
commit | 9e1ffae242f28346d7ab876d85ba2453aab02635 (patch) | |
tree | d1a109de51894a2a89ed43e06d1aa77aa5e91cc6 /src/macros.c | |
parent | 603aaedc7b254c680b180b8206961868c80b66ed (diff) | |
download | emacs-9e1ffae242f28346d7ab876d85ba2453aab02635.tar.gz |
(Fstart_kbd_macro): Access Vlast_kbd_macro via perdisplay.
(Fend_kbd_macro, Fcall_last_kbd_macro): Likewise.
(init_macros): Delete initialization.
(syms_of_macros): Use DEFVAR_DISPLAY for Vlast_kbd_macro.
Doc fix for executing-macro, executing-kbd-macro, last-kbd-macro.
Diffstat (limited to 'src/macros.c')
-rw-r--r-- | src/macros.c | 24 |
1 files changed, 11 insertions, 13 deletions
diff --git a/src/macros.c b/src/macros.c index 75227ec6218..fd5c193e86a 100644 --- a/src/macros.c +++ b/src/macros.c @@ -27,8 +27,6 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ Lisp_Object Qexecute_kbd_macro; -Lisp_Object Vlast_kbd_macro; - Lisp_Object Vexecuting_macro; int executing_macro_index; @@ -64,7 +62,8 @@ Non-nil arg (prefix arg) means append to last macro defined;\n\ { message("Appending to kbd macro..."); current_perdisplay->kbd_macro_ptr = current_perdisplay->kbd_macro_end; - Fexecute_kbd_macro (Vlast_kbd_macro, make_number (1)); + Fexecute_kbd_macro (current_perdisplay->Vlast_kbd_macro, + make_number (1)); } current_perdisplay->defining_kbd_macro = Qt; @@ -96,7 +95,7 @@ An argument of zero means repeat until error.") { current_perdisplay->defining_kbd_macro = Qnil; update_mode_lines++; - Vlast_kbd_macro + current_perdisplay->Vlast_kbd_macro = make_event_array ((current_perdisplay->kbd_macro_end - current_perdisplay->kbd_macro_buffer), current_perdisplay->kbd_macro_buffer); @@ -104,12 +103,12 @@ An argument of zero means repeat until error.") } if (XFASTINT (arg) == 0) - Fexecute_kbd_macro (Vlast_kbd_macro, arg); + Fexecute_kbd_macro (current_perdisplay->Vlast_kbd_macro, arg); else { XSETINT (arg, XINT (arg)-1); if (XINT (arg) > 0) - Fexecute_kbd_macro (Vlast_kbd_macro, arg); + Fexecute_kbd_macro (current_perdisplay->Vlast_kbd_macro, arg); } return Qnil; } @@ -161,10 +160,10 @@ defining others, use \\[name-last-kbd-macro].") { if (! NILP (current_perdisplay->defining_kbd_macro)) error ("Can't execute anonymous macro while defining one"); - else if (NILP (Vlast_kbd_macro)) + else if (NILP (current_perdisplay->Vlast_kbd_macro)) error ("No kbd macro has been defined"); else - Fexecute_kbd_macro (Vlast_kbd_macro, prefix); + Fexecute_kbd_macro (current_perdisplay->Vlast_kbd_macro, prefix); return Qnil; } @@ -228,7 +227,6 @@ COUNT is a repeat count, or nil for once, or 0 for infinite loop.") init_macros () { - Vlast_kbd_macro = Qnil; Vexecuting_macro = Qnil; } @@ -246,13 +244,13 @@ syms_of_macros () "Non-nil while a keyboard macro is being defined. Don't set this!"); DEFVAR_LISP ("executing-macro", &Vexecuting_macro, - "Currently executing keyboard macro (a string); nil if none executing."); + "Currently executing keyboard macro (string or vector); nil if none executing."); DEFVAR_LISP_NOPRO ("executing-kbd-macro", &Vexecuting_macro, - "Currently executing keyboard macro (a string); nil if none executing."); + "Currently executing keyboard macro (string or vector); nil if none executing."); - DEFVAR_LISP ("last-kbd-macro", &Vlast_kbd_macro, - "Last kbd macro defined, as a string; nil if none defined."); + DEFVAR_DISPLAY ("last-kbd-macro", Vlast_kbd_macro, + "Last kbd macro defined, as a string or vector; nil if none defined."); } keys_of_macros () |