]> git.eshelyaron.com Git - emacs.git/commitdiff
(minor-mode-map-alist): Use substitute-key-definition
authorKarl Heuer <kwzh@gnu.org>
Fri, 3 Nov 1995 03:11:24 +0000 (03:11 +0000)
committerKarl Heuer <kwzh@gnu.org>
Fri, 3 Nov 1995 03:11:24 +0000 (03:11 +0000)
to find the appropriate bindings for window enlarge/shrink.
(2C-shrink-window-horizontally, 2C-enlarge-window-horizontally):
Renamed from shrink-window-horizontally, enlarge-window-horizontally
to avoid redefining the standard functions.

lisp/textmodes/two-column.el

index 9b27b5ee37c371448739eeb624063f363be4b38b..9452a4f9e54b02e11fa29e33f5ecd891fca65939 100644 (file)
     (define-key map [f2] '2C-two-columns)
     (define-key map "b" '2C-associate-buffer)
     (define-key map "s" '2C-split)
-    (define-key map "{" 'shrink-window-horizontally)
-    (define-key map "}" 'enlarge-window-horizontally)
     map)
   "Keymap for commands for setting up two-column mode.")
 
     (define-key map "o" '2C-associated-buffer)
     (define-key map "\^m" '2C-newline)
     (define-key map "|" '2C-toggle-autoscroll)
+    (define-key map "{" '2C-shrink-window-horizontally)
+    (define-key map "}" '2C-enlarge-window-horizontally)
     map)
   "Keymap for commands for use in two-column mode.")
 
                  (let ((map (make-sparse-keymap)))
                    (substitute-key-definition '2C-command 2C-minor-mode-map
                                               map (current-global-map))
+                   (substitute-key-definition 'enlarge-window-horizontally
+                                              '2C-enlarge-window-horizontally
+                                              map (current-global-map))
+                   (substitute-key-definition 'shrink-window-horizontally
+                                              '2C-shrink-window-horizontally
+                                              map (current-global-map))
                    map))
            minor-mode-map-alist))
 \f
@@ -597,7 +603,7 @@ When autoscrolling is turned on, this also realigns the two buffers."
 
 
 
-(defun enlarge-window-horizontally (arg)
+(defun 2C-enlarge-window-horizontally (arg)
   "Make current window ARG columns wider."
   (interactive "p")
   (enlarge-window arg t)
@@ -606,10 +612,10 @@ When autoscrolling is turned on, this also realigns the two buffers."
        (set-buffer (2C-other))
        (setq 2C-window-width (- 2C-window-width arg))))
 
-(defun shrink-window-horizontally (arg)
+(defun 2C-shrink-window-horizontally (arg)
   "Make current window ARG columns narrower."
   (interactive "p")
-  (enlarge-window-horizontally (- arg)))
+  (2C-enlarge-window-horizontally (- arg)))