瀏覽代碼

add scroll key bindings as scroll for term-mode

pull/1/head
10sr 12 年之前
父節點
當前提交
09672b95a2
共有 1 個文件被更改,包括 10 次插入1 次删除
  1. +10
    -1
      emacs.el

+ 10
- 1
emacs.el 查看文件

@@ -994,7 +994,16 @@ delete; o: select other; j, l: enlarge; h, k: shrink; q: quit."
(define-key term-raw-map
"\C-x" (lookup-key (current-global-map) "\C-x"))
(define-key term-raw-map
"\C-z" (lookup-key (current-global-map) "\C-z")))
"\C-z" (lookup-key (current-global-map) "\C-z"))
)
;; (define-key term-raw-map "\C-xl" 'term-line-mode)
;; (define-key term-mode-map "\C-xc" 'term-char-mode)
(define-key term-raw-map (kbd "<up>")
(lambda () (interactive) (scroll-down 1)))
(define-key term-raw-map (kbd "<down>")
(lambda () (interactive) (scroll-up 1)))
(define-key term-raw-map (kbd "<right>") 'scroll-up)
(define-key term-raw-map (kbd "<left>") 'scroll-down)
(define-key term-raw-map (kbd "C-p") 'term-send-raw)
(define-key term-raw-map (kbd "C-n") 'term-send-raw)
(define-key term-raw-map "q" 'my-term-quit-or-send-raw)


Loading…
取消
儲存