bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#16767: 24.3.50; `C-x 5 b' for special-display buffers


From: martin rudalics
Subject: bug#16767: 24.3.50; `C-x 5 b' for special-display buffers
Date: Tue, 7 Sep 2021 10:15:12 +0200

> So the bug seems rather that C-x 5 b with `special-display-regexps' nil
> pops up a new frame when the buffer already appears on some frame.

Summarizing:

C-x 5 b with `special-display-regexps' uncustomized behaves as expected
with one minor inaccuracy:

- The doc-string says that "By default, if the buffer is already
  displayed (even in the current frame), that window is selected."

- The manual says more accurately that "If the specified buffer is
  already displayed in another window, in any frame on the current
  terminal, this switches to that window instead of creating a new
  frame.  However, the selected window is never used for this."

So if *scratch* is displayed in the selected window, that window is not
used but the doc-string doesn't tell that.

C-x 5 b with `special-display-regexps' customized in a way that matches
the name of the buffer to switch to, behaves as advertised.  In the case
at hand, it assumes that if *scratch* already appears in a window,
*scratch* has been "displayed specially" in that window and consequently
reuses that window as prescribed.  Popping up a separate window or frame
for *scratch* would be wrong.

Concluding: This is "not a bug" and all statements made in the original
report are based on a misunderstanding of the now obsolete concept of
the special display of buffers.  It's probably about time to remove that
code from base.

martin





reply via email to

[Prev in Thread] Current Thread [Next in Thread]