]> code.delx.au - gnu-emacs/blobdiff - lisp/emacs-lisp/map-ynp.el
Move comments into docstrings.
[gnu-emacs] / lisp / emacs-lisp / map-ynp.el
index 2fa97f163d7e44f12e2452d2001d2857f53c0cfd..84c7ae58ced7676c1d818aea6bc0efc095933e7a 100644 (file)
@@ -1,6 +1,7 @@
 ;;; map-ynp.el --- general-purpose boolean question-asker
 
-;; Copyright (C) 1991, 1992, 1993, 1994, 1995, 2000 Free Software Foundation, Inc.
+;; Copyright (C) 1991, 1992, 1993, 1994, 1995, 2000, 2002, 2003,
+;;   2004, 2005 Free Software Foundation, Inc.
 
 ;; Author: Roland McGrath <roland@gnu.org>
 ;; Maintainer: FSF
@@ -20,8 +21,8 @@
 
 ;; You should have received a copy of the GNU General Public License
 ;; along with GNU Emacs; see the file COPYING.  If not, write to the
-;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-;; Boston, MA 02111-1307, USA.
+;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+;; Boston, MA 02110-1301, USA.
 
 ;;; Commentary:
 
@@ -102,15 +103,18 @@ Returns the number of actions taken."
        (let ((object (if help (capitalize (nth 0 help))))
              (objects (if help (capitalize (nth 1 help))))
              (action (if help (capitalize (nth 2 help)))))
-         (setq map `(("Yes" . act) ("No" . skip) ("Quit" . exit)
-                     (,(if help (concat action " " object " And Quit")
-                         "Do it and Quit") . act-and-exit)
-                     (,(if help (concat action " All " objects)
-                         "Do All") . automatic)
+         (setq map `(("Yes" . act) ("No" . skip)
                      ,@(mapcar (lambda (elt)
-                                 (cons (capitalize (nth 2 elt))
+                                 (cons (with-syntax-table
+                                           text-mode-syntax-table
+                                         (capitalize (nth 2 elt)))
                                        (vector (nth 1 elt))))
-                               action-alist))
+                               action-alist)
+                     (,(if help (concat action " This But No More")
+                         "Do This But No More") . act-and-exit)
+                     (,(if help (concat action " All " objects)
+                         "Do All") . automatic)
+                     ("No For All" . exit))
                use-menus t
                mouse-event last-nonmenu-event))
       (setq user-keys (if action-alist
@@ -200,10 +204,10 @@ Returns the number of actions taken."
                               (concat
                                (format "Type SPC or `y' to %s the current %s;
 DEL or `n' to skip the current %s;
-RET or `q' to exit (skip all remaining %s);
-C-g to quit (cancel the operation);
+RET or `q' to give up on the %s (skip all remaining %s);
+C-g to quit (cancel the whole command);
 ! to %s all remaining %s;\n"
-                                       action object object objects action
+                                       action object object action objects action
                                        objects)
                                (mapconcat (function
                                            (lambda (elt)
@@ -261,4 +265,5 @@ the current %s and exit."
     ;; Return the number of actions that were taken.
     actions))
 
+;;; arch-tag: 1d0a3201-a151-4c10-b231-4da47c9e6dc3
 ;;; map-ynp.el ends here