[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#70949: display-buffer-choose-some-window
From: |
Juri Linkov |
Subject: |
bug#70949: display-buffer-choose-some-window |
Date: |
Fri, 07 Jun 2024 19:45:33 +0300 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/30.0.50 (x86_64-pc-linux-gnu) |
close 70949 30.0.50
thanks
>> Then let's install the first patch for (nil . ((some-window . mru)))
>> that is not so controversial.
>
> OK with me.
Very nice! So the original patch is pushed, and now the OP can happily use:
(setq display-buffer-base-action '(nil . ((some-window . mru))))
and I can use:
(defvar-local display-buffer-last-window nil)
(setq display-buffer-base-action
'(nil . ((some-window
. (lambda (_buffer alist)
(let ((last-window (buffer-local-value
'display-buffer-last-window
(window-buffer))))
(or (and (window-live-p last-window) last-window)
(get-mru-window nil nil t))))))))
(define-advice display-buffer-record-window (:after (type window buffer))
(with-current-buffer (window-buffer)
(setq-local display-buffer-last-window window)))
that works nicely even for showing buffers repeatedly
in the selected window. And all commands are supported,
even to show diffs from vc-dir.
- bug#70949: display-buffer-choose-some-window, Juri Linkov, 2024/06/02
- bug#70949: display-buffer-choose-some-window, martin rudalics, 2024/06/04
- bug#70949: display-buffer-choose-some-window, Juri Linkov, 2024/06/04
- bug#70949: display-buffer-choose-some-window, martin rudalics, 2024/06/05
- bug#70949: display-buffer-choose-some-window, Juri Linkov, 2024/06/05
- bug#70949: display-buffer-choose-some-window, martin rudalics, 2024/06/06
- bug#70949: display-buffer-choose-some-window, Juri Linkov, 2024/06/07
- bug#70949: display-buffer-choose-some-window, martin rudalics, 2024/06/07
- bug#70949: display-buffer-choose-some-window,
Juri Linkov <=
- bug#70949: display-buffer-choose-some-window, martin rudalics, 2024/06/08
- bug#70949: display-buffer-choose-some-window, Juri Linkov, 2024/06/09