2017-07-31 42 views
0

想知道是否有人知道控制在magit中滚动的参数。目前,当我处于缓冲区并保持按下空格键时,其他窗口中的差异视图滚动到底部,并继续回到顶部并滚动 - 实际上是无休止的。有没有办法让它停在底部?Emacs magit diff-buffer滚动 - 如何在底部停止

回答

0

没有为没有选择,但你可以得到你想要的行为被重新定义magit-diff-show-or-scroll-up

(defun magit-diff-show-or-scroll-up() 
    "Update the commit or diff buffer for the thing at point. 

Either show the commit or stash at point in the appropriate 
buffer, or if that buffer is already being displayed in the 
current frame and contains information about that commit or 
stash, then instead scroll the buffer up. If there is no 
commit or stash at point, then prompt for a commit." 
    (interactive) 
    (magit-diff-show-or-scroll (lambda() (scroll-up)))) 
+0

不错..我猜你强迫'(到pCASE ..'不匹配并使滚动错误没有操作。谢谢 - 它的工作原理! – RoyM

+0

是的,这是如何工作的。 – tarsius