显示按键等信息

在 Linux 系统中捕捉并显示按键等信息。

xevprint contents of X events

Xev creates a window and then asks the X server to send it events whenever anything happens to the window (such as it being moved, resized, typed in, clicked in, etc.). You can also attach it to an existing window. It is useful for seeing what causes events to occur and to display the information that they contain; it is essentially a debugging and development tool, and should not be needed in normal usage.
——General Commands Manual

showkeyexamine the codes sent by the keyboard

showkey prints to standard output either the scan codes or the keycode or the ASCII code of each key pressed. In the first two modes the program runs until 10 seconds have elapsed since the last key press or release event, or until it receives a suitable signal, like SIGTERM, from another process. In ASCII mode the program terminates when the user types ^D.
——General Commands Manual

直接使用 showkey 命令可能会得到 Couldn't get a file descriptor referring to the console. 的错误信息,可使用 showkey -a 解决。

Enter any child page of Series.

CTRL-/