c-v/m-v一滚就滚全屏幕.
用这个,让它自己滚动,看行不行:
(use-package smooth-scrolling
:ensure t
:defer t
:init
(progn
(setq smooth-scroll-margin 5)
(smooth-scrolling-mode 1)
)
)
(provide 'xhx-smooth-scrolling)
7 回答5.3k 阅读
4 回答4k 阅读
2 回答5.9k 阅读✓ 已解决
2 回答2.5k 阅读✓ 已解决
1 回答2.4k 阅读✓ 已解决
2 回答808 阅读✓ 已解决
2 回答3.3k 阅读
我的.emacs中这样设置了下,ALT + P/N 可以方便的上下滚动
(defun hold-line-scroll-up()
"Scroll the page with the cursor in the same line"
(interactive)
(let ((next-screen-context-lines
(count-lines
(window-start) (window-end))))
(scroll-up)))
(global-set-key (kbd "M-N") 'hold-line-scroll-up)
;;
(defun hold-line-scroll-down()
"Scroll the page with the cursor in the same line"
(interactive)
(let ((next-screen-context-lines
(count-lines
(window-start) (window-end))))
(scroll-down)))
(global-set-key (kbd "M-P") 'hold-line-scroll-down)