From: Kim F. Storm Date: Mon, 1 Nov 2004 23:06:32 +0000 (+0000) Subject: (group kmacro): Add :version. X-Git-Tag: ttn-vms-21-2-B4~4268 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=1b25dccd6ef4ffd0d82daf82143d2107cc5099e1;p=emacs.git (group kmacro): Add :version. (kmacro-keyboard-quit): New function to cleanup on C-g. (kmacro-start-macro): Set defining-kbd-macro to append when appending to last macro. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6b030c02c7c..82aec89b14b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2004-11-02 Kim F. Storm + * descr-text.el (describe-text-properties): Don't err if called in + the *Help* buffer; output to *Help-2* buffer instead. + * kmacro.el (group kmacro): Add :version. (kmacro-keyboard-quit): New function to cleanup on C-g. (kmacro-start-macro): Set defining-kbd-macro to append when diff --git a/lisp/kmacro.el b/lisp/kmacro.el index 2b4cbcaf323..9ee34a8432c 100644 --- a/lisp/kmacro.el +++ b/lisp/kmacro.el @@ -1,6 +1,6 @@ ;;; kmacro.el --- enhanced keyboard macros -;; Copyright (C) 2002 Free Software Foundation, Inc. +;; Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc. ;; Author: Kim F. Storm ;; Keywords: keyboard convenience @@ -120,6 +120,7 @@ "Simplified keyboard macro user interface." :group 'keyboard :group 'convenience + :version "21.4" :link '(emacs-commentary-link :tag "Commentary" "kmacro.el") :link '(emacs-library-link :tag "Lisp File" "kmacro.el")) @@ -222,6 +223,14 @@ macro to be executed before appending to it." (global-set-key (vector kmacro-call-mouse-event) 'kmacro-end-call-mouse)) +;;; Called from keyboard-quit + +(defun kmacro-keyboard-quit () + (or (not defining-kbd-macro) + (eq defining-kbd-macro 'append) + (kmacro-ring-empty-p) + (kmacro-pop-ring))) + ;;; Keyboard macro counter @@ -585,7 +594,9 @@ Use \\[kmacro-bind-to-key] to bind it to a key sequence." (and append (if kmacro-execute-before-append (> (car arg) 4) - (= (car arg) 4))))))) + (= (car arg) 4)))) + (if (and defining-kbd-macro append) + (setq defining-kbd-macro 'append))))) ;;;###autoload