]> code.delx.au - gnu-emacs/blobdiff - lisp/textmodes/reftex-index.el
Update for MH-E release 7.95.
[gnu-emacs] / lisp / textmodes / reftex-index.el
index 83a5d4ac1370510fd54a9dd9ed3a069662bef8f9..5616d4f454c9bb09d5b41cfd1ae509904f2656d4 100644 (file)
@@ -1,9 +1,9 @@
 ;;; reftex-index.el --- index support with RefTeX
-;; Copyright (c) 1997, 1998, 1999, 2000, 2003, 2004, 2005
-;;  Free Software Foundation, Inc.
+;; Copyright (C) 1997, 1998, 1999, 2000, 2003, 2004, 2005,
+;;   2006 Free Software Foundation, Inc.
 
 ;; Author: Carsten Dominik <dominik@science.uva.nl>
-;; Version: VERSIONTAG
+;; Version: 4.31
 
 ;; This file is part of GNU Emacs.
 
@@ -19,8 +19,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:
 
@@ -166,13 +166,20 @@ will prompt for other arguments."
   ;; OPT-ARGS is a list of optional argument indices, as given by
   ;; `reftex-parse-args'.
   (let* ((opt (and (integerp itag) (member itag opt-args)))
-         (index-tags (cdr (assq 'index-tags 
-                                (symbol-value reftex-docstruct-symbol))))
-         (default (reftex-default-index))
-         (prompt (concat "Index tag"
-                         (if default (format " (default: %s)" default) "")
-                         (if opt " (optional)" "") ": "))
-         (tag (completing-read prompt (mapcar 'list index-tags))))
+        (index-tags (cdr (assq 'index-tags
+                               (symbol-value reftex-docstruct-symbol))))
+        (default (reftex-default-index))
+        (prompt (concat "Index tag"
+                        (if (or opt default)
+                            (format " (%s): "
+                                    (concat
+                                     (if opt "optional" "")
+                                     (if default
+                                         (concat (if opt ", " "")
+                                                 (format "default %s" default))
+                                       "")))
+                          ": ")))
+        (tag (completing-read prompt (mapcar 'list index-tags))))
     (if (and default (equal tag "")) (setq tag default))
     (reftex-update-default-index tag)
     tag))
@@ -1027,6 +1034,7 @@ When index is restricted, select the previous section as restriction criterion."
 ;; Index map
 (define-key reftex-index-map (if (featurep 'xemacs) [(button2)] [(mouse-2)])
   'reftex-index-mouse-goto-line-and-hide)
+(define-key reftex-index-map [follow-link] 'mouse-face)
 
 (substitute-key-definition
  'next-line 'reftex-index-next reftex-index-map global-map)
@@ -1232,7 +1240,7 @@ If the buffer is non-empty, delete the old header first."
           (beginning-of-line 2))          
       (cond ((fboundp 'zmacs-activate-region) (zmacs-activate-region))
             ((boundp 'make-active) (setq mark-active t)))
-      (if (yes-or-no-p "Delete and rebuilt header ")
+      (if (yes-or-no-p "Delete and rebuild header? ")
           (delete-region (point-min) (point))))
 
     ;; Insert the mode line