diff options
Diffstat (limited to 'chinese/irssi/files/patch-src::fe-text::gui-readline.c')
-rw-r--r-- | chinese/irssi/files/patch-src::fe-text::gui-readline.c | 53 |
1 files changed, 26 insertions, 27 deletions
diff --git a/chinese/irssi/files/patch-src::fe-text::gui-readline.c b/chinese/irssi/files/patch-src::fe-text::gui-readline.c index 5b514efc4cf8..29bf1948fd10 100644 --- a/chinese/irssi/files/patch-src::fe-text::gui-readline.c +++ b/chinese/irssi/files/patch-src::fe-text::gui-readline.c @@ -1,39 +1,38 @@ ---- src/fe-text/gui-readline.c.orig Mon Nov 11 15:00:02 2002 -+++ src/fe-text/gui-readline.c Tue Apr 1 09:47:02 2003 -@@ -50,6 +50,10 @@ +--- src/fe-text/gui-readline.c.orig Sun Nov 23 20:30:02 2003 ++++ src/fe-text/gui-readline.c Sun Dec 7 16:35:50 2003 +@@ -53,6 +53,9 @@ static ENTRY_REDIRECT_REC *redir; static int escape_next_key; +static int big5high = FALSE; +static unichar prekey = '\0'; + -+ static int readtag; - static time_t idle_time; - -@@ -148,7 +152,25 @@ - - idle_time = time(NULL); + static unichar prev_key; + static GTimeVal last_keypress; +@@ -339,7 +342,25 @@ + return; + } - if (key < 32) { -+ if(big5high || is_big5_hi(key)) -+ { -+ if(big5high) -+ { -+ big5high = FALSE; -+ str[0] = prekey; -+ str[1] = key; -+ str[2] = '\0'; -+ gui_entry_insert_text(active_entry, str); -+ return; -+ } -+ else -+ { -+ big5high = TRUE; -+ prekey = key; -+ return; -+ } -+ } ++ if(big5high || is_big5_hi(key)) ++ { ++ if(big5high) ++ { ++ big5high = FALSE; ++ str[0] = prekey; ++ str[1] = key; ++ str[2] = '\0'; ++ gui_entry_insert_text(active_entry, str); ++ return; ++ } ++ else ++ { ++ big5high = TRUE; ++ prekey = key; ++ return; ++ } ++ } + else if (key < 32) { /* control key */ str[0] = '^'; |