Request: Reuse window with :align
justbur opened this issue · 3 comments
I would like it if I could have a rule like (pdf-view-mode :align right :size 0.6 :reuse t)
where the meaning of :reuse
is that if there exists a window to the right, use that window and resize it if possible. :reuse
could also be smarter and only use the window if there is currently a buffer in it to which that rule applies. In my example, if we already have a buffer in pdf-view-mode
, I'd like to just reuse that buffer instead of popping open a new one.
Perhaps this is possible already, but it wasn't clear to me how to achieve it.
:reuse
currently does exactly the same thing as display-buffer-reuse-window
, it checks whether the buffer to be displayed has already been. I wouldn't want to break the behavior for something like this. That aside, :reuse
and :align
introduce different behaviors. Changing things so that both combined yield a third one, well, I'm not a fan.
So if I understand right you're saying that what I want is :popup t :other t
? By the way, I expected just :other t
to be sufficient to popup a new window, but it's not.
Would it be possible to control the size of the popup if not the side that the popup appears on? Essentially what I want (and what doesn't seem to be easily achievable) is :align right :size 0.6
when the new window is created, but then the behavior of :popup t :other t
afterwards.
Should be doable with custom functions.