Created
November 16, 2010 18:10
-
-
Save graywh/702193 to your computer and use it in GitHub Desktop.
fix irssi's key bindings
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Remove hack for binding ^ that prevents binding ctrl-^ | |
--- irssi-0.8.15.orig/src/fe-text/gui-readline.c | |
+++ irssi-0.8.15/src/fe-text/gui-readline.c | |
@@ -392,12 +392,6 @@ | |
str[g_unichar_to_utf8(key, str)] = '\0'; | |
} | |
- if (strcmp(str, "^") == 0) { | |
- /* change it as ^^ */ | |
- str[1] = '^'; | |
- str[2] = '\0'; | |
- } | |
- | |
if (escape_next_key) { | |
escape_next_key = FALSE; | |
gui_entry_insert_char(active_entry, key); | |
@@ -962,7 +956,6 @@ | |
key_bind("key", NULL, " ", "space", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "^M", "return", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "^J", "return", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "^H", "backspace", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "^?", "backspace", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "^I", "tab", (SIGNAL_FUNC) key_combo); | |
@@ -970,7 +963,6 @@ | |
key_bind("key", NULL, "^[", "meta", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta-[", "meta2", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta-O", "meta2", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "meta-[O", "meta2", (SIGNAL_FUNC) key_combo); | |
/* arrow keys */ | |
key_bind("key", NULL, "meta2-A", "up", (SIGNAL_FUNC) key_combo); | |
@@ -979,11 +971,9 @@ | |
key_bind("key", NULL, "meta2-D", "left", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-1~", "home", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "meta2-7~", "home", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-H", "home", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-4~", "end", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "meta2-8~", "end", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-F", "end", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-5~", "prior", (SIGNAL_FUNC) key_combo); | |
@@ -994,8 +984,6 @@ | |
key_bind("key", NULL, "meta2-2~", "insert", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-3~", "delete", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "meta2-d", "cleft", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "meta2-c", "cright", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-5D", "cleft", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-5C", "cright", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-1;5D", "cleft", (SIGNAL_FUNC) key_combo); | |
@@ -1005,18 +993,12 @@ | |
key_bind("key", NULL, "meta2-1;3B", "mdown", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-1;3D", "mleft", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-1;3C", "mright", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "meta-up", "mup", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "meta-down", "mdown", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "meta-left", "mleft", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "meta-right", "mright", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-1;5~", "chome", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "meta2-7;5~", "chome", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-5H", "chome", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-1;5H", "chome", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-4;5~", "cend", (SIGNAL_FUNC) key_combo); | |
- key_bind("key", NULL, "meta2-8;5~", "cend", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-5F", "cend", (SIGNAL_FUNC) key_combo); | |
key_bind("key", NULL, "meta2-1;5F", "cend", (SIGNAL_FUNC) key_combo); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apt-get install build-essential | |
apt-get build-dep irssi | |
apt-get source irssi | |
cd irssi-{version} | |
wget {this file} -O debian/patches/99bindings.patch | |
echo "99bindings.patch" >> debian/patches/series | |
editor debian/changelog | |
dpkg-buildpackage |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment