I had the same problem on Linux Mint 13 and the same output on xev, namely Control_l + f
was mapped to Control_l
.
My solution:
I remembered that I have xbindkeys running to enable some exotic buttons on my tablet pc.
By running xbindkeys-config and checking all key mappings defined for xbindkeys I found an entry that interfered with CTRL-F
.
After deleting the offending mapping and saving the new settings, CTRL-F
works again and correctly launches the search dialog in gedit, firefox, ...
The terminal emulator translates events like “the Tab key was pressed” into sequences of characters that the application running in the terminal (bash, in your case) reads. See How do keyboard input and text output work? for a more detailed presentation of this topic.
For historical reasons, a few of keys send a character that's the same as pressing Ctrl with some other character: Tab = Ctrl+I, Return = Ctrl+M, Esc = Ctrl+[. This is because historical physical terminals did this, so applications that run in terminals expect it, so terminals do it.
Both Guake and Gnome-terminal use the VTE library, which does not allow the mapping from key chords to character sequences to be configured. You have the same problem as bash - wrong key sequence bindings with control+alt+space
Xterm has fully configurable key bindings. You can make the Tab key send a tab character (that's the default), or make it send the string hello
, or whatever you choose. Xterm is configured via X resources. For example, to make Tab send the escape sequence \e[t
when pressed and \e]t
when released, put this in your ~/.Xresources
:
XTerm.vt100.translations: #override \
<Key>Tab: string("\033[t") \n\
<KeyRelease>Tab: string("\033]t") \n\
Or maybe you would leave Tab sending the tab character and make Ctrl+I send something else:
XTerm.vt100.translations: #override \
Ctrl~Meta~Shift<Key>I: string("\033[a5i") \n\
Ctrl~Meta Shift<Key>I: string("\033[a6i") \n\
You can then bind \e[a5i
to whatever you want in bash and other terminal applications with configurable keybindings.
Note that by convention, multi-character escape sequences start with the escape character (often represented as \e
or \033
or \x1b
in programming languages and configuration files); some applications may have trouble with escape sequences starting with other characters, and of course you can't have a character that's both an escape sequence and a key of its own, unless you're willing to accept a timeout (that's how it works in applications such as vi where Esc on its own is bound to some functionality). If you define your own key sequences, take care not to clash with the ones sent by function and cursor keys, which are more or less de facto standardized.
Best Answer
I believe ctrl-' will not be passed to applications in the console. It also doesn't show up in xev.
It may be the input system or even PC hardware, but without trickery some of the key combinations may be impossible to detect.