unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Robert Pluim <rpluim@gmail.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: michael.albinus@gmx.de,  emacs-devel@gnu.org
Subject: Re: emacs-29 bdb0bc2b4e4: Fix tex-mode display-buffer issues
Date: Mon, 12 Jun 2023 17:57:00 +0200	[thread overview]
Message-ID: <87o7lkhdwz.fsf@gmail.com> (raw)
In-Reply-To: <83a5x4yci0.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 12 Jun 2023 17:35:35 +0300")

>>>>> On Mon, 12 Jun 2023 17:35:35 +0300, Eli Zaretskii <eliz@gnu.org> said:

    >> From: Robert Pluim <rpluim@gmail.com>
    >> Cc: Michael Albinus <michael.albinus@gmx.de>,  emacs-devel@gnu.org
    >> Date: Mon, 12 Jun 2023 16:01:46 +0200
    >> 
    Eli> Sorry, I have no idea what this failure means.  In particular, the
    Eli> value is correct for the defcustom, and works in practice, and also
    Eli> fits the type of the defcustom (AFAICT).
    >> 
    >> Are you sure?

    Eli> Sure about which part?

About it fitting the type of the defcustom. Since the current value
works for you, it appears the code is more lenient than the defcustom
type indicates.

    Eli> Once again, if you see the problem, feel free to fix it, and thanks.

The minimal fix would be:

diff --git a/lisp/window.el b/lisp/window.el
index 78b0787abdb..16f16a75418 100644
--- a/lisp/window.el
+++ b/lisp/window.el
@@ -8776,7 +8776,7 @@ display-comint-buffer-action
   :group 'windows
   :group 'comint)
 
-(defcustom display-tex-shell-buffer-action 'display-buffer-in-previous-window
+(defcustom display-tex-shell-buffer-action '(display-buffer-in-previous-window)
   "`display-buffer' action for displaying TeX shell buffers."
   :type display-buffer--action-custom-type
   :risky t

Although if we went by analogy to `display-comint-buffer-action', it
would have to be this:

diff --git a/lisp/window.el b/lisp/window.el
index 78b0787abdb..0213023e495 100644
--- a/lisp/window.el
+++ b/lisp/window.el
@@ -7575,6 +7575,13 @@ display-buffer--same-window-action
 Specifies to call `display-buffer-same-window'.")
 (put 'display-buffer--same-window-action 'risky-local-variable t)
 
+(defvar display-buffer--in-previous-window-action
+  '(display-buffer-in-previous-window
+    (inhibit-same-window . t))
+  "A `display-buffer' action for displaying in the previous window.
+Specifies to call `display-buffer-in-previous-window'.")
+(put 'display-buffer--in-previous-window-action 'risky-local-variable t)
+
 (defvar display-buffer--other-frame-action
   '((display-buffer-reuse-window
      display-buffer-pop-up-frame)
@@ -8776,7 +8783,7 @@ display-comint-buffer-action
   :group 'windows
   :group 'comint)
 
-(defcustom display-tex-shell-buffer-action 'display-buffer-in-previous-window
+(defcustom display-tex-shell-buffer-action display-buffer--in-previous-window-action
   "`display-buffer' action for displaying TeX shell buffers."
   :type display-buffer--action-custom-type
   :risky t


Robert
-- 



  reply	other threads:[~2023-06-12 15:57 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <168646413703.30014.174311348729871734@vcs2.savannah.gnu.org>
     [not found] ` <20230611061539.9CBD6C1925C@vcs2.savannah.gnu.org>
2023-06-12 12:21   ` emacs-29 bdb0bc2b4e4: Fix tex-mode display-buffer issues Michael Albinus
2023-06-12 13:11     ` Eli Zaretskii
2023-06-12 13:25       ` Eli Zaretskii
2023-06-12 14:01       ` Robert Pluim
2023-06-12 14:35         ` Eli Zaretskii
2023-06-12 15:57           ` Robert Pluim [this message]
2023-06-12 16:40             ` Eli Zaretskii
2023-06-12 17:10               ` Robert Pluim
2023-06-12 17:51                 ` Eli Zaretskii

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=87o7lkhdwz.fsf@gmail.com \
    --to=rpluim@gmail.com \
    --cc=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=michael.albinus@gmx.de \
    /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).