aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoland McGrath1993-08-02 22:18:34 +0000
committerRoland McGrath1993-08-02 22:18:34 +0000
commitceab6935fd988c7d31e2bf725f6af3d12773b6ce (patch)
treedfcb41766dec7e55ff4f5e9f890ecb9b0b0f83bc
parentef2c57aca04c8311f3e7bb872bdae769bba9a30b (diff)
downloademacs-ceab6935fd988c7d31e2bf725f6af3d12773b6ce.tar.gz
emacs-ceab6935fd988c7d31e2bf725f6af3d12773b6ce.zip
(other-frame): New function, analogous to other-window.
(ctl-x-5-map): Bind C-x 5 o to other-frame.
-rw-r--r--lisp/frame.el17
1 files changed, 17 insertions, 0 deletions
diff --git a/lisp/frame.el b/lisp/frame.el
index 743758d1095..90469d26b17 100644
--- a/lisp/frame.el
+++ b/lisp/frame.el
@@ -350,6 +350,22 @@ the user during startup."
350 (cdr param-list)) 350 (cdr param-list))
351 351
352 352
353(defun other-frame (arg)
354 "Select the ARG'th different frame, deiconify and raise it.
355All frames are arranged in a cyclic order.
356This command selects the frame ARG steps away in that order.
357A negative ARG moves in the opposite order."
358 (interactive "p")
359 (let ((frame (selected-frame)))
360 (while (> arg 0)
361 (setq frame (next-frame frame)
362 arg (1- arg)))
363 (while (< arg 0)
364 (setq frame (previous-frame frame)
365 arg (1- arg)))
366 (make-frame-visible frame)
367 (raise-frame frame)
368 (select-frame frame)))
353 369
354;;;; Frame configurations 370;;;; Frame configurations
355 371
@@ -535,6 +551,7 @@ should use `set-frame-width' instead."
535 551
536(define-key ctl-x-5-map "2" 'new-frame) 552(define-key ctl-x-5-map "2" 'new-frame)
537(define-key ctl-x-5-map "0" 'delete-frame) 553(define-key ctl-x-5-map "0" 'delete-frame)
554(define-key ctl-x-5-map "o" 'other-frame)
538 555
539(provide 'frame) 556(provide 'frame)
540 557