有什么办法可以让undo-tree-mode在“水平”缓冲区中显示可视化(即 C-x 3 与 C-x 2)?
最佳答案
根据@Tom's suggestion ,我提出了一个仅适用于撤消树的解决方案:
(defadvice undo-tree-visualize (around undo-tree-split-side-by-side activate)
"Split undo-tree side-by-side"
(let ((split-height-threshold nil)
(split-width-threshold 0))
ad-do-it))
2017-04-29:defadvice
现已弃用,取而代之的是 advice-add
。上述解决方案的更新版本如下:
(defun undo-tree-split-side-by-side (original-function &rest args)
"Split undo-tree side-by-side"
(let ((split-height-threshold nil)
(split-width-threshold 0))
(apply original-function args)))
(advice-add 'undo-tree-visualize :around #'undo-tree-split-side-by-side)
关于plugins - 垂直打开 'undo-tree-visualize side by side to the buffer, and not "”,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7225054/