xterm has a
modifyOtherKeys option that tells it to construct an escape sequence for various key combinations that are normally not available. That option can be enabled in
.Xdefaults, or with a control sequence from within the terminal (
echo -n -e '\033[>4;1m' does the trick for me).
This option allows for more key combinations to be bound to commands in text mode programs, e.g. in Emacs. For example
Ctrl + ') will normally generate a single
' character, which is useless, but will turn into a complex - but usable - escape sequence when the
modifyOtherKeys option is enabled.
gnome-terminal have a similar ability? I could not find anything in the menus on my system (Mageia Linux 4, gnome-terminal-3.10.2), but perhaps there is some control sequence with the same effect?