--- xterm-202/button.c.orig 2005-04-22 04:21:53 +0400 +++ xterm-202/button.c 2005-06-08 15:52:10 +0400 @@ -62,6 +62,7 @@ button.c Handles button events in the te #include #include +#include #include #include @@ -2317,6 +2319,16 @@ static int charClass[256] = 48, 48, 48, 48, 48, 48, 48, 48}; /* *INDENT-ON* */ +void +init_classtab (void) +{ + int i; + + for (i = 1; i < 256; ++i) + if (isalnum (i)) + charClass[i] = '0'; +} + int SetCharacterClassRange(int low, /* in range of [0..255] */ int high, --- xterm-202/charclass.c.orig 2005-01-14 04:50:02 +0300 +++ xterm-202/charclass.c 2005-06-08 15:52:10 +0400 @@ -27,6 +27,7 @@ #include #include +#include #if OPT_WIDE_CHARS @@ -76,6 +77,7 @@ SetCharacterClassRange(int low, int high void init_classtab(void) { + int i; const int size = 50; classtab = TypeMallocN(struct classentry, size); @@ -99,6 +101,10 @@ init_classtab(void) SetCharacterClassRange(215, 215, IDENT); SetCharacterClassRange(247, 247, IDENT); + for (i = 1; i < 256; ++i) + if (isalnum (i) && CharacterClass(i) != 48) + SetCharacterClassRange(i, i, 48); + /* added Unicode classes */ SetCharacterClassRange(0x0100, 0xffdf, ALNUM); /* mostly characters */ SetCharacterClassRange(0x037e, 0x037e, IDENT); /* Greek question mark */ --- xterm-202/main.c.orig 2005-06-08 15:52:10 +0400 +++ xterm-202/main.c 2005-06-08 15:52:10 +0400 @@ -2071,10 +2071,8 @@ main(int argc, char *argv[]ENVP_ARG) XtSetValues(toplevel, ourTopLevelShellArgs, number_ourTopLevelShellArgs); -#if OPT_WIDE_CHARS /* seems as good a place as any */ init_classtab(); -#endif /* Parse the rest of the command line */ TRACE_ARGV("After XtOpenApplication", argv);