changeset 63336:423fcdb144f5

(Man-mode-map): Initialize it properly. (Man-mode): Set mode-class property to special.
author Lute Kamstra <lute@gnu.org>
date Sun, 12 Jun 2005 10:08:56 +0000
parents f6ea50272353
children abb85b9b2afa
files lisp/man.el
diffstat 1 files changed, 7 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/man.el	Sun Jun 12 09:00:57 2005 +0000
+++ b/lisp/man.el	Sun Jun 12 10:08:56 2005 +0000
@@ -391,10 +391,11 @@
     table)
   "Syntax table used in Man mode buffers.")
 
-(if Man-mode-map
-    nil
-  (setq Man-mode-map (copy-keymap button-buffer-map))
+(unless Man-mode-map
+  (setq Man-mode-map (make-sparse-keymap))
   (suppress-keymap Man-mode-map)
+  (set-keymap-parent Man-mode-map button-buffer-map)
+
   (define-key Man-mode-map " "    'scroll-up)
   (define-key Man-mode-map "\177" 'scroll-down)
   (define-key Man-mode-map "n"    'Man-next-section)
@@ -410,8 +411,7 @@
   (define-key Man-mode-map "k"    'Man-kill)
   (define-key Man-mode-map "q"    'Man-quit)
   (define-key Man-mode-map "m"    'man)
-  (define-key Man-mode-map "?"    'describe-mode)
-  )
+  (define-key Man-mode-map "?"    'describe-mode))
 
 ;; buttons
 (define-button-type 'Man-xref-man-page
@@ -1023,6 +1023,8 @@
 ;; ======================================================================
 ;; set up manual mode in buffer and build alists
 
+(put 'Man-mode 'mode-class 'special)
+
 (defun Man-mode ()
   "A mode for browsing Un*x manual pages.