aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoland McGrath1993-09-07 00:56:00 +0000
committerRoland McGrath1993-09-07 00:56:00 +0000
commite7683fffbf7fd1b764ddfbeb788abc12a38e2b78 (patch)
tree3be6be1276216a1622319265d3891f1aa406073a
parent68cd265f830104789138f1dec83dc0b6d81592bd (diff)
downloademacs-e7683fffbf7fd1b764ddfbeb788abc12a38e2b78.tar.gz
emacs-e7683fffbf7fd1b764ddfbeb788abc12a38e2b78.zip
(jump-to-register): Take new optional arg NODELETE (prefix arg); pass
through to set-frame-configuration.
-rw-r--r--lisp/register.el10
1 files changed, 6 insertions, 4 deletions
diff --git a/lisp/register.el b/lisp/register.el
index 32646112857..4a4c29ac98e 100644
--- a/lisp/register.el
+++ b/lisp/register.el
@@ -74,19 +74,21 @@ Argument is a character, naming the register."
74 (set-register char (current-frame-configuration))) 74 (set-register char (current-frame-configuration)))
75 75
76(defalias 'register-to-point 'jump-to-register) 76(defalias 'register-to-point 'jump-to-register)
77(defun jump-to-register (char) 77(defun jump-to-register (char &optional nodelete)
78 "Move point to location stored in a register. 78 "Move point to location stored in a register.
79If the register contains a file name, find that file. 79If the register contains a file name, find that file.
80 \(To put a file name in a register, you must use `set-register'.) 80 \(To put a file name in a register, you must use `set-register'.)
81If the register contains a window configuration (one frame) or a frame 81If the register contains a window configuration (one frame) or a frame
82configuration (all frames), restore that frame or all frames accordingly. 82configuration (all frames), restore that frame or all frames accordingly.
83Argument is a character, naming the register." 83First argument is a character, naming the register.
84 (interactive "cJump to register: ") 84Optional second arg non-nil (interactively, prefix argument) says not to
85delete any existing frames when restoring a frame configuration."
86 (interactive "cJump to register: \nP")
85 (let ((val (get-register char))) 87 (let ((val (get-register char)))
86 (cond 88 (cond
87 ((and (fboundp 'frame-configuration-p) 89 ((and (fboundp 'frame-configuration-p)
88 (frame-configuration-p val)) 90 (frame-configuration-p val))
89 (set-frame-configuration val)) 91 (set-frame-configuration val nodelete))
90 ((window-configuration-p val) 92 ((window-configuration-p val)
91 (set-window-configuration val)) 93 (set-window-configuration val))
92 ((markerp val) 94 ((markerp val)