[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: frames dedicated to buffers, or, always see specific buffers in a sp
Re: frames dedicated to buffers, or, always see specific buffers in a specific frame
Mon, 15 Apr 2013 09:11:23 +0200
>> So for making this general purpose you should use `pop-to-buffer'
>> instead of `display-buffer'.
> Yes, that works too. Why exactly is this more general purpose?
I meant that if you really want to use this as a subtitute for
`switch-to-buffer' you should make sure the window and frame get
selected. They don't necessarily using `display-buffer' alone.
> Also, ido has these `ido-default-buffer-method' and
> `ido-default-file-method' that can be set to various options to
> control how buffer appears.
> But the way these options implemented does not bring them all to
> `display-buffer', which sometimes precludes user's control. Should't
> they be implemented via `display-buffer-alist', keeping any of the
> user's entries on top?
Doesn't setting `ido-default-buffer-method' to `display' work? Maybe we
could add `pop-to-buffer' to the default methods.
> Pity. But what about making `switch-to-buffer' delegate to
> `display-buffer' too? It could dinamically bind `display-buffer-alist'
> to display and select the buffer, but keeping any existing entries
> (probably set by the user, or other programs) on top.
> If that resulted in `switch-to-buffer' not switching to the buffer's
> window, it could not be considered unexpected behaviour, since
> ultimately the user set `display-buffer-alist' himself.
The basic idea of the `switch-to-buffer' functions is to bypass the
`display-buffer' customizations. That is, by default you display a
buffer in a certain manner but always can use `switch-to-buffer' to
override that default behavior.