diff options
| author | Roland McGrath | 1993-09-07 00:56:00 +0000 |
|---|---|---|
| committer | Roland McGrath | 1993-09-07 00:56:00 +0000 |
| commit | e7683fffbf7fd1b764ddfbeb788abc12a38e2b78 (patch) | |
| tree | 3be6be1276216a1622319265d3891f1aa406073a | |
| parent | 68cd265f830104789138f1dec83dc0b6d81592bd (diff) | |
| download | emacs-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.el | 10 |
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. |
| 79 | If the register contains a file name, find that file. | 79 | If 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'.) |
| 81 | If the register contains a window configuration (one frame) or a frame | 81 | If the register contains a window configuration (one frame) or a frame |
| 82 | configuration (all frames), restore that frame or all frames accordingly. | 82 | configuration (all frames), restore that frame or all frames accordingly. |
| 83 | Argument is a character, naming the register." | 83 | First argument is a character, naming the register. |
| 84 | (interactive "cJump to register: ") | 84 | Optional second arg non-nil (interactively, prefix argument) says not to |
| 85 | delete 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) |