diff options
author | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-07-05 15:19:36 +0000 |
---|---|---|
committer | naruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-07-05 15:19:36 +0000 |
commit | 26f0a39bb33c3bc14f35dca12403cfd3cea089e7 (patch) | |
tree | 23d7231c0939965c0921828bf7d1463ba54c10f7 /ext/nkf/nkf-utf8/config.h | |
parent | 1980223eaa5562ca3ae409b516c30a630aae3f2f (diff) |
* ext/nkf/nkf-utf8/{nkf.c,utf8tbl.c,config.h}:
imported nkf.c 1.70 (support UTF-8-MAC)
* ext/nkf/lib/kconv.rb: add :utf8mac and :internalunicode
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@8729 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/nkf/nkf-utf8/config.h')
-rw-r--r-- | ext/nkf/nkf-utf8/config.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/ext/nkf/nkf-utf8/config.h b/ext/nkf/nkf-utf8/config.h index 2619440bf9..e46fe95a44 100644 --- a/ext/nkf/nkf-utf8/config.h +++ b/ext/nkf/nkf-utf8/config.h @@ -43,6 +43,10 @@ */ /* #define INT_IS_SHORT */ +/* Unicode Normalization */ +#define UNICODE_NORMALIZATION + +#ifndef WIN32DLL /******************************/ /* $B%G%U%)%k%H$N=PNO%3!<%IA*Br(B */ /* Select DEFAULT_CODE */ @@ -51,5 +55,20 @@ /* #define DEFAULT_CODE_EUC */ /* #define DEFAULT_CODE_UTF8 */ /******************************/ +#else +#define DEFAULT_CODE_SJIS +#endif + +#if defined(UTF8_INPUT_ENABLE) && defined(UNICODE_NORMALIZATION) +#define NORMALIZATION_TABLE_LENGTH 942 +#define NORMALIZATION_TABLE_NFC_LENGTH 3 +#define NORMALIZATION_TABLE_NFD_LENGTH 9 +struct normalization_pair{ + int nfc[NORMALIZATION_TABLE_NFC_LENGTH]; + int nfd[NORMALIZATION_TABLE_NFD_LENGTH]; +}; +#else +#undef UNICODE_NORMALIZATION +#endif #endif /* _CONFIG_H_ */ |