Reputation: 2534
Is there an built-in option in emacs to toggle between full window and a split window, so that both files remain the same? As if minimizing one buffer for a while. Currently, when I do C-x 3 to split vertically it will open the same buffer, I then open a file in the other window. But at some point I want to concentrate fully on one part again and "minimize" the other half of the window. And later I want to unminimize and have both files shown again. Is this toggling of emacs windows possible?
NB: I use term "window" in emacsian.
Upvotes: 5
Views: 184
Reputation: 30708
@Seanmcl's answer is a good one, as is @abo-abo's.
Depending on how you work or just what you want to do, you can also use C-x 5 2
to open the current buffer in a new frame. And then use C-x 5 0
there to delete that frame when done focusing on that buffer.
Upvotes: 2
Reputation: 20362
I'm using `winner-mode' for this purpose:
(winner-mode)
(global-set-key [f9] 'delete-other-windows)
(global-set-key [C-f9] 'delete-window)
(global-set-key (kbd "<f7>") 'winner-undo)
(global-set-key (kbd "C-<f7>") 'winner-redo)
This way
I rarely use C-f7, just included it for completeness.
Upvotes: 4