# HG changeset patch # User Gerd Moellmann # Date 956176846 0 # Node ID 17281c5a2834988c297dd5e4449e059233b2a6c3 # Parent bb5083cf05654108c8fb0012938b617c6ad9580d (clone-indirect-buffer-other-window): New command. (clone-indirect-buffer): Add optional arg NORECROD. (toplevel): Bind `C-x 4 c' to clone-indirect-buffer-other-window. diff -r bb5083cf0565 -r 17281c5a2834 lisp/simple.el --- a/lisp/simple.el Wed Apr 19 19:12:22 2000 +0000 +++ b/lisp/simple.el Wed Apr 19 20:40:46 2000 +0000 @@ -4158,7 +4158,7 @@ new)) -(defun clone-indirect-buffer (newname display-flag) +(defun clone-indirect-buffer (newname display-flag &optional norecord) "Create an indirect buffer that is a twin copy of the current buffer. Give the indirect buffer name NEWNAME. Interactively, read NEW-NAME @@ -4168,7 +4168,10 @@ or by incrementing the N in an existing suffix. DISPLAY-FLAG non-nil means show the new buffer with `pop-to-buffer'. -This is always done when called interactively." +This is always done when called interactively. + +Optional last arg NORECORD non-nil means do not put this buffer at the +front of the list of recently selected ones." (interactive (list (if current-prefix-arg (read-string "BName of indirect buffer: ")) t)) @@ -4182,6 +4185,18 @@ buffer)) +(defun clone-indirect-buffer-other-window (buffer &optional norecord) + "Create an indirect buffer that is a twin copy of BUFFER. +Select the new buffer in another window. +Optional second arg NORECORD non-nil means do not put this buffer at +the front of the list of recently selected ones." + (interactive "bClone buffer in other window: ") + (let ((popup-windows t)) + (set-buffer buffer) + (clone-indirect-buffer nil t norecord))) + +(define-key ctl-x-4-map "c" 'display-buffer) + ;;; Syntax stuff.