-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
386 additions
and
371 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,86 +1,51 @@ | ||
#ifndef _CONFIG_H_ | ||
#define _CONFIG_H_ | ||
|
||
/* UTF8 $BF~=PNO(B */ | ||
/* UTF8 input and output */ | ||
#define UTF8_INPUT_ENABLE | ||
#define UTF8_OUTPUT_ENABLE | ||
|
||
/* Shift_JIS $BHO0O30$NJ8;z$r!"(BCP932 $B$GF1CM$JJ8;z$KFI$_49$($k(B */ | ||
/* invert characters invalid in Shift_JIS to CP932 */ | ||
#define SHIFTJIS_CP932 | ||
|
||
/* $B%*%W%7%g%s$GF~NO$r;XDj$7$?;~$K!"J8;z%3!<%I$r8GDj$9$k(B */ | ||
/* fix input encoding when given by option */ | ||
#define INPUT_CODE_FIX | ||
|
||
/* --overwrite $B%*%W%7%g%s(B */ | ||
/* --overwrite option */ | ||
/* by Satoru Takabayashi <[email protected]> */ | ||
#define OVERWRITE | ||
|
||
/* --cap-input, --url-input $B%*%W%7%g%s(B */ | ||
/* --cap-input, --url-input option */ | ||
#define INPUT_OPTION | ||
|
||
/* --numchar-input $B%*%W%7%g%s(B */ | ||
/* --numchar-input option */ | ||
#define NUMCHAR_OPTION | ||
|
||
/* --debug, --no-output $B%*%W%7%g%s(B */ | ||
/* --debug, --no-output option */ | ||
#define CHECK_OPTION | ||
|
||
/* JIS X0212 */ | ||
#define X0212_ENABLE | ||
|
||
/* --exec-in, --exec-out $B%*%W%7%g%s(B | ||
* pipe, fork, execvp $B$"$?$j$,L5$$$HF0$-$^$;$s!#(B | ||
* MS-DOS, MinGW $B$J$I$G$O(B undef $B$K$7$F$/$@$5$$(B | ||
* child process $B=*N;;~$N=hM}$,$$$$$+$2$s$J$N$G!"(B | ||
* $B%G%U%)%k%H$GL58z$K$7$F$$$^$9!#(B | ||
/* --exec-in, --exec-out option | ||
* require pipe, fork, execvp and so on. | ||
* please undef this on MS-DOS, MinGW | ||
* this is still buggy arround child process | ||
*/ | ||
/* #define EXEC_IO */ | ||
|
||
/* SunOS $B$N(B cc $B$r;H$&$H$-$O(B undef $B$K$7$F$/$@$5$$(B */ | ||
#define ANSI_C_PROTOTYPE | ||
|
||
/* int $B$,(B 32bit $BL$K~$N4D6-$G(B NUMCHAR_OPTION $B$r;H$&$K$O!"(B | ||
* $B%3%a%s%H$r30$7$F$/$@$5$$!#(B | ||
*/ | ||
/* #define INT_IS_SHORT */ | ||
|
||
|
||
#if defined(INT_IS_SHORT) | ||
typedef long nkf_char; | ||
typedef unsigned char nkf_nfchar; | ||
#else | ||
typedef int nkf_char; | ||
typedef int nkf_nfchar; | ||
#endif | ||
|
||
/* Unicode Normalization */ | ||
#define UNICODE_NORMALIZATION | ||
|
||
#ifndef WIN32DLL | ||
/******************************/ | ||
/* $B%G%U%)%k%H$N=PNO%3!<%IA*Br(B */ | ||
/* Select DEFAULT_CODE */ | ||
/* #define DEFAULT_CODE_JIS */ | ||
/* #define DEFAULT_CODE_SJIS */ | ||
/* #define DEFAULT_CODE_EUC */ | ||
/* #define DEFAULT_CODE_UTF8 */ | ||
/******************************/ | ||
#endif | ||
|
||
#if defined(NUMCHAR_OPTION) && !defined(UTF8_INPUT_ENABLE) | ||
#define UTF8_INPUT_ENABLE | ||
#endif | ||
/* | ||
* Select Default Output Encoding | ||
* | ||
* If not defined, locale encoding is used. | ||
*/ | ||
|
||
#ifdef UNICODE_NORMALIZATION | ||
#ifndef UTF8_INPUT_ENABLE | ||
#define UTF8_INPUT_ENABLE | ||
#endif | ||
#define NORMALIZATION_TABLE_LENGTH 942 | ||
#define NORMALIZATION_TABLE_NFC_LENGTH 3 | ||
#define NORMALIZATION_TABLE_NFD_LENGTH 9 | ||
struct normalization_pair{ | ||
const nkf_nfchar nfc[NORMALIZATION_TABLE_NFC_LENGTH]; | ||
const nkf_nfchar nfd[NORMALIZATION_TABLE_NFD_LENGTH]; | ||
}; | ||
#endif | ||
/* #define DEFAULT_CODE_JIS */ | ||
/* #define DEFAULT_CODE_SJIS */ | ||
/* #define DEFAULT_CODE_EUC */ | ||
/* #define DEFAULT_CODE_UTF8 */ | ||
|
||
#endif /* _CONFIG_H_ */ |
Oops, something went wrong.