From: Alexander Danilov Date: 2002-02-14T22:48:53+09:00 Subject: ruby-m17n Have a nice day|night ! I want to have m17d ruby. Week ago I retrive ruby-m17n from cvs and now I want to add koi8-r russian character table to m17n.[ch]. in m17n.h I found such block #define M17N_U 01 /* Upper case */ #define M17N_L 02 /* Lower case */ #define M17N_N 04 /* Numeral (digit) */ #define M17N_S 010 /* Spacing character */ #define M17N_P 020 /* Punctuation */ #define M17N_C 040 /* Control character */ #define M17N_W 0100 /* non alpha-numeral Word character */ #define M17N_X 0200 /* heXadecimal digit */ What does M17N_W mean? What is it "non alpha-numeral word"? can you show me an example from english alphabet? I have not found such character in latin1_ctype_table[]. Is it japanes specific? I wrote a program to generate koi8r_ctype_table. I think it can be used to generate cyrillic and may be latin character table if your locale setup correctly my locale is LANG=ru_RU.KOI8-R LC_CTYPE=ru_RU.KOI8-R LC_NUMERIC=ru_RU.KOI8-R LC_TIME=ru_RU.KOI8-R LC_COLLATE=ru_RU.KOI8-R LC_MONETARY=ru_RU.KOI8-R LC_MESSAGES=ru_RU.KOI8-R LC_ALL= program was written in linux debian potato and wasn't tested at other platform. #include #include #include int main(int argc, char **argv){ int i,v; setlocale(LC_ALL,""); for(i=0; i<=255; i++){ v = 0; if( isupper(i) ){ v |= 0001; } if( islower(i) ){ v |= 0002; } if( isdigit(i) ){ v |= 0004; } if( isspace(i) ){ v |= 0010; } if( ispunct(i) ){ v |= 0020; } if( iscntrl(i) ){ v |= 0040; } if( isxdigit(i) ){ v |= 0200; } printf("%0004o",v); if(i<255) putchar(','); if( (i+1) % 8 ) putchar(' '); else printf("\n"); } } result 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0050, 0050, 0050, 0050, 0050, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0040, 0010, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0204, 0204, 0204, 0204, 0204, 0204, 0204, 0204, 0204, 0204, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0201, 0201, 0201, 0201, 0201, 0201, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0020, 0020, 0020, 0020, 0020, 0020, 0202, 0202, 0202, 0202, 0202, 0202, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0020, 0020, 0020, 0020, 0040, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0010, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0002, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0001, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0020, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0002, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001, 0001 it's for koi8-r