From: Chong Yidong <cyd@stupidchicken.com>
To: Stefan Monnier <monnier@IRO.UMontreal.CA>
Cc: 1061@emacsbugs.donarmstrong.com, Dan Nicolaescu <dann@ics.uci.edu>
Subject: bug#1061: pop-up-frames does not work on a tty
Date: Wed, 08 Oct 2008 20:51:31 -0400 [thread overview]
Message-ID: <87iqs2mvzg.fsf@cyd.mit.edu> (raw)
It may not be wise to change the behavior of pop-up-frames so radically
right now. How bout the following change, which allows a
`on-graphic-displays' value of pop-up-frames to restrict pop-up-frames
to graphic displays?
Martin's patch can go on top of this, for those people who do want to
use pop-up-frames on ttys (who knows, frame manipulation on ttys might
improve in the future).
diff -c /home/cyd/trunk/lisp/window.el.\~1.154.\~ /home/cyd/trunk/lisp/window.el
*** trunk/lisp/window.el.~1.154.~ 2008-10-05 14:13:01.000000000 -0400
--- trunk/lisp/window.el 2008-10-08 20:46:19.000000000 -0400
***************
*** 710,717 ****
:group 'windows)
(defcustom pop-up-frames nil
! "Non-nil means `display-buffer' should make a separate frame."
! :type 'boolean
:group 'windows)
(defcustom display-buffer-reuse-frames nil
--- 710,723 ----
:group 'windows)
(defcustom pop-up-frames nil
! "Whether `display-buffer' should make a separate frame.
! If nil, never make a seperate frame.
! If the value is `on-graphic-displays', make a separate frame only
! if the selected frame is on a graphic display.
! Any other non-nil value means to make a separate frame."
! :type '(choice (const :tag "Never" nil)
! (const :tag "On graphic displays" on-graphic-displays)
! (const :tag "Always" t))
:group 'windows)
(defcustom display-buffer-reuse-frames nil
***************
*** 941,946 ****
--- 947,957 ----
(not (or not-this-window
(window-dedicated-p (selected-window))
(window-minibuffer-p))))
+ (use-pop-up-frame
+ (cond ((null pop-up-frames) nil)
+ ((eq pop-up-frames 'on-graphic-displays)
+ (display-graphic-p))
+ (t t)))
(buffer (if (bufferp buffer-or-name)
buffer-or-name
(get-buffer buffer-or-name)))
***************
*** 967,973 ****
;; If the buffer's name tells us to use the selected window do so.
(window--display-buffer-2 buffer (selected-window)))
((let ((frames (or frame
! (and (or pop-up-frames display-buffer-reuse-frames
(not (last-nonminibuffer-frame)))
0)
(last-nonminibuffer-frame))))
--- 978,985 ----
;; If the buffer's name tells us to use the selected window do so.
(window--display-buffer-2 buffer (selected-window)))
((let ((frames (or frame
! (and (or use-pop-up-frame
! display-buffer-reuse-frames
(not (last-nonminibuffer-frame)))
0)
(last-nonminibuffer-frame))))
***************
*** 983,989 ****
(when pars
(funcall special-display-function
buffer (if (listp pars) pars))))))
! ((or pop-up-frames (not frame-to-use))
;; We want or need a new frame.
(window--display-buffer-2
buffer (frame-selected-window (funcall pop-up-frame-function))))
--- 995,1001 ----
(when pars
(funcall special-display-function
buffer (if (listp pars) pars))))))
! ((or use-pop-up-frame (not frame-to-use))
;; We want or need a new frame.
(window--display-buffer-2
buffer (frame-selected-window (funcall pop-up-frame-function))))
Diff finished. Wed Oct 8 20:46:21 2008
next reply other threads:[~2008-10-09 0:51 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-09 0:51 Chong Yidong [this message]
2008-10-09 1:59 ` bug#1061: pop-up-frames does not work on a tty Stefan Monnier
2008-10-09 8:33 ` martin rudalics
-- strict thread matches above, loose matches on Subject: below --
2008-10-01 8:40 Dan Nicolaescu
2008-10-01 13:05 ` martin rudalics
2008-10-01 15:57 ` Dan Nicolaescu
2008-10-01 13:26 ` martin rudalics
2008-10-01 15:20 ` Dan Nicolaescu
2008-10-01 15:20 ` Dan Nicolaescu
2008-10-01 18:20 ` martin rudalics
2008-10-01 18:56 ` Dan Nicolaescu
2008-10-02 9:33 ` martin rudalics
2008-10-02 12:45 ` Stefan Monnier
2008-10-03 11:51 ` martin rudalics
2008-10-03 13:09 ` Stefan Monnier
2008-10-03 13:41 ` martin rudalics
2008-10-06 14:02 ` Stefan Monnier
2008-10-06 16:31 ` martin rudalics
2008-10-03 17:06 ` Eli Zaretskii
2008-10-06 14:06 ` Stefan Monnier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87iqs2mvzg.fsf@cyd.mit.edu \
--to=cyd@stupidchicken.com \
--cc=1061@emacsbugs.donarmstrong.com \
--cc=dann@ics.uci.edu \
--cc=monnier@IRO.UMontreal.CA \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.