本文介绍了在emacs中,我可以设置* Messages *缓冲区以使其尾随的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
基本上,我想要 * 消息 * 缓冲区,当新消息到达时,总是滚动到底部。
Basically I want the *Messages* buffer to always scroll to the bottom when a new message arrives.
我可以这样做吗?
我发现 auto-revert-tail-mode
,但适用于访问文件的缓冲区。
当我在消息缓冲区中尝试它时,弹出一个错误:
auto-revert-tail-mode:此缓冲区不访问文件
I found auto-revert-tail-mode
but that works for buffers that are visiting files. When I tried it in the Messages buffer, it popped an error:auto-revert-tail-mode: This buffer is not visiting a file
推荐答案
对于您可能想要的多个框架:
For multiple frames you probably want:
(defadvice message (after message-tail activate)
"goto point max after a message"
(with-current-buffer "*Messages*"
(goto-char (point-max))
(walk-windows (lambda (window)
(if (string-equal (buffer-name (window-buffer window)) "*Messages*")
(set-window-point window (point-max))))
nil
t)))
这篇关于在emacs中,我可以设置* Messages *缓冲区以使其尾随的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!