[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/woman.el,v
From: |
Stefan Monnier |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/woman.el,v |
Date: |
Mon, 10 Sep 2007 03:22:14 +0000 |
CVSROOT: /sources/emacs
Module name: emacs
Changes by: Stefan Monnier <monnier> 07/09/10 03:22:13
Index: woman.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/woman.el,v
retrieving revision 1.60
retrieving revision 1.61
diff -u -b -r1.60 -r1.61
--- woman.el 7 Sep 2007 02:45:28 -0000 1.60
+++ woman.el 10 Sep 2007 03:22:11 -0000 1.61
@@ -1761,21 +1761,21 @@
;;; Major mode (Man) interface:
-(defvar woman-mode-map nil "Keymap for woman mode.")
-
-(unless woman-mode-map
- (setq woman-mode-map (make-sparse-keymap))
- (set-keymap-parent woman-mode-map Man-mode-map)
-
- (define-key woman-mode-map "R" 'woman-reformat-last-file)
- (define-key woman-mode-map "w" 'woman)
- (define-key woman-mode-map "\en" 'WoMan-next-manpage)
- (define-key woman-mode-map "\ep" 'WoMan-previous-manpage)
- (define-key woman-mode-map [M-mouse-2] 'woman-follow-word)
+(defvar woman-mode-map
+ (let ((map (make-sparse-keymap)))
+ (set-keymap-parent map Man-mode-map)
+
+ (define-key map "R" 'woman-reformat-last-file)
+ (define-key map "w" 'woman)
+ (define-key map "\en" 'WoMan-next-manpage)
+ (define-key map "\ep" 'WoMan-previous-manpage)
+ (define-key map [M-mouse-2] 'woman-follow-word)
;; We don't need to call `man' when we are in `woman-mode'.
- (define-key woman-mode-map [remap man] 'woman)
- (define-key woman-mode-map [remap man-follow] 'woman-follow))
+ (define-key map [remap man] 'woman)
+ (define-key map [remap man-follow] 'woman-follow)
+ map)
+ "Keymap for woman mode.")
(defun woman-follow (topic)
"Get a Un*x manual page of the item under point and put it in a buffer."
@@ -2083,16 +2083,13 @@
(char-to-string woman-unpadded-space-char)
"Internal string representation of unpadded space characters.")
-(defvar woman-syntax-table nil
- "Syntax table to support special characters used internally by WoMan.")
-
-(if woman-syntax-table
- ()
- (setq woman-syntax-table (make-syntax-table))
+(defvar woman-syntax-table
+ (let ((st (make-syntax-table)))
;; The following internal chars must NOT have whitespace syntax:
- (modify-syntax-entry woman-unpadded-space-char "." woman-syntax-table)
- (modify-syntax-entry woman-escaped-escape-char "." woman-syntax-table)
- )
+ (modify-syntax-entry woman-unpadded-space-char "." st)
+ (modify-syntax-entry woman-escaped-escape-char "." st)
+ st)
+ "Syntax table to support special characters used internally by WoMan.")
(defun woman-set-buffer-display-table ()
"Set up a display table for a WoMan buffer.