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

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

bug#45688: 28.0.50; New action for display-buffer?


From: Lars Ingebrigtsen
Subject: bug#45688: 28.0.50; New action for display-buffer?
Date: Thu, 07 Jan 2021 16:39:29 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

martin rudalics <rudalics@gmx.at> writes:

>> As Martin explained, display-buffer-use-some-window almost does this,
>> but since switching to the buffer doesn't count as "use", it doesn't
>> work for this particular use case.
>
> Switching to the buffer does count as "use" but 'display-buffer' doesn't
> switch to the buffer because it doesn't select it.

Sorry; I meant "use the window".

> Add a function say 'window-bump-use-time' that does
>
>       w->use_time = ++window_select_count;
>
> and call that from `display-buffer'.

Thanks!

I've now pushed this -- like I said, my familiarity with this area in
Emacs is approx. nil, so if this implementation is beyond stupid, please
feel free to pipe up.  :-)

But with this setting:

  (setq display-buffer-base-action '(display-buffer-use-least-recent-window))

it's quite XEmacs-like?  I think?  At least in my tests.  So now we've
got that all-important ex-XEmacs market segment covered.

The only oddity is that it'll resize windows to their previous sizes --
is there any way to inhibit that?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





reply via email to

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