Ctrl-Shift 键发出哔哔声且不发送到终端 [英] Ctrl-Shift-key Beeps and Doesn't Send to Terminal

查看:15
本文介绍了Ctrl-Shift 键发出哔哔声且不发送到终端的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的 OS X 终端似乎无法识别 Ctrl-Shift.相反,当我按下 Ctrl-Shift 和键盘上的任何其他键时,它会发出哔哔声.我使用 Emacs,因此无法使用很多快捷方式.这不是 Bash 的哔哔声,而是 OS X 的哔哔声.

My OS X terminal does not seem to recognise Ctrl-Shift. Instead, it beeps when I hit Ctrl-Shift and any other key on the keyboard. I use Emacs and as a result I cannot use many shortcuts. It is not the Bash beep, but the OS X beep.

如何让我的终端识别 Ctrl-Shift-anykey?

How can I get my Terminal to recognise Ctrl-Shift-anykey?

推荐答案

没有通过 tty 传输修饰键的标准;但是,xterm 定义了一个方法,并且其他一些终端仿真器支持它.终端不直接支持这一点,但您可以自定义终端的键盘首选项以将其他一些键映射到 emacs 识别的序列:

There is no standard for transmitting modifier keys through a tty; however, xterm defines a method, and some other terminal emulators support it. Terminal does not directly support this, but you can customize Terminal’s keyboard preferences to map some other key to the sequence that emacs recognizes:

首选项 > 设置 > [配置文件] > 键盘

Xterm 对修饰键的通用编码在 PC 风格的功能键 XTerm 控制序列 文档.

Xterm’s generalized encoding of modifier keys is described briefly at the end of the PC-Style Function Keys section of the XTerm Control Sequences documentation.

输入M-x describe-bindings RET可以看到emacs支持的序列.比如emacs识别序列

You can see the sequences that emacs supports by entering M-x describe-bindings RET. For example, emacs recognizes the sequence

M-[ 2 7 ;7 ;4 7 ~

并将其映射到

C-M-/

您可以使用此列表来发现通过 tty 与其他修饰键序列通信的类似序列.

You can use this list to discover similar sequences that communicate other modifier key sequences through a tty.

这篇关于Ctrl-Shift 键发出哔哔声且不发送到终端的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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