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

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

bug#37840: Missing in the Emacs manuals:


From: martin rudalics
Subject: bug#37840: Missing in the Emacs manuals:
Date: Sun, 10 Nov 2019 19:33:17 +0100

> So what is the correct customization if I wish to have _every_
> buffer in its own (new) frame, just different buffer types having
> different frame types, the latter meaning different geometry, fonts
> etc.?

I'm afraid there's none.  The reason is a technical one.  The speedbar
code uses 'switch-to-buffer' internally to switch to its own buffer in
its own window on its own frame.  Any customization of
'switch-to-buffer' to do something like switch to _any_ buffer in
another frame will make the speedbar choke because its buffer won't be
displayed in the same window where it expects it.

Note that 'switch-to-buffer-obey-display-actions' is a new addition
that has not been yet tested extensively.  In earlier versions you had
no possibility customizing the behavior of 'switch-to-buffer'.  In
practice, it always used the selected window for displaying the
buffer.

You could try to replace the regexp in 'display-buffer-alist' with a
function that filters out all buffers that are in a sense special like
the speedbar buffer but I'm afraid that you will encounter too many
instances of internal uses of 'switch-to-buffer' so you will soon or
later get tired of such an approach.

The other approach is to specify in that function all buffers that
interest you (mostly based on the extension of the file they visit)
instead of _every_ buffer.  Would that be so difficult?

Finally, note that if you make sure that practically all windows you
use are strongly dedicated to their buffers, 'switch-to-buffer' calls
will respect that.  For example, if with emacs -Q I do

(custom-set-variables
 '(display-buffer-base-action
   '((display-buffer-reuse-window display-buffer-pop-up-frame)
     (dedicated . t)
     (reusable-frames . 0))))

(set-window-dedicated-p nil t)

and then choose *Messages* from the Buffers menu, it will pop up in a
new frame and the speedbar will work normally.  Note, however, that
strongly dedicated windows may have other disadvantages you will have
to get used to.

martin





reply via email to

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