多项:了解键盘绑定 [英] multi-term: Understanding keyboard bindings

查看:125
本文介绍了多项:了解键盘绑定的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我对多项中的这两个列表之间的区别感到困惑(顺便说一下官方存储库托管在哪里?)




  • term-bind-key-alist

  • term-unbind-key-list



在我的头脑中,应该有两件事:




  • 我们希望Emacs捕获自己并在一个

  • Emacs直接发送到shell的笔画(按原样)。



term-unbind-key-list term-bind-key-alist 定义这些列表和绑定?



此外,多项支持线模式字符模式 ?如果是这样,我们如何改变击键和这些列表的方式呢?

解决方案

我看到食谱 multi-term.rcp for el-get ,它是从emacswiki下载的。



term-bind-key-alist 适用于 term-send-up term-previous-input 等功能,其键盘是设置为emacs style而不是term style。



term-unbind-key-list 是一个用于设置的模拟'nil (请参阅字符模式中的ansi-term )。默认情况下, term-raw-map 中几乎所有的键都绑定到函数 term-send-raw 'nil 只是解除绑定。



term-bind-key-alist term-unbind-key-list 用于 term-raw-map 字符模式 c> term-mode-map 行模式)在multi-term.el中根本不被使用。 p>

我不使用多项,我设置 term-mode-map 术语-raw-map 直接。例如,在模式之间切换:

 (define-key term-mode-map(kbdCj)'term-char -mode)
(define-key term-raw-map(kbdCj)'term-line-mode)


I am a bit confused by the difference between these two lists in multi-term (by the way where is the official repository hosted?)

  • term-bind-key-alist
  • term-unbind-key-list

In my head, there should be two things:

  • The keystrokes that we want Emacs to capture itself and to interpret in a specific way (by binding them to commands)
  • The strokes that Emacs sends directly to the shell ("as is").

How exactly do term-unbind-key-list and term-bind-key-alist define these lists and bindings?

Also, does multi-term support line mode and character mode? If so, how does the mode in which we are alter the way keystrokes and these lists are interpreted?

解决方案

I saw recipe multi-term.rcp for el-get, it is downloaded from emacswiki.

term-bind-key-alist is for functions like term-send-up or term-previous-input, whose keybinds are set in "emacs style" instead of "term style".

term-unbind-key-list is an analog for setup 'nil (see ansi-term in character mode). By default almost all keys in term-raw-map are binded to function term-send-raw and 'nil just unbinds them.

term-bind-key-alist and term-unbind-key-list are used over of term-raw-map (character mode) and term-mode-map(line mode) in multi-term.el isn't used at all.

I don't use multi-term, I setup term-mode-map and term-raw-map directly. For example for switching between modes:

(define-key term-mode-map (kbd "C-j") 'term-char-mode)
(define-key term-raw-map (kbd "C-j") 'term-line-mode)

这篇关于多项:了解键盘绑定的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆