From: Stephen Leake <stephen_leake@stephe-leake.org>
To: emacs-devel <emacs-devel@gnu.org>
Subject: patch gud-gdb to respect other-frame-window?
Date: Sun, 29 Jul 2018 12:22:55 -0500 [thread overview]
Message-ID: <86muuaq7m8.fsf@stephe-leake.org> (raw)
Currently, 'gud-gdb' has its own notion of where to put the *gud-<exec name>*
buffer. Since I use other-frame-window (a GNU ELPA package), I'd like to
override that. This patch works for me:
diff --git a/lisp/progmodes/gud.el b/lisp/progmodes/gud.el
index 6826674a94..1b5cf46231 100644
--- a/lisp/progmodes/gud.el
+++ b/lisp/progmodes/gud.el
@@ -2608,9 +2608,11 @@ gud-common-init
(select-window
(display-buffer
(get-buffer-create (concat "*gud" filepart "*"))
- '(display-buffer-reuse-window
- display-buffer-in-previous-window
- display-buffer-same-window display-buffer-pop-up-window)))
+ (if (featurep 'other-frame-window)
+ '(display-buffer-same-window)
+ '(display-buffer-reuse-window
+ display-buffer-in-previous-window
+ display-buffer-same-window display-buffer-pop-up-window))))
(when (and existing-buffer (get-buffer-process existing-buffer))
(error "This program is already being debugged"))
;; Set the dir, in case the buffer already existed with a different dir.
A similar pattern can be used for other commands that do not currently
respect other-frame-window.
Ok to commit to master?
--
-- Stephe
next reply other threads:[~2018-07-29 17:22 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-29 17:22 Stephen Leake [this message]
2018-07-29 17:30 ` patch gud-gdb to respect other-frame-window? Eli Zaretskii
2018-07-30 6:56 ` Stephen Leake
2018-07-30 7:34 ` martin rudalics
2018-07-30 16:49 ` Stephen Leake
2018-07-31 6:37 ` martin rudalics
2018-07-31 9:21 ` [SPAM UNSURE] " Stephen Leake
2018-07-30 6:23 ` martin rudalics
2018-07-30 17:17 ` Stefan Monnier
2018-07-30 20:23 ` Stephen Leake
2018-07-30 20:28 ` Stefan Monnier
2018-07-30 20:30 ` Stephen Leake
2018-07-30 21:22 ` Stephen Leake
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=86muuaq7m8.fsf@stephe-leake.org \
--to=stephen_leake@stephe-leake.org \
--cc=emacs-devel@gnu.org \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).