Is it possible to have new buffers created by a spesific command (vc-diff
for example) use the same viewable area as the current buffer?
Currently it creates a split window, which I need to manually close after using the buffer and deleting it.
Emacs Stack Exchange is a question and answer site for those using, extending or developing Emacs. It only takes a minute to sign up.
Sign up to join this communityThere is a global option to prevent splits from being opened:
(setq pop-up-windows nil)
When writing scripts you can locally assign this which won't apply outside the scope of the function, eg:
(defun vc-root-diff-fullscreen ()
"Open a diff of the repository in the current frame."
(interactive)
(let ((pop-up-windows nil))
(vc-root-diff nil)))
(pop-to-buffer (current-buffer))
withinvc-diff-internal
-- see comments in related thread for possible solutions: emacs.stackexchange.com/questions/29665/…(pop-to-buffer BUFFER)
to temporarily behave like(set-window-buffer (selected-window) BUFFER)
?" FYI: As far as I can tell, your question has nothing to do withframe
.pop-to-buffer
. I think its good to word questions from a user perspective when their not specifically about internal API's.