[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Fwd: Why does "\024" mean `C-t'? (in bindkey example in man page)
From: |
Micah Cowan |
Subject: |
Fwd: Why does "\024" mean `C-t'? (in bindkey example in man page) |
Date: |
Mon, 15 Aug 2016 10:44:16 -0700 |
Resending; meant to send this to the list, not privately.
On Sun, Aug 14, 2016 at 7:11 AM, Aleksey Tsalolikhin
<address@hidden> wrote:
>
> Lovely, thank you very much Axel and Pieter!
>
> Why does pressing ctrl-1 make 1, and pressing ctrl-3 make ^[ ? Pressing
> ctrl-8 makes nothing, like Pieter said (you can't shift 042 down by 64).
The basic answer here is that, outside of the ASCII entries from 0x40
- 0x5F, and their lower-case equivalents, and a few pretty ubiquitous
exceptions, there's not a lot of consistency as to which characters
might also generate a character in the control range, and if so, what
character might be generated.
You may find this previous email of mine on the subject of "what does
control do", helpful:
https://lists.gnu.org/archive/html/screen-users/2015-08/msg00005.html
Also note that, outside of the terminal context - in for example an X
Window context, control key combinations really are represented as
"adding" information to the keypress you type. There's no mutation of
the key code there - it's only that way in terminals, for historical
reasons.
-mjc