unmappable keys / missing generic key-remapping method
Submitted by samo
Link to original bug (#375652)
Description
using libvte, i cannot in any way get ctrl-home and ctrl-end or ctrl-tab through to the shell inside (and have them different from plain home/end/tab).
- there's no libXt so one cannot use Xresource/xrdb translation, like xterm
- gtkrc binding does not work as u override key-press which is not accessible from there - only things like gtkTextEntry's insert-at-cursor
so the last resort left is to hack the source - but IMO this is not good style.
- the way of checking keymap/entries does not allow to have ctrl-home mapping auto-produced from home's one in same way as ctrl-F5 from F5 is.
- so here a patch: but this is using my own mappings... hardcoded.
IMO linking (optionaly) a libXt (or whatever) and having vte*translation: entry as X-resource will be easiest to do without breaking anything. All else doesn't seem any good. Or maybe gtk stuff but i dont really think so.
--- org/vte-0.14.1/src/keymap.c 2006-08-31 22:56:44.000000000 +0300 +++ src/keymap.c 2006-11-15 20:50:08.000000000 +0200 @@ -123,6 +123,8 @@ /* Alt+Tab = Esc+Tab */ {cursor_all, keypad_all, fkey_all, VTE_META_MASK, _VTE_CAP_ESC "\t", -1, X_NULL},
- //ctrl-tab
- {cursor_all, keypad_all, fkey_all, GDK_CONTROL_MASK, _VTE_CAP_ESC "{t", -1, X_NULL}, /* Regular tab. */ {cursor_all, keypad_all, fkey_all, 0, X_NULL, 0, "ta"}, @@ -208,14 +210,17 @@ static const struct _vte_keymap_entry _vte_keymap_GDK_Home[] = {
- {cursor_all, keypad_all, fkey_all, GDK_CONTROL_MASK, _VTE_CAP_ESC "{h", -1, X_NULL}, {cursor_all, keypad_all, fkey_all, 0, X_NULL, 0, "kh"}, {cursor_all, keypad_all, fkey_vt220, 0, _VTE_CAP_CSI "1~", -1, X_NULL}, {cursor_all, keypad_all, fkey_hp, 0, _VTE_CAP_ESC "h", -1, X_NULL}, {cursor_all, keypad_all, fkey_nothpvt, 0, X_NULL, 0, "kh"}, {cursor_all, keypad_all, fkey_all, 0, X_NULL, 0, X_NULL}, };
static const struct _vte_keymap_entry _vte_keymap_GDK_End[] = {
- {cursor_all, keypad_all, fkey_all, GDK_CONTROL_MASK, _VTE_CAP_ESC "{e", -1, X_NULL}, {cursor_all, keypad_all, fkey_all, 0, X_NULL, 0, "@7"}, {cursor_all, keypad_all, fkey_vt220, 0, _VTE_CAP_CSI "4~", -1, X_NULL}, {cursor_all, keypad_all, fkey_notvt220, 0, X_NULL, 0, "@7"},