也许这是一个愚蠢的问题..但我正在努力让我的emacs定制细粒度..是否有直接命令改变这样的窗口?
+----------------+
| |
| |
+----------------+
| |
| |
+----------------+
到
+----------------+------------+
| | |
| | |
+----------------+ |
| | |
| | |
+----------------+------------+
或者我是否需要开始学习elisp?
答案 0 :(得分:5)
将以下代码添加到.emacs中。 C-x C-e来评估它,然后希望击中F5将按预期执行(假设你没有杀死'* Messages *'缓冲区)。
global-set-key '[f5] '(lambda () (interactive)
(let ((other (buffer-name (window-buffer (next-window)))))
(delete-other-windows)
(set-frame-width (selected-frame)
(+ (frame-width (selected-frame)) (window-width)))
(split-window-horizontally)
(split-window-vertically)
(with-selected-window (next-window)
(set-window-buffer (selected-window) other))
(with-selected-window (previous-window)
(set-window-buffer (selected-window) "*Messages*")))))