diff --git a/Versions/build.txt b/Versions/build.txt index 712cd79a3..49e657f97 100644 --- a/Versions/build.txt +++ b/Versions/build.txt @@ -1 +1 @@ -1650 +1651 diff --git a/language/common_res.h b/language/common_res.h index 71a66c3e8..b49f781c6 100644 --- a/language/common_res.h +++ b/language/common_res.h @@ -327,49 +327,50 @@ #define CMD_RECODEDEFAULT 20010 #define CMD_RECODEANSI 20011 #define CMD_RECODEOEM 20012 -#define CMD_RELOADASCIIASUTF8 20013 -#define CMD_RELOADFORCEDETECTION 20014 -#define CMD_RELOADNOFILEVARS 20015 -#define CMD_LEXDEFAULT 20016 -#define CMD_LEXHTML 20017 -#define CMD_LEXXML 20018 -#define CMD_TIMESTAMPS 20019 -#define CMD_WEBACTION1 20020 -#define CMD_WEBACTION2 20021 -#define CMD_FINDNEXTSEL 20022 -#define CMD_FINDPREVSEL 20023 -#define CMD_INCLINELIMIT 20024 -#define CMD_DECLINELIMIT 20025 -#define CMD_STRINGIFY 20026 -#define CMD_STRINGIFY2 20027 -#define CMD_EMBRACE 20028 -#define CMD_EMBRACE2 20029 -#define CMD_EMBRACE3 20030 -#define CMD_EMBRACE4 20031 -#define CMD_INCREASENUM 20032 -#define CMD_DECREASENUM 20033 -#define CMD_TOGGLETITLE 20034 -#define CMD_JUMP2SELSTART 20035 -#define CMD_JUMP2SELEND 20036 -#define CMD_COPYPATHNAME 20037 -#define CMD_COPYWINPOS 20038 -#define CMD_INITIALWINPOS 20039 -#define CMD_OPENINIFILE 20040 -#define CMD_CTRLENTER 20041 -#define CMD_OPEN_HYPERLINK 20042 -#define CMD_ALTUP 20043 -#define CMD_ALTDOWN 20044 -#define CMD_ALTLEFT 20045 -#define CMD_ALTRIGHT 20046 -#define CMD_TAB 20047 -#define CMD_BACKTAB 20048 -#define CMD_VK_INSERT 20049 -#define CMD_FULLSCRWINPOS 20050 -#define CMD_DEFAULTWINPOS 20051 -#define CMD_SAVEASDEFWINPOS 20052 -#define CMD_CLEARSAVEDWINPOS 20053 -//#define CMD_LEFT 20054 -//#define CMD_RIGHT 20055 +#define CMD_RECODEGB18030 20013 +#define CMD_RELOADASCIIASUTF8 20014 +#define CMD_RELOADFORCEDETECTION 20015 +#define CMD_RELOADNOFILEVARS 20016 +#define CMD_LEXDEFAULT 20017 +#define CMD_LEXHTML 20018 +#define CMD_LEXXML 20019 +#define CMD_TIMESTAMPS 20020 +#define CMD_WEBACTION1 20021 +#define CMD_WEBACTION2 20022 +#define CMD_FINDNEXTSEL 20023 +#define CMD_FINDPREVSEL 20024 +#define CMD_INCLINELIMIT 20025 +#define CMD_DECLINELIMIT 20026 +#define CMD_STRINGIFY 20027 +#define CMD_STRINGIFY2 20028 +#define CMD_EMBRACE 20029 +#define CMD_EMBRACE2 20030 +#define CMD_EMBRACE3 20031 +#define CMD_EMBRACE4 20032 +#define CMD_INCREASENUM 20033 +#define CMD_DECREASENUM 20034 +#define CMD_TOGGLETITLE 20035 +#define CMD_JUMP2SELSTART 20036 +#define CMD_JUMP2SELEND 20037 +#define CMD_COPYPATHNAME 20038 +#define CMD_COPYWINPOS 20039 +#define CMD_INITIALWINPOS 20040 +#define CMD_OPENINIFILE 20041 +#define CMD_CTRLENTER 20042 +#define CMD_OPEN_HYPERLINK 20043 +#define CMD_ALTUP 20044 +#define CMD_ALTDOWN 20045 +#define CMD_ALTLEFT 20046 +#define CMD_ALTRIGHT 20047 +#define CMD_TAB 20048 +#define CMD_BACKTAB 20049 +#define CMD_VK_INSERT 20050 +#define CMD_FULLSCRWINPOS 20051 +#define CMD_DEFAULTWINPOS 20052 +#define CMD_SAVEASDEFWINPOS 20053 +#define CMD_CLEARSAVEDWINPOS 20054 +//#define CMD_LEFT 20055 +//#define CMD_RIGHT 20056 #define IDS_MUI_MENU_LANGUAGE 34500 #define IDS_MUI_LANG_EN_US 34501 @@ -620,69 +621,70 @@ #define IDS_ENC_ISO_8859_2 61017 #define IDS_ENC_MAC_CENTRAL_EUROP 61018 #define IDS_ENC_WIN_1250 61019 -#define IDS_ENC_GBK_2312 61020 -#define IDS_ENC_MAC_ZH_CN 61021 -#define IDS_ENC_BIG5 61022 -#define IDS_ENC_MAC_ZH_TW 61023 -#define IDS_ENC_MAC_CROATIAN 61024 -#define IDS_ENC_DOS_866 61025 -#define IDS_ENC_ISO_8859_5 61026 -#define IDS_ENC_KOI8_R 61027 -#define IDS_ENC_KOI8_U 61028 -#define IDS_ENC_MAC_CYRILLIC 61029 -#define IDS_ENC_WIN_1251 61030 -#define IDS_ENC_ISO_8859_13 61031 -#define IDS_ENC_DOS_863 61032 -#define IDS_ENC_DOS_737 61033 -#define IDS_ENC_ISO_8859_7 61034 -#define IDS_ENC_MAC_GREEK 61035 -#define IDS_ENC_WIN_1253 61036 -#define IDS_ENC_DOS_869 61037 -#define IDS_ENC_DOS_862 61038 -#define IDS_ENC_ISO_8859_8_I 61039 -#define IDS_ENC_ISO_8859_8 61040 -#define IDS_ENC_MAC_HEBREW 61041 -#define IDS_ENC_WIN_1255 61042 -#define IDS_ENC_DOS_861 61043 -#define IDS_ENC_MAC_ICELANDIC 61044 -#define IDS_ENC_MAC_JAPANESE 61045 -#define IDS_ENC_SHIFT_JIS 61046 -#define IDS_ENC_MAC_KOREAN 61047 -#define IDS_ENC_WIN_949 61048 -#define IDS_ENC_ISO_8859_3 61049 -#define IDS_ENC_ISO_8859_15 61050 -#define IDS_ENC_DOS_865 61051 -#define IDS_ENC_DOS_437 61052 -#define IDS_ENC_DOS_858 61053 -#define IDS_ENC_DOS_860 61054 -#define IDS_ENC_MAC_ROMANIAN 61055 -#define IDS_ENC_MAC_THAI 61056 -#define IDS_ENC_WIN_874 61057 -#define IDS_ENC_DOS_857 61058 -#define IDS_ENC_ISO_8859_9 61059 -#define IDS_ENC_MAC_TURKISH 61060 -#define IDS_ENC_WIN_1254 61061 -#define IDS_ENC_MAC_UKRAINIAN 61062 -#define IDS_ENC_WIN_1258 61063 -#define IDS_ENC_DOS_850 61064 -#define IDS_ENC_ISO_8859_1 61065 -#define IDS_ENC_MAC_WESTERN_EUROP 61066 -#define IDS_ENC_WIN_1252 61067 -#define IDS_ENC_IBM_EBCDIC_US 61068 -#define IDS_ENC_IBM_EBCDIC_INT 61069 -#define IDS_ENC_IBM_EBCDIC_GR 61070 -#define IDS_ENC_IBM_EBCDIC_LAT_5 61071 -#define IDS_ENC_GB18030 61072 -#define IDS_ENC_EUC_JAPANESE 61073 -#define IDS_ENC_EUC_KOREAN 61074 -#define IDS_ENC_ISO_2022_CN 61075 -#define IDS_ENC_HZ_GB2312 61076 -#define IDS_ENC_ISO_2022_JP 61077 -#define IDS_ENC_ISO_2022_KR 61078 -#define IDS_ENC_X_CHINESE_CNS 61079 -#define IDS_ENC_JOHAB 61080 -#define IDS_ENC_ISO_8859_10 61081 -#define IDS_ENC_BIG5_HKSCS 61082 +#define IDS_ENC_GB18030 61020 +#define IDS_ENC_GBK_936 61021 +#define IDS_ENC_GB2312_80 61022 +#define IDS_ENC_MAC_ZH_CN 61023 +#define IDS_ENC_BIG5 61024 +#define IDS_ENC_MAC_ZH_TW 61025 +#define IDS_ENC_MAC_CROATIAN 61026 +#define IDS_ENC_DOS_866 61027 +#define IDS_ENC_ISO_8859_5 61028 +#define IDS_ENC_KOI8_R 61029 +#define IDS_ENC_KOI8_U 61030 +#define IDS_ENC_MAC_CYRILLIC 61031 +#define IDS_ENC_WIN_1251 61032 +#define IDS_ENC_ISO_8859_13 61033 +#define IDS_ENC_DOS_863 61034 +#define IDS_ENC_DOS_737 61035 +#define IDS_ENC_ISO_8859_7 61036 +#define IDS_ENC_MAC_GREEK 61037 +#define IDS_ENC_WIN_1253 61038 +#define IDS_ENC_DOS_869 61039 +#define IDS_ENC_DOS_862 61040 +#define IDS_ENC_ISO_8859_8_I 61041 +#define IDS_ENC_ISO_8859_8 61042 +#define IDS_ENC_MAC_HEBREW 61043 +#define IDS_ENC_WIN_1255 61044 +#define IDS_ENC_DOS_861 61045 +#define IDS_ENC_MAC_ICELANDIC 61046 +#define IDS_ENC_MAC_JAPANESE 61047 +#define IDS_ENC_SHIFT_JIS 61048 +#define IDS_ENC_MAC_KOREAN 61049 +#define IDS_ENC_WIN_949 61050 +#define IDS_ENC_ISO_8859_3 61051 +#define IDS_ENC_ISO_8859_15 61052 +#define IDS_ENC_DOS_865 61053 +#define IDS_ENC_DOS_437 61054 +#define IDS_ENC_DOS_858 61055 +#define IDS_ENC_DOS_860 61056 +#define IDS_ENC_MAC_ROMANIAN 61057 +#define IDS_ENC_MAC_THAI 61058 +#define IDS_ENC_WIN_874 61059 +#define IDS_ENC_DOS_857 61060 +#define IDS_ENC_ISO_8859_9 61061 +#define IDS_ENC_MAC_TURKISH 61062 +#define IDS_ENC_WIN_1254 61063 +#define IDS_ENC_MAC_UKRAINIAN 61064 +#define IDS_ENC_WIN_1258 61065 +#define IDS_ENC_DOS_850 61066 +#define IDS_ENC_ISO_8859_1 61067 +#define IDS_ENC_MAC_WESTERN_EUROP 61068 +#define IDS_ENC_WIN_1252 61069 +#define IDS_ENC_IBM_EBCDIC_US 61070 +#define IDS_ENC_IBM_EBCDIC_INT 61071 +#define IDS_ENC_IBM_EBCDIC_GR 61072 +#define IDS_ENC_IBM_EBCDIC_LAT_5 61073 +#define IDS_ENC_EUC_JAPANESE 61074 +#define IDS_ENC_EUC_KOREAN 61075 +#define IDS_ENC_ISO_2022_CN 61076 +#define IDS_ENC_HZ_GB2312 61077 +#define IDS_ENC_ISO_2022_JP 61078 +#define IDS_ENC_ISO_2022_KR 61079 +#define IDS_ENC_X_CHINESE_CNS 61080 +#define IDS_ENC_JOHAB 61081 +#define IDS_ENC_ISO_8859_10 61082 +#define IDS_ENC_BIG5_HKSCS 61083 #define IDS_EOL_WIN 62000 #define IDS_EOL_MAC 62001 diff --git a/language/np3_af_za/encode_af_za.rc b/language/np3_af_za/encode_af_za.rc index 76e40cb36..4c7dc61bf 100644 --- a/language/np3_af_za/encode_af_za.rc +++ b/language/np3_af_za/encode_af_za.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -146,7 +148,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_af_za/menu_af_za.rc b/language/np3_af_za/menu_af_za.rc index a6e0f3158..026c68b11 100644 --- a/language/np3_af_za/menu_af_za.rc +++ b/language/np3_af_za/menu_af_za.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 with &Signature", IDM_ENCODING_UTF8SIGN MENUITEM "&Meer...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "Force Kompakte Enkodering Opsporing", CMD_RELOADFORCEDETECTION + MENUITEM "Force Enkodering Opsporing", CMD_RELOADFORCEDETECTION MENUITEM SEPARATOR MENUITEM "Hercodeer na &Standaard\tCtrl-Alt-F", CMD_RECODEDEFAULT MENUITEM "Hercodeer na &ANSI\tCtrl-Shift+A", CMD_RECODEANSI MENUITEM "Hercodeer na &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 + MENUITEM SEPARATOR MENUITEM "ASCII as UTF-&8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "Ignoreer Kodering &Tags\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "&Herkodeer...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_be_by/encode_be_by.rc b/language/np3_be_by/encode_be_by.rc index a97fca1c1..31c759f22 100644 --- a/language/np3_be_by/encode_be_by.rc +++ b/language/np3_be_by/encode_be_by.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -147,7 +149,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_be_by/menu_be_by.rc b/language/np3_be_by/menu_be_by.rc index 4f08265f7..d6b65b629 100644 --- a/language/np3_be_by/menu_be_by.rc +++ b/language/np3_be_by/menu_be_by.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 BO&M", IDM_ENCODING_UTF8SIGN MENUITEM "&...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM " ", CMD_RELOADFORCEDETECTION + MENUITEM " ", CMD_RELOADFORCEDETECTION MENUITEM SEPARATOR MENUITEM " &\tCtrl-Alt-F", CMD_RECODEDEFAULT - MENUITEM " A&NSI\tCtrl-Shift+A", CMD_RECODEANSI - MENUITEM " &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM " A&NSI\tCtrl-Shift+A", CMD_RECODEANSI + MENUITEM " &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 + MENUITEM SEPARATOR MENUITEM " ASCII & UTF-8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM " & \tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "& ...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_de_de/encode_de_de.rc b/language/np3_de_de/encode_de_de.rc index fe93b2295..70bb1b2e7 100644 --- a/language/np3_de_de/encode_de_de.rc +++ b/language/np3_de_de/encode_de_de.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -146,7 +148,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_de_de/menu_de_de.rc b/language/np3_de_de/menu_de_de.rc index 1e5f83df8..14e03f580 100644 --- a/language/np3_de_de/menu_de_de.rc +++ b/language/np3_de_de/menu_de_de.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 mit &Signatur", IDM_ENCODING_UTF8SIGN MENUITEM "&Mehr Codierungen...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "Force Compact Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM "Erzwinge Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM SEPARATOR + MENUITEM "Recodiere als &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT + MENUITEM "Recodiere als &ANSI\tCtrl-Shift+A", CMD_RECODEANSI + MENUITEM "Recodiere als &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recodiere als &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 MENUITEM SEPARATOR - MENUITEM "Recodiere als &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT - MENUITEM "Recodiere als &ANSI\tCtrl-Shift+A", CMD_RECODEANSI - MENUITEM "Recodiere als &OEM\tCtrl+Shift+O", CMD_RECODEOEM MENUITEM "ASCII als UTF-&8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "Ignoriere Codierungs &Tags\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "&Re-Codierung...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_en_gb/encode_en_gb.rc b/language/np3_en_gb/encode_en_gb.rc index 0e02d15eb..90609edc6 100644 --- a/language/np3_en_gb/encode_en_gb.rc +++ b/language/np3_en_gb/encode_en_gb.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -146,7 +148,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_en_gb/menu_en_gb.rc b/language/np3_en_gb/menu_en_gb.rc index 12092e7a7..ecabecc16 100644 --- a/language/np3_en_gb/menu_en_gb.rc +++ b/language/np3_en_gb/menu_en_gb.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 with &Signature", IDM_ENCODING_UTF8SIGN MENUITEM "&More...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "Force Compact Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM "Force Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM SEPARATOR + MENUITEM "Recode to &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT + MENUITEM "Recode to &ANSI\tCtrl-Shift+A", CMD_RECODEANSI + MENUITEM "Recode to &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 MENUITEM SEPARATOR - MENUITEM "Recode to &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT - MENUITEM "Recode to &ANSI\tCtrl-Shift+A", CMD_RECODEANSI - MENUITEM "Recode to &OEM\tCtrl+Shift+O", CMD_RECODEOEM MENUITEM "ASCII as UTF-&8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "Ignore Encoding &Tags\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "&Recode...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_en_us/encode_en_us.rc b/language/np3_en_us/encode_en_us.rc index 569284ad8..43be52be5 100644 --- a/language/np3_en_us/encode_en_us.rc +++ b/language/np3_en_us/encode_en_us.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -146,7 +148,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_en_us/menu_en_us.rc b/language/np3_en_us/menu_en_us.rc index a16ae001f..cacb4a7b5 100644 --- a/language/np3_en_us/menu_en_us.rc +++ b/language/np3_en_us/menu_en_us.rc @@ -88,14 +88,16 @@ BEGIN MENUITEM "UTF-8 with &Signature", IDM_ENCODING_UTF8SIGN MENUITEM "&More...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "Force Compact Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM "Force Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM SEPARATOR + MENUITEM "Recode to &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT + MENUITEM "Recode to &ANSI\tCtrl-Shift+A", CMD_RECODEANSI + MENUITEM "Recode to &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 MENUITEM SEPARATOR - MENUITEM "Recode to &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT - MENUITEM "Recode to &ANSI\tCtrl-Shift+A", CMD_RECODEANSI - MENUITEM "Recode to &OEM\tCtrl+Shift+O", CMD_RECODEOEM MENUITEM "ASCII as UTF-&8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 - MENUITEM "Ignore Encoding &Tags\tAlt+F8", CMD_RELOADNOFILEVARS - MENUITEM "&Recode...\tF8", IDM_ENCODING_RECODE + MENUITEM "Ignore Encoding &Tags\tAlt+F8", CMD_RELOADNOFILEVARS + MENUITEM "&Recode...\tF8", IDM_ENCODING_RECODE MENUITEM SEPARATOR MENUITEM "Set &Default...", IDM_ENCODING_SETDEFAULT END diff --git a/language/np3_es_es/encode_es_es.rc b/language/np3_es_es/encode_es_es.rc index ecf3ddcf2..834979697 100644 --- a/language/np3_es_es/encode_es_es.rc +++ b/language/np3_es_es/encode_es_es.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -146,7 +148,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_es_es/menu_es_es.rc b/language/np3_es_es/menu_es_es.rc index e99d9c058..7b217b2dd 100644 --- a/language/np3_es_es/menu_es_es.rc +++ b/language/np3_es_es/menu_es_es.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 con &signatura", IDM_ENCODING_UTF8SIGN MENUITEM "&Ms...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "Forzar la deteccin de codificacin compacta", CMD_RELOADFORCEDETECTION + MENUITEM "Forzar la Deteccin de Codificacin", CMD_RELOADFORCEDETECTION MENUITEM SEPARATOR MENUITEM "Recodificar a &Defecto\tCtrl-Alt-F", CMD_RECODEDEFAULT MENUITEM "Recodificar a &ANSI\tCtrl-Shift+A", CMD_RECODEANSI MENUITEM "Recodificar a &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 + MENUITEM SEPARATOR MENUITEM "ASCII como UTF-&8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "Ignorar Codificacin &Tags\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "&Recodificar...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_fr_fr/encode_fr_fr.rc b/language/np3_fr_fr/encode_fr_fr.rc index de904a661..467823a23 100644 --- a/language/np3_fr_fr/encode_fr_fr.rc +++ b/language/np3_fr_fr/encode_fr_fr.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -146,7 +148,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_fr_fr/menu_fr_fr.rc b/language/np3_fr_fr/menu_fr_fr.rc index 5c50257d2..f2b23d3c7 100644 --- a/language/np3_fr_fr/menu_fr_fr.rc +++ b/language/np3_fr_fr/menu_fr_fr.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 avec &Signature", IDM_ENCODING_UTF8SIGN MENUITEM "&Plus...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "Forcer la dtection d'encodage compact", CMD_RELOADFORCEDETECTION + MENUITEM "Forcer la dtection d'encodage", CMD_RELOADFORCEDETECTION + MENUITEM SEPARATOR + MENUITEM "Rencoder vers &Dfaut\tCtrl-Alt-F", CMD_RECODEDEFAULT + MENUITEM "Rencoder vers &ANSI\tCtrl-Shift+A", CMD_RECODEANSI + MENUITEM "Rencoder vers &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Rencoder vers &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 MENUITEM SEPARATOR - MENUITEM "Rencoder vers &Dfaut\tCtrl-Alt-F", CMD_RECODEDEFAULT - MENUITEM "Rencoder vers &ANSI\tCtrl-Shift+A", CMD_RECODEANSI - MENUITEM "Rencoder vers &OEM\tCtrl+Shift+O", CMD_RECODEOEM MENUITEM "ASCII comme UTF-&8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "Ignorer Encodage &Tags\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "&Rencoder...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_hu_hu/encode_hu_hu.rc b/language/np3_hu_hu/encode_hu_hu.rc index 1c15c1856..95c812a4f 100644 --- a/language/np3_hu_hu/encode_hu_hu.rc +++ b/language/np3_hu_hu/encode_hu_hu.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -147,7 +149,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_hu_hu/menu_hu_hu.rc b/language/np3_hu_hu/menu_hu_hu.rc index ed6752fa0..932c7ce99 100644 --- a/language/np3_hu_hu/menu_hu_hu.rc +++ b/language/np3_hu_hu/menu_hu_hu.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 with &Signature", IDM_ENCODING_UTF8SIGN MENUITEM "&More...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "Force Compact Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM "Force Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM SEPARATOR + MENUITEM "Recode to &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT + MENUITEM "Recode to &ANSI\tCtrl-Shift+A", CMD_RECODEANSI + MENUITEM "Recode to &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 MENUITEM SEPARATOR - MENUITEM "Recode to &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT - MENUITEM "Recode to &ANSI\tCtrl-Shift+A", CMD_RECODEANSI - MENUITEM "Recode to &OEM\tCtrl+Shift+O", CMD_RECODEOEM MENUITEM "ASCII as UTF-&8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "Ignore Encoding &Tags\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "&Recode...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_it_it/encode_it_it.rc b/language/np3_it_it/encode_it_it.rc index 07141a4ae..67aa5f4e7 100644 --- a/language/np3_it_it/encode_it_it.rc +++ b/language/np3_it_it/encode_it_it.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -146,7 +148,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_it_it/menu_it_it.rc b/language/np3_it_it/menu_it_it.rc index dd54cb6c8..d82a6c23c 100644 --- a/language/np3_it_it/menu_it_it.rc +++ b/language/np3_it_it/menu_it_it.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 with &Signature", IDM_ENCODING_UTF8SIGN MENUITEM "&More...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "Force Compact Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM "Force Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM SEPARATOR + MENUITEM "Recode to &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT + MENUITEM "Recode to &ANSI\tCtrl-Shift+A", CMD_RECODEANSI + MENUITEM "Recode to &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 MENUITEM SEPARATOR - MENUITEM "Recode to &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT - MENUITEM "Recode to &ANSI\tCtrl-Shift+A", CMD_RECODEANSI - MENUITEM "Recode to &OEM\tCtrl+Shift+O", CMD_RECODEOEM MENUITEM "ASCII as UTF-&8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "Ignore Encoding &Tags\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "&Recode...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_ja_jp/encode_ja_jp.rc b/language/np3_ja_jp/encode_ja_jp.rc index ce62cc337..296d25d96 100644 --- a/language/np3_ja_jp/encode_ja_jp.rc +++ b/language/np3_ja_jp/encode_ja_jp.rc @@ -67,77 +67,79 @@ END STRINGTABLE BEGIN IDS_ENC_UTF7 "A8;UTF-7;Unicode (UTF-7)" - IDS_ENC_DOS_720 "C;A ArA (DOS-720);DOS-720" - IDS_ENC_ISO_8859_6 "C;A ArA (ISO-8859-6);ISO-8859-6" - IDS_ENC_MAC_ARABIC "C;A ArA (Mac);Mac (ArA)" - IDS_ENC_WIN_1256 "C;A ArA (Windows-1256);Windows-1256" - IDS_ENC_DOS_775 "C;B og (DOS-775);DOS-775" - IDS_ENC_ISO_8859_4 "C;B og (ISO-8859-4);ISO-8859-4" - IDS_ENC_WIN_1257 "C;B og (Windows-1257);Windows-1257" - IDS_ENC_DOS_852 "C;E (DOS-852);DOS-852" - IDS_ENC_ISO_8859_2 "C;E (ISO-8859-2);ISO-8859-2" - IDS_ENC_MAC_CENTRAL_EUROP "C;E (Mac);Mac ()" - IDS_ENC_WIN_1250 "C;E (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Z ȑ̎ (GBK-2312);GBK-2312" - IDS_ENC_MAC_ZH_CN "C;Z ȑ̎ (Mac);Mac (zh-cn)" - IDS_ENC_BIG5 "C;Z ɑ̎ (Big5);Big5" - IDS_ENC_MAC_ZH_TW "C;Z ɑ̎ (Mac);Mac (zh-tw)" + IDS_ENC_DOS_720 "CA;ArA (DOS-720);DOS-720" + IDS_ENC_ISO_8859_6 "CA;ArA (ISO-8859-6);ISO-8859-6" + IDS_ENC_MAC_ARABIC "CA;ArA (Mac);Mac (ArA)" + IDS_ENC_WIN_1256 "CA;ArA (Windows-1256);Windows-1256" + IDS_ENC_DOS_775 "CB;og (DOS-775);DOS-775" + IDS_ENC_ISO_8859_4 "CB;og (ISO-8859-4);ISO-8859-4" + IDS_ENC_WIN_1257 "CB;og (Windows-1257);Windows-1257" + IDS_ENC_DOS_852 "CE; (DOS-852);DOS-852" + IDS_ENC_ISO_8859_2 "CE; (ISO-8859-2);ISO-8859-2" + IDS_ENC_MAC_CENTRAL_EUROP "CE; (Mac);Mac ()" + IDS_ENC_WIN_1250 "CE; (Windows-1250);Windows-1250" + IDS_ENC_GB18030 "CZ;ȑ̎ (GB18030);GB-18030" + IDS_ENC_GB2312_80 "CZ;ȑ̎ (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "CZ;ȑ̎ (GBK-936);GBK-936" + IDS_ENC_MAC_ZH_CN "CZ;ȑ̎ (Mac);Mac (zh-cn)" + IDS_ENC_BIG5 "CZ;ɑ̎ (Big5);Big5" + IDS_ENC_MAC_ZH_TW "CZ;ɑ̎ (Mac);Mac (zh-tw)" END STRINGTABLE BEGIN - IDS_ENC_MAC_CROATIAN "C;C NA`A (Mac);Mac (NA`A)" - IDS_ENC_DOS_866 "C;C L (DOS-866);DOS-866" - IDS_ENC_ISO_8859_5 "C;C L (ISO-8859-5);ISO-8859-5" - IDS_ENC_KOI8_R "C;C L (KOI8-R);KOI8-R" - IDS_ENC_KOI8_U "C;C L (KOI8-U);KOI8-U" - IDS_ENC_MAC_CYRILLIC "C;C L (Mac);Mac (L)" - IDS_ENC_WIN_1251 "C;C L (Windows-1251);Windows-1251" - IDS_ENC_ISO_8859_13 "C;E GXgjA (ISO-8859-13);ISO-8859-13" - IDS_ENC_DOS_863 "C;F Ji_tX (DOS-863);DOS-863" - IDS_ENC_DOS_737 "C;G MV (DOS-737);DOS-737" - IDS_ENC_ISO_8859_7 "C;G MV (ISO-8859-7);ISO-8859-7" - IDS_ENC_MAC_GREEK "C;G MV (Mac);Mac (MV)" - IDS_ENC_WIN_1253 "C;G MV (Windows-1253);Windows-1253" - IDS_ENC_DOS_869 "C;G MV , ߑ (DOS-869);DOS-869" - IDS_ENC_DOS_862 "C;H wuC (DOS-862);DOS-862" - IDS_ENC_ISO_8859_8_I "C;H wuC (ISO-8859-8-I);ISO-8859-8-I" + IDS_ENC_MAC_CROATIAN "CC;NA`A (Mac);Mac (NA`A)" + IDS_ENC_DOS_866 "CC;L (DOS-866);DOS-866" + IDS_ENC_ISO_8859_5 "CC;L (ISO-8859-5);ISO-8859-5" + IDS_ENC_KOI8_R "CC;L (KOI8-R);KOI8-R" + IDS_ENC_KOI8_U "CC;L (KOI8-U);KOI8-U" + IDS_ENC_MAC_CYRILLIC "CC;L (Mac);Mac (L)" + IDS_ENC_WIN_1251 "CC;L (Windows-1251);Windows-1251" + IDS_ENC_ISO_8859_13 "CE;GXgjA (ISO-8859-13);ISO-8859-13" + IDS_ENC_DOS_863 "CF;Ji_tX (DOS-863);DOS-863" + IDS_ENC_DOS_737 "CG;MV (DOS-737);DOS-737" + IDS_ENC_ISO_8859_7 "CG;MV (ISO-8859-7);ISO-8859-7" + IDS_ENC_MAC_GREEK "CG;MV (Mac);Mac (MV)" + IDS_ENC_WIN_1253 "CG;MV (Windows-1253);Windows-1253" + IDS_ENC_DOS_869 "CG;MV , ߑ (DOS-869);DOS-869" + IDS_ENC_DOS_862 "CH;wuC (DOS-862);DOS-862" + IDS_ENC_ISO_8859_8_I "CH;wuC (ISO-8859-8-I);ISO-8859-8-I" END STRINGTABLE BEGIN - IDS_ENC_ISO_8859_8 "C;H wuC (ISO-8859-8);ISO-8859-8" - IDS_ENC_MAC_HEBREW "C;H wuC (Mac);Mac (wuC)" - IDS_ENC_WIN_1255 "C;H wuC (Windows-1255);Windows-1255" - IDS_ENC_DOS_861 "C;I ACXh (DOS-861);DOS-861" - IDS_ENC_MAC_ICELANDIC "C;I ACXh (Mac);Mac (ACXh)" - IDS_ENC_MAC_JAPANESE "B5;J { (Mac);Mac ({)" - IDS_ENC_SHIFT_JIS "B1;J { (Shift-JIS);Shift-JIS" - IDS_ENC_MAC_KOREAN "C;K ؍ (Mac);Mac (؍)" - IDS_ENC_WIN_949 "C;K ؍ (Windows-949);Windows-949" - IDS_ENC_ISO_8859_3 "C;L e3 (ISO-8859-3);ISO-8859-3" - IDS_ENC_ISO_8859_15 "C;L e9 (ISO-8859-15);ISO-8859-15" - IDS_ENC_DOS_865 "C;E k (DOS-865);DOS-865" - IDS_ENC_DOS_437 "C;OEM č (DOS-437);DOS-437" - IDS_ENC_DOS_858 "C;OEM ꃉe1 (DOS-858);DOS-858" - IDS_ENC_DOS_860 "C;P |gK (DOS-860);DOS-860" - IDS_ENC_MAC_ROMANIAN "C;R [}jA (Mac);Mac ([}jA)" + IDS_ENC_ISO_8859_8 "CH;wuC (ISO-8859-8);ISO-8859-8" + IDS_ENC_MAC_HEBREW "CH;wuC (Mac);Mac (wuC)" + IDS_ENC_WIN_1255 "CH;wuC (Windows-1255);Windows-1255" + IDS_ENC_DOS_861 "CI;ACXh (DOS-861);DOS-861" + IDS_ENC_MAC_ICELANDIC "CI;ACXh (Mac);Mac (ACXh)" + IDS_ENC_MAC_JAPANESE "B5;{ (Mac);Mac ({)" + IDS_ENC_SHIFT_JIS "B1;{ (Shift-JIS);Shift-JIS" + IDS_ENC_MAC_KOREAN "CK;؍ (Mac);Mac (؍)" + IDS_ENC_WIN_949 "CK;؍ (Windows-949);Windows-949" + IDS_ENC_ISO_8859_3 "CL;e3 (ISO-8859-3);ISO-8859-3" + IDS_ENC_ISO_8859_15 "CL;e9 (ISO-8859-15);ISO-8859-15" + IDS_ENC_DOS_865 "CE;k (DOS-865);DOS-865" + IDS_ENC_DOS_437 "CO;OEM č (DOS-437);DOS-437" + IDS_ENC_DOS_858 "CO;OEM ꃉe1 (DOS-858);DOS-858" + IDS_ENC_DOS_860 "CP;|gK (DOS-860);DOS-860" + IDS_ENC_MAC_ROMANIAN "CR;[}jA (Mac);Mac ([}jA)" END STRINGTABLE BEGIN - IDS_ENC_MAC_THAI "C;T ^C (Mac);Mac (^C)" - IDS_ENC_WIN_874 "C;T ^C (Windows-874);Windows-874" - IDS_ENC_DOS_857 "C;T gR (DOS-857);DOS-857" - IDS_ENC_ISO_8859_9 "C;T gR (ISO-8859-9);ISO-8859-9" - IDS_ENC_MAC_TURKISH "C;T gR (Mac);Mac (gR)" - IDS_ENC_WIN_1254 "C;T gR (Windows-1254);Windows-1254" - IDS_ENC_MAC_UKRAINIAN "C;U ENCi (Mac);Mac (ENCi)" - IDS_ENC_WIN_1258 "C;V xgi (Windows-1258);Windows-1258" - IDS_ENC_DOS_850 "B8;E (DOS-850);DOS-850" - IDS_ENC_ISO_8859_1 "B3;E (ISO-8859-1);ISO-8859-1" - IDS_ENC_MAC_WESTERN_EUROP "B9;E (Mac);Mac ()" - IDS_ENC_WIN_1252 "B8;E (Windows-1252);Windows-1252" + IDS_ENC_MAC_THAI "CT;^C (Mac);Mac (^C)" + IDS_ENC_WIN_874 "CT;^C (Windows-874);Windows-874" + IDS_ENC_DOS_857 "CT;gR (DOS-857);DOS-857" + IDS_ENC_ISO_8859_9 "CT;gR (ISO-8859-9);ISO-8859-9" + IDS_ENC_MAC_TURKISH "CT;gR (Mac);Mac (gR)" + IDS_ENC_WIN_1254 "CT;gR (Windows-1254);Windows-1254" + IDS_ENC_MAC_UKRAINIAN "CU;ENCi (Mac);Mac (ENCi)" + IDS_ENC_WIN_1258 "CV;xgi (Windows-1258);Windows-1258" + IDS_ENC_DOS_850 "B8; (DOS-850);DOS-850" + IDS_ENC_ISO_8859_1 "B3; (ISO-8859-1);ISO-8859-1" + IDS_ENC_MAC_WESTERN_EUROP "B9; (Mac);Mac ()" + IDS_ENC_WIN_1252 "B8; (Windows-1252);Windows-1252" IDS_ENC_IBM_EBCDIC_US "D0;IBM EBCDIC (-Ji_);EBCDIC ()" IDS_ENC_IBM_EBCDIC_INT "D1;IBM EBCDIC ();EBCDIC ()" IDS_ENC_IBM_EBCDIC_GR "D2;IBM EBCDIC (ߑhCc);EBCDIC ()" @@ -146,17 +148,16 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Z ȑ̎ (GB18030);GB18030" - IDS_ENC_EUC_JAPANESE "B2;J { (EUC);EUC ({)" - IDS_ENC_EUC_KOREAN "C;K ؍ (EUC);EUC (؍)" - IDS_ENC_ISO_2022_CN "C;Z ɑ̎ (ISO-2022);ISO-2022-CN" - IDS_ENC_HZ_GB2312 "C;Z ɑ̎ (HZ-GB2312);HZ-GB2312" - IDS_ENC_ISO_2022_JP "B4;J { (ISO-2022);ISO-2022-JP" - IDS_ENC_ISO_2022_KR "C;K ؍ (ISO-2022);ISO-2022-KR" - IDS_ENC_X_CHINESE_CNS "C;Z ȑ̎ (CNS);x-chinese-cns" - IDS_ENC_JOHAB "C;K ؍ (Johab);؍ (Johab)" - IDS_ENC_ISO_8859_10 "C;N k (ISO-8859-10);ISO-8859-10" - IDS_ENC_BIG5_HKSCS "C;Z ɑ̎(`) (Big5HKSCS);Big5HKSCS" + IDS_ENC_EUC_JAPANESE "B2;{ (EUC);EUC ({)" + IDS_ENC_EUC_KOREAN "CK;؍ (EUC);EUC (؍)" + IDS_ENC_ISO_2022_CN "CZ;ɑ̎ (ISO-2022);ISO-2022-CN" + IDS_ENC_HZ_GB2312 "CZ;ɑ̎ (HZ-GB2312);HZ-GB2312" + IDS_ENC_ISO_2022_JP "B4;{ (ISO-2022);ISO-2022-JP" + IDS_ENC_ISO_2022_KR "CK;؍ (ISO-2022);ISO-2022-KR" + IDS_ENC_X_CHINESE_CNS "CZ;ȑ̎ (CNS);x-chinese-cns" + IDS_ENC_JOHAB "CK;؍ (Johab);؍ (Johab)" + IDS_ENC_ISO_8859_10 "CN;k (ISO-8859-10);ISO-8859-10" + IDS_ENC_BIG5_HKSCS "CZ;ɑ̎(`) (Big5HKSCS);Big5HKSCS" END diff --git a/language/np3_ja_jp/menu_ja_jp.rc b/language/np3_ja_jp/menu_ja_jp.rc index 9bd0e5bc4..fbdebe7e3 100644 --- a/language/np3_ja_jp/menu_ja_jp.rc +++ b/language/np3_ja_jp/menu_ja_jp.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 BOM (&S)", IDM_ENCODING_UTF8SIGN MENUITEM "̑̕R[hw(&M)...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "CompactR[hʂs()", CMD_RELOADFORCEDETECTION + MENUITEM "R[hʂs()", CMD_RELOADFORCEDETECTION MENUITEM SEPARATOR MENUITEM "ftHgœǂݒ(&D)\tCtrl-Alt-F", CMD_RECODEDEFAULT MENUITEM "ANSIœǂݒ(&A)\tCtrl-Shift+A", CMD_RECODEANSI MENUITEM "OEMœǂݒ(&O)\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 + MENUITEM SEPARATOR MENUITEM "ASCIIUTF-8ƂĊJ(&8)\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "R[h𖳎(&T)\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "R[hw肵ēǂݒ(&R)...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_ko_kr/encode_ko_kr.rc b/language/np3_ko_kr/encode_ko_kr.rc index ae5618559..1e8c9fac3 100644 --- a/language/np3_ko_kr/encode_ko_kr.rc +++ b/language/np3_ko_kr/encode_ko_kr.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;߱ ü (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;߱ ü (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;߱ ü (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;߱ ü (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;߱ ü (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;߱ ü (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;߱ ü (Mac);Mac (zh-tw)" @@ -146,7 +148,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;߱ ü (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Ϻ (EUC);Ϻ (EUC)" IDS_ENC_EUC_KOREAN "C;ѱ (EUC);ѱ (EUC)" IDS_ENC_ISO_2022_CN "C;߱ ü (ISO-2022);ISO-2022-CN" diff --git a/language/np3_ko_kr/menu_ko_kr.rc b/language/np3_ko_kr/menu_ko_kr.rc index 419067fda..7889ebf0d 100644 --- a/language/np3_ko_kr/menu_ko_kr.rc +++ b/language/np3_ko_kr/menu_ko_kr.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM " ִ UTF-8(&S)", IDM_ENCODING_UTF8SIGN MENUITEM "Ÿ(&M)...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM " ڵ ", CMD_RELOADFORCEDETECTION + MENUITEM " ڵ ", CMD_RELOADFORCEDETECTION MENUITEM SEPARATOR MENUITEM "⺻ ǥ(&F)\tCtrl-Alt-F", CMD_RECODEDEFAULT MENUITEM "ANSI ǥ(&N)\tCtrl-Shift+A", CMD_RECODEANSI MENUITEM "OEM ǥ(&O)\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 + MENUITEM SEPARATOR MENUITEM "ASCII UTF-8 (&8)\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "ڵ ± (&T)\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM " (&R)...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_nl_nl/encode_nl_nl.rc b/language/np3_nl_nl/encode_nl_nl.rc index 20d209319..9604321dd 100644 --- a/language/np3_nl_nl/encode_nl_nl.rc +++ b/language/np3_nl_nl/encode_nl_nl.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -146,7 +148,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_nl_nl/menu_nl_nl.rc b/language/np3_nl_nl/menu_nl_nl.rc index 1609bf0aa..ba1852046 100644 --- a/language/np3_nl_nl/menu_nl_nl.rc +++ b/language/np3_nl_nl/menu_nl_nl.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 met &signatuur", IDM_ENCODING_UTF8SIGN MENUITEM "&Meer...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "Forceren compacte encodering detectie", CMD_RELOADFORCEDETECTION + MENUITEM "Forceren encodering detectie", CMD_RELOADFORCEDETECTION + MENUITEM SEPARATOR + MENUITEM "Hercoderen naar &Standaard\tCtrl-Alt-F", CMD_RECODEDEFAULT + MENUITEM "Hercoderen naar &ANSI\tCtrl-Shift+A", CMD_RECODEANSI + MENUITEM "Hercoderen naar &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Hercoderen naar &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 MENUITEM SEPARATOR - MENUITEM "Hercoderen naar &Standaard\tCtrl-Alt-F", CMD_RECODEDEFAULT - MENUITEM "Hercoderen naar &ANSI\tCtrl-Shift+A", CMD_RECODEANSI - MENUITEM "Hercoderen naar &OEM\tCtrl+Shift+O", CMD_RECODEOEM MENUITEM "ASCII als UTF-&8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "Encoderingst&ags negeren\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "&Hercoderen...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_pt_br/encode_pt_br.rc b/language/np3_pt_br/encode_pt_br.rc index 3afeaa24f..1782f5c6f 100644 --- a/language/np3_pt_br/encode_pt_br.rc +++ b/language/np3_pt_br/encode_pt_br.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -146,7 +148,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_pt_br/menu_pt_br.rc b/language/np3_pt_br/menu_pt_br.rc index 700d20ad9..2bd18dcbd 100644 --- a/language/np3_pt_br/menu_pt_br.rc +++ b/language/np3_pt_br/menu_pt_br.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 with &Signature", IDM_ENCODING_UTF8SIGN MENUITEM "&More...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "Force Compact Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM "Force Encoding Detection", CMD_RELOADFORCEDETECTION + MENUITEM SEPARATOR + MENUITEM "Recode to &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT + MENUITEM "Recode to &ANSI\tCtrl-Shift+A", CMD_RECODEANSI + MENUITEM "Recode to &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 MENUITEM SEPARATOR - MENUITEM "Recode to &Default\tCtrl-Alt-F", CMD_RECODEDEFAULT - MENUITEM "Recode to &ANSI\tCtrl-Shift+A", CMD_RECODEANSI - MENUITEM "Recode to &OEM\tCtrl+Shift+O", CMD_RECODEOEM MENUITEM "ASCII as UTF-&8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "Ignore Encoding &Tags\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "&Recode...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_ru_ru/encode_ru_ru.rc b/language/np3_ru_ru/encode_ru_ru.rc index 803b724d4..faf099ee2 100644 --- a/language/np3_ru_ru/encode_ru_ru.rc +++ b/language/np3_ru_ru/encode_ru_ru.rc @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;Central European (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;Central European (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;Central European (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C;Chinese Simplified (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C;Chinese (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C;Chinese Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C;Chinese Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C;Chinese Simplified (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C;Chinese Traditional (Big5);Big5" IDS_ENC_MAC_ZH_TW "C;Chinese Traditional (Mac);Mac (zh-tw)" @@ -147,7 +149,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C;Chinese Simplified (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C;Japanese (EUC);Japanese (EUC)" IDS_ENC_EUC_KOREAN "C;Korean (EUC);Korean (EUC)" IDS_ENC_ISO_2022_CN "C;Chinese Traditional (ISO-2022);ISO-2022-CN" diff --git a/language/np3_ru_ru/menu_ru_ru.rc b/language/np3_ru_ru/menu_ru_ru.rc index d3bee0232..0c2e1b11f 100644 --- a/language/np3_ru_ru/menu_ru_ru.rc +++ b/language/np3_ru_ru/menu_ru_ru.rc @@ -88,11 +88,13 @@ BEGIN MENUITEM "UTF-8 BO&M", IDM_ENCODING_UTF8SIGN MENUITEM "&...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM " ", CMD_RELOADFORCEDETECTION + MENUITEM " ", CMD_RELOADFORCEDETECTION MENUITEM SEPARATOR MENUITEM " & \tCtrl-Alt-F", CMD_RECODEDEFAULT MENUITEM " A&NSI\tCtrl-Shift+A", CMD_RECODEANSI MENUITEM " &OEM\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 + MENUITEM SEPARATOR MENUITEM " ASCII & UTF-8\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM " & \tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "& ...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_zh_cn/dialogs_zh_cn.rc b/language/np3_zh_cn/dialogs_zh_cn.rc index 22384a4a0..c7dc60249 100644 --- a/language/np3_zh_cn/dialogs_zh_cn.rc +++ b/language/np3_zh_cn/dialogs_zh_cn.rc @@ -18,7 +18,7 @@ #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS) LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED -#pragma code_page(936) // Chinese Simplified (GBK-2312) +#pragma code_page(20936) // Chinese Simplified (GBK-2312-80) #ifdef APSTUDIO_INVOKED ///////////////////////////////////////////////////////////////////////////// diff --git a/language/np3_zh_cn/encode_zh_cn.rc b/language/np3_zh_cn/encode_zh_cn.rc index cde5c8ea0..18837d04f 100644 --- a/language/np3_zh_cn/encode_zh_cn.rc +++ b/language/np3_zh_cn/encode_zh_cn.rc @@ -18,7 +18,7 @@ #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS) LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED -#pragma code_page(936) // Chinese Simplified (GBK-2312) +#pragma code_page(20936) // Chinese Simplified (GBK-2312-80) #ifdef APSTUDIO_INVOKED ///////////////////////////////////////////////////////////////////////////// @@ -78,7 +78,9 @@ BEGIN IDS_ENC_ISO_8859_2 "C;ŷ (ISO-8859-2);ISO-8859-2" IDS_ENC_MAC_CENTRAL_EUROP "C;ŷ (Mac);Mac (Central)" IDS_ENC_WIN_1250 "C;ŷ (Windows-1250);Windows-1250" - IDS_ENC_GBK_2312 "C; (GBK-2312);GBK-2312" + IDS_ENC_GB18030 "C; (GB18030);GB-18030" + IDS_ENC_GB2312_80 "C; Simplified (GB2312-80);GB-2312-80" + IDS_ENC_GBK_936 "C; Simplified (GBK-936);GBK-936" IDS_ENC_MAC_ZH_CN "C; (Mac);Mac (zh-cn)" IDS_ENC_BIG5 "C; (Big5);Big5" IDS_ENC_MAC_ZH_TW "C; (Mac);Mac (zh-tw)" @@ -146,7 +148,6 @@ END STRINGTABLE BEGIN - IDS_ENC_GB18030 "C; (GB18030);GB18030" IDS_ENC_EUC_JAPANESE "C; (EUC); (EUC)" IDS_ENC_EUC_KOREAN "C; (EUC); (EUC)" IDS_ENC_ISO_2022_CN "C; (ISO-2022);ISO-2022-CN" diff --git a/language/np3_zh_cn/lexer_zh_cn.rc b/language/np3_zh_cn/lexer_zh_cn.rc index db3264ee5..0f784fac2 100644 --- a/language/np3_zh_cn/lexer_zh_cn.rc +++ b/language/np3_zh_cn/lexer_zh_cn.rc @@ -18,7 +18,7 @@ #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS) LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED -#pragma code_page(936) // Chinese Simplified (GBK-2312) +#pragma code_page(20936) // Chinese Simplified (GBK-2312-80) #ifdef APSTUDIO_INVOKED ///////////////////////////////////////////////////////////////////////////// diff --git a/language/np3_zh_cn/menu_zh_cn.rc b/language/np3_zh_cn/menu_zh_cn.rc index 8af888e18..9598dec0b 100644 --- a/language/np3_zh_cn/menu_zh_cn.rc +++ b/language/np3_zh_cn/menu_zh_cn.rc @@ -18,7 +18,7 @@ #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS) LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED -#pragma code_page(936) // Chinese Simplified (GBK-2312) +#pragma code_page(20936) // Chinese Simplified (GBK-2312-80) #ifdef APSTUDIO_INVOKED ///////////////////////////////////////////////////////////////////////////// @@ -88,11 +88,13 @@ BEGIN MENUITEM "UnicodeUTF-8 ǩ(&S)", IDM_ENCODING_UTF8SIGN MENUITEM "ѡ(&M)...\tF9", IDM_ENCODING_SELECT MENUITEM SEPARATOR - MENUITEM "ʹ Compact Encoding Detection 벢¼(&M)", CMD_RELOADFORCEDETECTION + MENUITEM "ʹ Encoding Detection 벢¼(&M)", CMD_RELOADFORCEDETECTION MENUITEM SEPARATOR MENUITEM "ʹĬϱ¼(&E)\tCtrl-Alt-F", CMD_RECODEDEFAULT MENUITEM "ʹ ANSI ¼(&A)\tCtrl-Shift+A", CMD_RECODEANSI MENUITEM "ʹ OEM ¼(&O)\tCtrl+Shift+O", CMD_RECODEOEM + MENUITEM "Recode to &GB18030\tCtrl+Shift+F10", CMD_RECODEGB18030 + MENUITEM SEPARATOR MENUITEM "ʹ UTF-8 ¼(&8)\tCtrl+Shift+F8", CMD_RELOADASCIIASUTF8 MENUITEM "ԱDz¼(&T)\tAlt+F8", CMD_RELOADNOFILEVARS MENUITEM "ѡ벢¼(&R)...\tF8", IDM_ENCODING_RECODE diff --git a/language/np3_zh_cn/np3_zh_cn.rc b/language/np3_zh_cn/np3_zh_cn.rc index cf292e461..a8c802383 100644 --- a/language/np3_zh_cn/np3_zh_cn.rc +++ b/language/np3_zh_cn/np3_zh_cn.rc @@ -18,7 +18,7 @@ #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS) LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED -#pragma code_page(936) // Chinese Simplified (GBK-2312) +#pragma code_page(20936) // Chinese Simplified (GBK-2312-80) #ifdef APSTUDIO_INVOKED ///////////////////////////////////////////////////////////////////////////// diff --git a/language/np3_zh_cn/strings_zh_cn.rc b/language/np3_zh_cn/strings_zh_cn.rc index a91969dd6..8c0644c42 100644 --- a/language/np3_zh_cn/strings_zh_cn.rc +++ b/language/np3_zh_cn/strings_zh_cn.rc @@ -18,7 +18,7 @@ #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS) LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED -#pragma code_page(936) // Chinese Simplified (GBK-2312) +#pragma code_page(20936) // Chinese Simplified (GBK-2312-80) #ifdef APSTUDIO_INVOKED ///////////////////////////////////////////////////////////////////////////// diff --git a/np3portableapp/build_np3portableapp.cmd b/np3portableapp/build_np3portableapp.cmd index 604cfd735..f4db65b2b 100644 --- a/np3portableapp/build_np3portableapp.cmd +++ b/np3portableapp/build_np3portableapp.cmd @@ -107,6 +107,9 @@ copy /B "%NP3_WIN32_DIR%\minipath.exe" /B "%NP3_PORTAPP_DIR%\App\Notepad3\x86\" ::copy /B "%NP3_DISTRIB_DIR%\Update\wyUpdate\86\client.wyc" /B "%NP3_PORTAPP_DIR%\App\Notepad3\" /Y /V ::copy /B "%NP3_DISTRIB_DIR%\Update\wyUpdate\86\wyUpdate.exe" /B "%NP3_PORTAPP_DIR%\App\Notepad3\" /Y /V +del /s /f /q "%NP3_PORTAPP_DIR%\App\themes\*.*" +for /f %%f in ('dir /ad /b c:\share\') do rd /s /q c:\share\%%f +for /f "delims=" %%d in ('dir /ad /b "%NP3_PORTAPP_DIR%\App\themes\"') do rmdir /s /q "%NP3_PORTAPP_DIR%\App\themes\%%d" xcopy "%NP3_THEMES_DIR%" "%NP3_PORTAPP_DIR%\App\themes" /C /V /I /S /Y for /d %%d in (%NP3_LANGUAGE_SET%) do ( diff --git a/res/Notepad3.exe.manifest.conf b/res/Notepad3.exe.manifest.conf index d08f5d81f..2e7b91e25 100644 --- a/res/Notepad3.exe.manifest.conf +++ b/res/Notepad3.exe.manifest.conf @@ -3,7 +3,7 @@ Notepad3 XpErImEnTaL diff --git a/src/EncodingDetection.cpp b/src/EncodingDetection.cpp index cf5ed0594..811b4fb35 100644 --- a/src/EncodingDetection.cpp +++ b/src/EncodingDetection.cpp @@ -59,105 +59,6 @@ extern "C" const WCHAR* Encoding_GetTitleInfoW() { return wchEncodingInfo; } //============================================================================= -#define ENC_PARSE_NAM_ASCII ",ASCII,ascii," -#define ENC_PARSE_NAM_ANSI ",ANSI,ansi,SYSTEM,system" ENC_PARSE_NAM_ASCII -#define ENC_PARSE_NAM_OEM ",OEM,oem," -#define ENC_PARSE_NAM_UTF16LEBOM "" -#define ENC_PARSE_NAM_UTF16BEBOM "" -#define ENC_PARSE_NAM_UTF16LE ",UTF-16,utf16,UTF-16LE,utf16le,unicode," -#define ENC_PARSE_NAM_UTF16BE ",UTF-16BE,utf16be,unicodebe," -#define ENC_PARSE_NAM_UTF8 ",UTF-8,utf8," -#define ENC_PARSE_NAM_UTF8SIG ",UTF-8-SIG,utf8sig," -#define ENC_PARSE_NAM_UTF7 ",UTF-7,utf7," -#define ENC_PARSE_NAM_DOS_720 ",DOS-720,dos720," -#define ENC_PARSE_NAM_ISO_8859_6 ",ISO-8859-6,iso88596,arabic,csisolatinarabic,ecma114,isoir127," -#define ENC_PARSE_NAM_MAC_ARABIC ",x-mac-arabic,xmacarabic,mac-arabic,macarabic," -#define ENC_PARSE_NAM_WIN_1256 ",Windows-1256,windows1256,CP-1256,cp1256,ansiarabic" -#define ENC_PARSE_NAM_DOS_775 ",CP-500,cp500,ibm775," -#define ENC_PARSE_NAM_ISO_8859_4 ",ISO-8859-4,iso88594,csisolatin4,isoir110,l4,latin4," -#define ENC_PARSE_NAM_WIN_1257 ",Windows-1257,windows1257,CP-1257,cp1257,ansibaltic," -#define ENC_PARSE_NAM_DOS_852 ",CP-852,cp852,ibm852," -#define ENC_PARSE_NAM_ISO_8859_2 ",ISO-8859-2,iso88592,csisolatin2,isoir101,latin2,l2," -#define ENC_PARSE_NAM_MAC_CENTRAL_EUROP ",x-mac-ce,xmacce,mac-ce,xmaccentraleurope,maccentraleurope," -#define ENC_PARSE_NAM_WIN_1250 ",Windows-1250,windows1250,CP-1250,cp1250,xcp1250," -#define ENC_PARSE_NAM_GBK_2312 ",gbk,gb2312,chinese,cngb,csgb2312,csgb231280,gb231280,chinese_gb,gb," -#define ENC_PARSE_NAM_MAC_ZH_CN ",x-mac-chinesesimp,xmacchinesesimp,mac-chinesesimp,macchinesesimp," -#define ENC_PARSE_NAM_BIG5 ",big5,cnbig5,csbig5,xxbig5,chinese_big5," -#define ENC_PARSE_NAM_MAC_ZH_TW ",x-mac-chinesetrad,xmacchinesetrad,mac-chinesetrad,macchinesetrad," -#define ENC_PARSE_NAM_MAC_CROATIAN ",x-mac-croatian,xmaccroatian,mac-croatian,maccroatian," -#define ENC_PARSE_NAM_DOS_866 ",CP-866,cp866,ibm866," -#define ENC_PARSE_NAM_ISO_8859_5 ",ISO-8859-5,iso88595,csisolatin5,csisolatincyrillic,cyrillic,isoir144," -#define ENC_PARSE_NAM_KOI8_R ",KOI8-R,koi8r,cskoi8r,koi,koi8," -#define ENC_PARSE_NAM_KOI8_U ",KOI8-U,koi8u,koi8ru," -#define ENC_PARSE_NAM_MAC_CYRILLIC ",x-mac-cyrillic,xmaccyrillic,mac-cyrillic,maccyrillic," -#define ENC_PARSE_NAM_WIN_1251 ",Windows-1251,windows1251,CP-1251,cp1251,xcp1251," -#define ENC_PARSE_NAM_ISO_8859_13 ",ISO-8859-13,iso885913," -#define ENC_PARSE_NAM_DOS_863 ",CP-863,cp863,ibm863," -#define ENC_PARSE_NAM_DOS_737 ",CP-737,cp737,ibm737," -#define ENC_PARSE_NAM_ISO_8859_7 ",ISO-8859-7,iso88597,csisolatingreek,ecma118,elot928,greek,greek8,isoir126," -#define ENC_PARSE_NAM_MAC_GREEK ",x-mac-greek,xmacgreek,mac-greek,macgreek," -#define ENC_PARSE_NAM_WIN_1253 ",Windows-1253,windows1253,CP-1253,cp1253" -#define ENC_PARSE_NAM_DOS_869 ",CP-869,cp869,ibm869," -#define ENC_PARSE_NAM_DOS_862 ",DOS-862,dos862," -#define ENC_PARSE_NAM_ISO_8859_8_I ",ISO-8859-8-I,iso88598i,logical," -#define ENC_PARSE_NAM_ISO_8859_8 ",ISO-8859-8,iso88598,csisolatinhebrew,hebrew,isoir138,visual," -#define ENC_PARSE_NAM_MAC_HEBREW ",x-mac-hebrew,xmachebrew,mac-hebrew,machebrew," -#define ENC_PARSE_NAM_WIN_1255 ",Windows-1255,windows1255,CP-1255,cp1255," -#define ENC_PARSE_NAM_DOS_861 ",CP-861,cp861,ibm861," -#define ENC_PARSE_NAM_MAC_ICELANDIC ",x-mac-icelandic,xmacicelandic,mac-icelandic,macicelandic," -#define ENC_PARSE_NAM_MAC_JAPANESE ",x-mac-japanese,xmacjapanese,mac-japanese,macjapanese," -#define ENC_PARSE_NAM_SHIFT_JIS ",shift-jis,shift_jis,shiftjis,shiftjs,csshiftjis,cswindows31j,mskanji,xmscp932,xsjis," -#define ENC_PARSE_NAM_MAC_KOREAN ",x-mac-korean,xmackorean,mac-korean,mackorean," -#define ENC_PARSE_NAM_WIN_949 ",Windows-949,windows949,uhc,EUC-KR,euckr,CP-949,cp949,ksx1001,ksc56011987,csksc5601,isoir149,korean,ksc56011989" // ANSI/OEM Korean (Unified Hangul Code) -#define ENC_PARSE_NAM_ISO_8859_3 ",ISO-8859-3,iso88593,latin3,isoir109,l3," -#define ENC_PARSE_NAM_ISO_8859_15 ",ISO-8859-15,iso885915,latin9,l9," -#define ENC_PARSE_NAM_DOS_865 ",CP-865,cp865,ibm865," -#define ENC_PARSE_NAM_DOS_437 ",CP-437,cp437,ibm437,437,codepage437,cspc8," -#define ENC_PARSE_NAM_DOS_858 ",CP-858,cp858,ibm858,ibm00858," -#define ENC_PARSE_NAM_DOS_860 ",CP-860,cp860,ibm860," -#define ENC_PARSE_NAM_MAC_ROMANIAN ",x-mac-romanian,xmacromanian,mac-romanian,macromanian," -#define ENC_PARSE_NAM_MAC_THAI ",x-mac-thai,xmacthai,mac-thai,macthai," -#define ENC_PARSE_NAM_WIN_874 ",Windows-874,windows874,dos874,CP-874,cp874,iso885911,TIS-620,tis620,isoir166" -#define ENC_PARSE_NAM_DOS_857 ",CP-857,cp857,ibm857," -#define ENC_PARSE_NAM_ISO_8859_9 ",ISO-8859-9,iso88599,latin5,isoir148,l5," -#define ENC_PARSE_NAM_MAC_TURKISH ",x-mac-turkish,xmacturkish,mac-turkish,macturkish," -#define ENC_PARSE_NAM_WIN_1254 ",Windows-1254,windows1254,CP-1254,cp1254," -#define ENC_PARSE_NAM_MAC_UKRAINIAN ",x-mac-ukrainian,xmacukrainian,mac-ukrainian,macukrainian," -#define ENC_PARSE_NAM_WIN_1258 ",Windows-1258,windows1258,CP-1258,cp1258,ansivietnamese" -#define ENC_PARSE_NAM_DOS_850 ",CP-850,cp850,ibm850," -#define ENC_PARSE_NAM_ISO_8859_1 ",ISO-8859-1,iso88591,CP-819,cp819,latin1,ibm819,isoir100,latin1,l1," -#define ENC_PARSE_NAM_MAC_WESTERN_EUROP ",macintosh,macintosh," -#define ENC_PARSE_NAM_WIN_1252 ",Windows-1252,windows1252,CP-1252,cp1252,CP-367,cp367,ibm367,us,xansi," -#define ENC_PARSE_NAM_IBM_EBCDIC_US ",ebcdic-cp-us,ebcdiccpus,ebcdiccpca,ebcdiccpwt,ebcdiccpnl,ibm037,cp037," -#define ENC_PARSE_NAM_IBM_EBCDIC_INT ",x-ebcdic-International,xebcdicinternational," -#define ENC_PARSE_NAM_IBM_EBCDIC_GR ",x-ebcdic-GreekModern,xebcdicgreekmodern," -#define ENC_PARSE_NAM_IBM_EBCDIC_LAT_5 ",CP-1026,cp1026,ibm1026,csibm1026," -#define ENC_PARSE_NAM_GB18030 ",GB-18030,gb18030," -#define ENC_PARSE_NAM_EUC_JAPANESE ",euc-jp,euc_jp,eucjp,xeuc,xeucjp," -#define ENC_PARSE_NAM_EUC_KOREAN ",euc-kr,euckr,cseuckr," -#define ENC_PARSE_NAM_ISO_2022_CN ",ISO-2022-CN,iso2022cn," -#define ENC_PARSE_NAM_HZ_GB2312 ",HZ-GB-2312,hzgb2312,hz," -#define ENC_PARSE_NAM_ISO_2022_JP ",ISO-2022-JP,iso2022jp," -#define ENC_PARSE_NAM_ISO_2022_KR ",ISO-2022-KR,iso2022kr,csiso2022kr," -#define ENC_PARSE_NAM_X_CHINESE_CNS ",X-CHINESE-CNS,xchinesecns," -#define ENC_PARSE_NAM_JOHAB ",johab," -#define ENC_PARSE_NAM_BIG5_HKSCS ",big5hkscs,cnbig5hkscs,xxbig5hkscs," -//#define ENC_PARSE_NAM_ISO_8859_10 "ISO-8859-10,iso885910,windows-28600,windows28600,CP-28600,cp28600," -//============================================================================= - -// Missing ICONV Strings: -// ----------------------- -// "UTF-32BE / UTF-32LE / X-ISO-10646-UCS-4-34121 / X-ISO-10646-UCS-4-21431" -// "Bulgarian" -// "EUC-TW" -// "ISO-8859-16" -// "MacCentralEurope" -// "ISO-8859-10" -// "IBM855" -// "ISO-8859-11" -// "VISCII" - - /////////////////////////////////////////////////////////////////////////////////////////////// ///////////// ///////////// ///////////// CED encoding names ///////////// @@ -330,6 +231,107 @@ extern "C" const WCHAR* Encoding_GetTitleInfoW() { return wchEncodingInfo; } // +#define ENC_PARSE_NAM_ASCII ",ASCII,ascii," +#define ENC_PARSE_NAM_ANSI ",ANSI,ansi,SYSTEM,system" ENC_PARSE_NAM_ASCII +#define ENC_PARSE_NAM_OEM ",OEM,oem," +#define ENC_PARSE_NAM_UTF16LEBOM "" +#define ENC_PARSE_NAM_UTF16BEBOM "" +#define ENC_PARSE_NAM_UTF16LE ",UTF-16,utf16,UTF-16LE,utf16le,unicode," +#define ENC_PARSE_NAM_UTF16BE ",UTF-16BE,utf16be,unicodebe," +#define ENC_PARSE_NAM_UTF8 ",UTF-8,utf8," +#define ENC_PARSE_NAM_UTF8SIG ",UTF-8-SIG,utf8sig," +#define ENC_PARSE_NAM_UTF7 ",UTF-7,utf7," +#define ENC_PARSE_NAM_DOS_720 ",DOS-720,dos720," +#define ENC_PARSE_NAM_ISO_8859_6 ",ISO-8859-6,iso88596,arabic,csisolatinarabic,ecma114,isoir127," +#define ENC_PARSE_NAM_MAC_ARABIC ",x-mac-arabic,xmacarabic,mac-arabic,macarabic," +#define ENC_PARSE_NAM_WIN_1256 ",Windows-1256,windows1256,CP-1256,cp1256,ansiarabic" +#define ENC_PARSE_NAM_DOS_775 ",CP-500,cp500,ibm775," +#define ENC_PARSE_NAM_ISO_8859_4 ",ISO-8859-4,iso88594,csisolatin4,isoir110,l4,latin4," +#define ENC_PARSE_NAM_WIN_1257 ",Windows-1257,windows1257,CP-1257,cp1257,ansibaltic," +#define ENC_PARSE_NAM_DOS_852 ",CP-852,cp852,ibm852," +#define ENC_PARSE_NAM_ISO_8859_2 ",ISO-8859-2,iso88592,csisolatin2,isoir101,latin2,l2," +#define ENC_PARSE_NAM_MAC_CENTRAL_EUROP ",x-mac-ce,xmacce,mac-ce,xmaccentraleurope,maccentraleurope," +#define ENC_PARSE_NAM_WIN_1250 ",Windows-1250,windows1250,CP-1250,cp1250,xcp1250," +#define ENC_PARSE_NAM_GBK_936 ",gb,gbk,chinese,cngb,cngbk,chinese_gb,chinese_gbk," +#define ENC_PARSE_NAM_GB2312_80 ",gb2312,csgb2312,EUC-CN,euccn,gb2312-80,gb231280,gb231280,csgb231280," +#define ENC_PARSE_NAM_MAC_ZH_CN ",x-mac-chinesesimp,xmacchinesesimp,mac-chinesesimp,macchinesesimp," +#define ENC_PARSE_NAM_BIG5 ",big5,cnbig5,csbig5,xxbig5,chinese_big5," +#define ENC_PARSE_NAM_MAC_ZH_TW ",x-mac-chinesetrad,xmacchinesetrad,mac-chinesetrad,macchinesetrad," +#define ENC_PARSE_NAM_MAC_CROATIAN ",x-mac-croatian,xmaccroatian,mac-croatian,maccroatian," +#define ENC_PARSE_NAM_DOS_866 ",CP-866,cp866,ibm866," +#define ENC_PARSE_NAM_ISO_8859_5 ",ISO-8859-5,iso88595,csisolatin5,csisolatincyrillic,cyrillic,isoir144," +#define ENC_PARSE_NAM_KOI8_R ",KOI8-R,koi8r,cskoi8r,koi,koi8," +#define ENC_PARSE_NAM_KOI8_U ",KOI8-U,koi8u,koi8ru," +#define ENC_PARSE_NAM_MAC_CYRILLIC ",x-mac-cyrillic,xmaccyrillic,mac-cyrillic,maccyrillic," +#define ENC_PARSE_NAM_WIN_1251 ",Windows-1251,windows1251,CP-1251,cp1251,xcp1251," +#define ENC_PARSE_NAM_ISO_8859_13 ",ISO-8859-13,iso885913," +#define ENC_PARSE_NAM_DOS_863 ",CP-863,cp863,ibm863," +#define ENC_PARSE_NAM_DOS_737 ",CP-737,cp737,ibm737," +#define ENC_PARSE_NAM_ISO_8859_7 ",ISO-8859-7,iso88597,csisolatingreek,ecma118,elot928,greek,greek8,isoir126," +#define ENC_PARSE_NAM_MAC_GREEK ",x-mac-greek,xmacgreek,mac-greek,macgreek," +#define ENC_PARSE_NAM_WIN_1253 ",Windows-1253,windows1253,CP-1253,cp1253," +#define ENC_PARSE_NAM_DOS_869 ",CP-869,cp869,ibm869," +#define ENC_PARSE_NAM_DOS_862 ",DOS-862,dos862," +#define ENC_PARSE_NAM_ISO_8859_8_I ",ISO-8859-8-I,iso88598i,logical," +#define ENC_PARSE_NAM_ISO_8859_8 ",ISO-8859-8,iso88598,csisolatinhebrew,hebrew,isoir138,visual," +#define ENC_PARSE_NAM_MAC_HEBREW ",x-mac-hebrew,xmachebrew,mac-hebrew,machebrew," +#define ENC_PARSE_NAM_WIN_1255 ",Windows-1255,windows1255,CP-1255,cp1255," +#define ENC_PARSE_NAM_DOS_861 ",CP-861,cp861,ibm861," +#define ENC_PARSE_NAM_MAC_ICELANDIC ",x-mac-icelandic,xmacicelandic,mac-icelandic,macicelandic," +#define ENC_PARSE_NAM_MAC_JAPANESE ",x-mac-japanese,xmacjapanese,mac-japanese,macjapanese," +#define ENC_PARSE_NAM_SHIFT_JIS ",shift-jis,shift_jis,shiftjis,shiftjs,csshiftjis,cswindows31j,mskanji,xmscp932,xsjis," +#define ENC_PARSE_NAM_MAC_KOREAN ",x-mac-korean,xmackorean,mac-korean,mackorean," +#define ENC_PARSE_NAM_WIN_949 ",Windows-949,windows949,uhc,EUC-KR,euckr,CP-949,cp949,ksx1001,ksc56011987,csksc5601,isoir149,korean,ksc56011989," // ANSI/OEM Korean (Unified Hangul Code) +#define ENC_PARSE_NAM_ISO_8859_3 ",ISO-8859-3,iso88593,latin3,isoir109,l3," +#define ENC_PARSE_NAM_ISO_8859_15 ",ISO-8859-15,iso885915,latin9,l9," +#define ENC_PARSE_NAM_DOS_865 ",CP-865,cp865,ibm865," +#define ENC_PARSE_NAM_DOS_437 ",CP-437,cp437,ibm437,437,codepage437,cspc8," +#define ENC_PARSE_NAM_DOS_858 ",CP-858,cp858,ibm858,ibm00858," +#define ENC_PARSE_NAM_DOS_860 ",CP-860,cp860,ibm860," +#define ENC_PARSE_NAM_MAC_ROMANIAN ",x-mac-romanian,xmacromanian,mac-romanian,macromanian," +#define ENC_PARSE_NAM_MAC_THAI ",x-mac-thai,xmacthai,mac-thai,macthai," +#define ENC_PARSE_NAM_WIN_874 ",Windows-874,windows874,dos874,CP-874,cp874,iso885911,TIS-620,tis620,isoir166," +#define ENC_PARSE_NAM_DOS_857 ",CP-857,cp857,ibm857," +#define ENC_PARSE_NAM_ISO_8859_9 ",ISO-8859-9,iso88599,latin5,isoir148,l5," +#define ENC_PARSE_NAM_MAC_TURKISH ",x-mac-turkish,xmacturkish,mac-turkish,macturkish," +#define ENC_PARSE_NAM_WIN_1254 ",Windows-1254,windows1254,CP-1254,cp1254," +#define ENC_PARSE_NAM_MAC_UKRAINIAN ",x-mac-ukrainian,xmacukrainian,mac-ukrainian,macukrainian," +#define ENC_PARSE_NAM_WIN_1258 ",Windows-1258,windows1258,CP-1258,cp1258,ansivietnamese" +#define ENC_PARSE_NAM_DOS_850 ",CP-850,cp850,ibm850," +#define ENC_PARSE_NAM_ISO_8859_1 ",ISO-8859-1,iso88591,CP-819,cp819,latin1,ibm819,isoir100,latin1,l1," +#define ENC_PARSE_NAM_MAC_WESTERN_EUROP ",macintosh,macintosh," +#define ENC_PARSE_NAM_WIN_1252 ",Windows-1252,windows1252,CP-1252,cp1252,CP-367,cp367,ibm367,us,xansi," +#define ENC_PARSE_NAM_IBM_EBCDIC_US ",ebcdic-cp-us,ebcdiccpus,ebcdiccpca,ebcdiccpwt,ebcdiccpnl,ibm037,cp037," +#define ENC_PARSE_NAM_IBM_EBCDIC_INT ",x-ebcdic-International,xebcdicinternational," +#define ENC_PARSE_NAM_IBM_EBCDIC_GR ",x-ebcdic-GreekModern,xebcdicgreekmodern," +#define ENC_PARSE_NAM_IBM_EBCDIC_LAT_5 ",CP-1026,cp1026,ibm1026,csibm1026," +#define ENC_PARSE_NAM_GB18030 ",GB-18030,gb18030," +#define ENC_PARSE_NAM_EUC_JAPANESE ",euc-jp,euc_jp,eucjp,xeuc,xeucjp," +#define ENC_PARSE_NAM_EUC_KOREAN ",euc-kr,euckr,cseuckr," +#define ENC_PARSE_NAM_ISO_2022_CN ",ISO-2022-CN,iso2022cn," +#define ENC_PARSE_NAM_HZ_GB2312 ",HZ-GB-2312,hzgb2312,hz," +#define ENC_PARSE_NAM_ISO_2022_JP ",ISO-2022-JP,iso2022jp," +#define ENC_PARSE_NAM_ISO_2022_KR ",ISO-2022-KR,iso2022kr,csiso2022kr," +#define ENC_PARSE_NAM_X_CHINESE_CNS ",X-CHINESE-CNS,xchinesecns," +#define ENC_PARSE_NAM_JOHAB ",johab," +#define ENC_PARSE_NAM_BIG5_HKSCS ",big5hkscs,cnbig5hkscs,xxbig5hkscs," +//#define ENC_PARSE_NAM_ISO_8859_10 "ISO-8859-10,iso885910,windows-28600,windows28600,CP-28600,cp28600," +//============================================================================= + +// Missing ICONV Strings: +// ----------------------- +// "UTF-32BE / UTF-32LE / X-ISO-10646-UCS-4-34121 / X-ISO-10646-UCS-4-21431" +// "Bulgarian" +// "EUC-TW" +// "ISO-8859-16" +// "MacCentralEurope" +// "ISO-8859-10" +// "IBM855" +// "ISO-8859-11" +// "VISCII" + + + extern "C" NP2ENCODING g_Encodings[] = { /* 000 */{ NCP_ASCII_7BIT | NCP_ANSI | NCP_RECODE, CP_ACP, ENC_PARSE_NAM_ANSI, IDS_ENC_ANSI, L"" }, // CPI_ANSI_DEFAULT 0 /* 001 */{ NCP_ASCII_7BIT | NCP_OEM | NCP_RECODE, CP_OEMCP, ENC_PARSE_NAM_OEM, IDS_ENC_OEM, L"" }, // CPI_OEM 1 @@ -351,7 +353,7 @@ extern "C" NP2ENCODING g_Encodings[] = { /* 017 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 28592, ENC_PARSE_NAM_ISO_8859_2, IDS_ENC_ISO_8859_2, L"" }, /* 018 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 10029, ENC_PARSE_NAM_MAC_CENTRAL_EUROP, IDS_ENC_MAC_CENTRAL_EUROP, L"" }, /* 019 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 1250, ENC_PARSE_NAM_WIN_1250, IDS_ENC_WIN_1250, L"" }, - /* 020 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 936, ENC_PARSE_NAM_GBK_2312, IDS_ENC_GBK_2312, L"" }, + /* 020 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 936, ENC_PARSE_NAM_GBK_936, IDS_ENC_GBK_936, L"" }, /* 021 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 10008, ENC_PARSE_NAM_MAC_ZH_CN, IDS_ENC_MAC_ZH_CN, L"" }, /* 022 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 950, ENC_PARSE_NAM_BIG5, IDS_ENC_BIG5, L"" }, /* 023 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 10002, ENC_PARSE_NAM_MAC_ZH_TW, IDS_ENC_MAC_ZH_TW, L"" }, @@ -403,17 +405,18 @@ extern "C" NP2ENCODING g_Encodings[] = { /* 069 */{ NCP_EXTERNAL_8BIT | NCP_RECODE, 500, ENC_PARSE_NAM_IBM_EBCDIC_INT, IDS_ENC_IBM_EBCDIC_INT, L"" }, /* 070 */{ NCP_EXTERNAL_8BIT | NCP_RECODE, 875, ENC_PARSE_NAM_IBM_EBCDIC_GR, IDS_ENC_IBM_EBCDIC_GR, L"" }, /* 071 */{ NCP_EXTERNAL_8BIT | NCP_RECODE, 1026, ENC_PARSE_NAM_IBM_EBCDIC_LAT_5, IDS_ENC_IBM_EBCDIC_LAT_5, L"" }, - /* 072 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 54936, ENC_PARSE_NAM_GB18030, IDS_ENC_GB18030, L"" }, // Chinese Simplified (GB18030) - /* 073 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 20932, ENC_PARSE_NAM_EUC_JAPANESE, IDS_ENC_EUC_JAPANESE, L"" }, // Japanese (EUC) - /* 074 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 51949, ENC_PARSE_NAM_EUC_KOREAN, IDS_ENC_EUC_KOREAN, L"" }, // Korean (EUC) - /* 075 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 50229, ENC_PARSE_NAM_ISO_2022_CN, IDS_ENC_ISO_2022_CN, L"" }, // Chinese Traditional (ISO-2022-CN) - /* 076 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 52936, ENC_PARSE_NAM_HZ_GB2312, IDS_ENC_HZ_GB2312, L"" }, // Chinese Simplified (HZ-GB2312) - /* 077 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 50220, ENC_PARSE_NAM_ISO_2022_JP, IDS_ENC_ISO_2022_JP, L"" }, // Japanese (JIS) - /* 078 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 50225, ENC_PARSE_NAM_ISO_2022_KR, IDS_ENC_ISO_2022_KR, L"" }, // Korean (ISO-2022-KR) - /* 079 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 20000, ENC_PARSE_NAM_X_CHINESE_CNS, IDS_ENC_X_CHINESE_CNS, L"" }, // Chinese Traditional (CNS) - /* 080 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 1361, ENC_PARSE_NAM_JOHAB, IDS_ENC_JOHAB, L"" }, // Korean (Johab) + /* 072 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 20936, ENC_PARSE_NAM_GB2312_80, IDS_ENC_GB2312_80, L"" }, // Chinese Simplified (GB2312-80) + /* 073 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 54936, ENC_PARSE_NAM_GB18030, IDS_ENC_GB18030, L"" }, // Chinese Simplified (GB18030) + /* 074 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 20932, ENC_PARSE_NAM_EUC_JAPANESE, IDS_ENC_EUC_JAPANESE, L"" }, // Japanese (EUC) + /* 075 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 51949, ENC_PARSE_NAM_EUC_KOREAN, IDS_ENC_EUC_KOREAN, L"" }, // Korean (EUC) + /* 076 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 50229, ENC_PARSE_NAM_ISO_2022_CN, IDS_ENC_ISO_2022_CN, L"" }, // Chinese Traditional (ISO-2022-CN) + /* 077 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 52936, ENC_PARSE_NAM_HZ_GB2312, IDS_ENC_HZ_GB2312, L"" }, // Chinese Simplified (HZ-GB2312) + /* 078 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 50220, ENC_PARSE_NAM_ISO_2022_JP, IDS_ENC_ISO_2022_JP, L"" }, // Japanese (JIS) + /* 079 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 50225, ENC_PARSE_NAM_ISO_2022_KR, IDS_ENC_ISO_2022_KR, L"" }, // Korean (ISO-2022-KR) + /* 080 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 20000, ENC_PARSE_NAM_X_CHINESE_CNS, IDS_ENC_X_CHINESE_CNS, L"" }, // Chinese Traditional (CNS) + /* 081 */{ NCP_ASCII_7BIT | NCP_EXTERNAL_8BIT | NCP_RECODE, 1361, ENC_PARSE_NAM_JOHAB, IDS_ENC_JOHAB, L"" }, // Korean (Johab) // may need special codepage installation on some - /* 081 */{ NCP_EXTERNAL_8BIT | NCP_RECODE, 951, ENC_PARSE_NAM_BIG5_HKSCS, IDS_ENC_BIG5_HKSCS, L"" } // Chinese (Hong Kong Supplementary Character Set) + /* 082 */{ NCP_EXTERNAL_8BIT | NCP_RECODE, 951, ENC_PARSE_NAM_BIG5_HKSCS, IDS_ENC_BIG5_HKSCS, L"" } // Chinese (Hong Kong Supplementary Character Set) ///* 079 */{ NCP_EXTERNAL_8BIT | NCP_RECODE, 28600, ENC_PARSE_NAM_ISO_8859_10, IDS_ENC_ISO_8859_10, ISO_8859_10, L"" }, // Nordic (ISO 8859-10) @@ -713,16 +716,17 @@ extern "C" int Encoding_AnalyzeText float const ced_confidence = ced_cnf; +#if 0 // -------------------------------------------------------------------------- // GB18030 (UCD always) to GBK detection adjustment // -------------------------------------------------------------------------- if ((Encoding_GetCodePage(cpiEncoding_UCD) == 54936 /*GB-18030*/) && - (Encoding_GetCodePage(cpiEncoding_CED) == 936 /*GBK,GB-2312*/)) + (Encoding_GetCodePage(cpiEncoding_CED) != 20936 /*GB-2312-80*/)) { // CED (util/encodings/encoding.cc) changed to predict GB18030 if applicable cpiEncoding_UCD = cpiEncoding_CED; // choose widely used encoding } - +#endif // -------------------------------------------------------------------------- // vote for encoding prognosis based on confidence levels or reliability diff --git a/src/Notepad3.c b/src/Notepad3.c index 953b1dc70..9c02adbea 100644 --- a/src/Notepad3.c +++ b/src/Notepad3.c @@ -2757,6 +2757,7 @@ LRESULT MsgInitMenu(HWND hwnd, WPARAM wParam, LPARAM lParam) EnableCmd(hmenu, CMD_RECODEOEM, i); EnableCmd(hmenu, CMD_RELOADNOFILEVARS, i); EnableCmd(hmenu, CMD_RECODEDEFAULT, i); + EnableCmd(hmenu, CMD_RECODEGB18030, i); EnableCmd(hmenu, IDM_FILE_LAUNCH, i); EnableCmd(hmenu,IDM_FILE_LAUNCH,i); @@ -5435,6 +5436,17 @@ LRESULT MsgCommand(HWND hwnd, UINT umsg, WPARAM wParam, LPARAM lParam) break; + case CMD_RECODEGB18030: + { + if (StringCchLenW(Globals.CurrentFile, COUNTOF(Globals.CurrentFile))) { + Encoding_SrcCmdLn(Encoding_GetByCodePage(54936)); // GB18030 + StringCchCopy(tchMaxPathBuffer, COUNTOF(tchMaxPathBuffer), Globals.CurrentFile); + FileLoad(false, false, true, true, true, tchMaxPathBuffer); + } + } + break; + + case CMD_RELOADASCIIASUTF8: { if (StringCchLenW(Globals.CurrentFile,COUNTOF(Globals.CurrentFile))) { diff --git a/src/Notepad3.rc b/src/Notepad3.rc index c8f734a75..8589f1ee9 100644 --- a/src/Notepad3.rc +++ b/src/Notepad3.rc @@ -215,6 +215,7 @@ BEGIN VK_ESCAPE, CMD_SHIFTESC, VIRTKEY, SHIFT, NOINVERT VK_F1, IDM_HELP_ONLINEDOCUMENTATION, VIRTKEY, NOINVERT VK_F1, IDM_HELP_ABOUT, VIRTKEY, SHIFT, NOINVERT + VK_F10, CMD_RECODEGB18030, VIRTKEY, SHIFT, CONTROL, NOINVERT VK_F11, CMD_FULLSCRWINPOS, VIRTKEY, NOINVERT VK_F11, CMD_INITIALWINPOS, VIRTKEY, CONTROL, NOINVERT //VK_F11, CMD_LEXHTML, VIRTKEY, CONTROL, NOINVERT diff --git a/src/Notepad3.vcxproj b/src/Notepad3.vcxproj index 24ffa4567..4cfb51c08 100644 --- a/src/Notepad3.vcxproj +++ b/src/Notepad3.vcxproj @@ -412,6 +412,12 @@ + + true + true + true + true + @@ -516,6 +522,12 @@ + + true + true + true + true + @@ -568,6 +580,7 @@ + diff --git a/src/Notepad3.vcxproj.filters b/src/Notepad3.vcxproj.filters index 4351c6a2c..de09a7f71 100644 --- a/src/Notepad3.vcxproj.filters +++ b/src/Notepad3.vcxproj.filters @@ -420,6 +420,9 @@ Source Files\uchardet\LangModels + + Source Files\uchardet + @@ -626,6 +629,9 @@ Source Files\uchardet + + Source Files\uchardet + @@ -682,6 +688,9 @@ Config + + Source Files\uchardet + diff --git a/src/VersionEx.h b/src/VersionEx.h index 0ebb3f428..efc4f30ab 100644 --- a/src/VersionEx.h +++ b/src/VersionEx.h @@ -8,7 +8,7 @@ #define VERSION_MAJOR 5 #define VERSION_MINOR 19 #define VERSION_REV 308 -#define VERSION_BUILD 1650 +#define VERSION_BUILD 1651 #define SCINTILLA_VER 414 #define ONIGMO_REGEX_VER 6.2.0 #define VERSION_PATCH XpErImEnTaL diff --git a/uchardet/WinCodePage_Identifiers.txt b/uchardet/WinCodePage_Identifiers.txt new file mode 100644 index 000000000..dfb48da5c --- /dev/null +++ b/uchardet/WinCodePage_Identifiers.txt @@ -0,0 +1,155 @@ + +Identifier .NET Name Additional information +------------------------------------------------------------------------------- + 037 IBM037 IBM EBCDIC US-Canada + 437 IBM437 OEM United States + 500 IBM500 IBM EBCDIC International + 708 ASMO-708 Arabic (ASMO 708) + 709 Arabic (ASMO-449+, BCON V4) + 710 Arabic - Transparent Arabic + 720 DOS-720 Arabic (Transparent ASMO); Arabic (DOS) + 737 ibm737 OEM Greek (formerly 437G); Greek (DOS) + 775 ibm775 OEM Baltic; Baltic (DOS) + 850 ibm850 OEM Multilingual Latin 1; Western European (DOS) + 852 ibm852 OEM Latin 2; Central European (DOS) + 855 IBM855 OEM Cyrillic (primarily Russian) + 857 ibm857 OEM Turkish; Turkish (DOS) + 858 IBM00858 OEM Multilingual Latin 1 + Euro symbol + 860 IBM860 OEM Portuguese; Portuguese (DOS) + 861 ibm861 OEM Icelandic; Icelandic (DOS) + 862 DOS-862 OEM Hebrew; Hebrew (DOS) + 863 IBM863 OEM French Canadian; French Canadian (DOS) + 864 IBM864 OEM Arabic; Arabic (864) + 865 IBM865 OEM Nordic; Nordic (DOS) + 866 cp866 OEM Russian; Cyrillic (DOS) + 869 ibm869 OEM Modern Greek; Greek, Modern (DOS) + 870 IBM870 IBM EBCDIC Multilingual/ROECE (Latin 2); IBM EBCDIC Multilingual Latin 2 + 874 windows-874 ANSI/OEM Thai (ISO 8859-11); Thai (Windows) + 875 cp875 IBM EBCDIC Greek Modern + 932 shift_jis ANSI/OEM Japanese; Japanese (Shift-JIS) + 936 gb2312 ANSI/OEM Simplified Chinese (PRC, Singapore); Chinese Simplified (GB2312) + 949 ks_c_5601-1987 ANSI/OEM Korean (Unified Hangul Code) + 950 big5 ANSI/OEM Traditional Chinese (Taiwan; Hong Kong SAR, PRC); Chinese Traditional (Big5) + 1026 IBM1026 IBM EBCDIC Turkish (Latin 5) + 1047 IBM01047 IBM EBCDIC Latin 1/Open System + 1140 IBM01140 IBM EBCDIC US-Canada (037 + Euro symbol); IBM EBCDIC (US-Canada-Euro) + 1141 IBM01141 IBM EBCDIC Germany (20273 + Euro symbol); IBM EBCDIC (Germany-Euro) + 1142 IBM01142 IBM EBCDIC Denmark-Norway (20277 + Euro symbol); IBM EBCDIC (Denmark-Norway-Euro) + 1143 IBM01143 IBM EBCDIC Finland-Sweden (20278 + Euro symbol); IBM EBCDIC (Finland-Sweden-Euro) + 1144 IBM01144 IBM EBCDIC Italy (20280 + Euro symbol); IBM EBCDIC (Italy-Euro) + 1145 IBM01145 IBM EBCDIC Latin America-Spain (20284 + Euro symbol); IBM EBCDIC (Spain-Euro) + 1146 IBM01146 IBM EBCDIC United Kingdom (20285 + Euro symbol); IBM EBCDIC (UK-Euro) + 1147 IBM01147 IBM EBCDIC France (20297 + Euro symbol); IBM EBCDIC (France-Euro) + 1148 IBM01148 IBM EBCDIC International (500 + Euro symbol); IBM EBCDIC (International-Euro) + 1149 IBM01149 IBM EBCDIC Icelandic (20871 + Euro symbol); IBM EBCDIC (Icelandic-Euro) + 1200 utf-16 Unicode UTF-16, little endian byte order (BMP of ISO 10646); available only to managed applications + 1201 unicodeFFFE Unicode UTF-16, big endian byte order; available only to managed applications + 1250 windows-1250 ANSI Central European; Central European (Windows) + 1251 windows-1251 ANSI Cyrillic; Cyrillic (Windows) + 1252 windows-1252 ANSI Latin 1; Western European (Windows) + 1253 windows-1253 ANSI Greek; Greek (Windows) + 1254 windows-1254 ANSI Turkish; Turkish (Windows) + 1255 windows-1255 ANSI Hebrew; Hebrew (Windows) + 1256 windows-1256 ANSI Arabic; Arabic (Windows) + 1257 windows-1257 ANSI Baltic; Baltic (Windows) + 1258 windows-1258 ANSI/OEM Vietnamese; Vietnamese (Windows) + 1361 Johab Korean (Johab) +10000 macintosh MAC Roman; Western European (Mac) +10001 x-mac-japanese Japanese (Mac) +10002 x-mac-chinesetrad MAC Traditional Chinese (Big5); Chinese Traditional (Mac) +10003 x-mac-korean Korean (Mac) +10004 x-mac-arabic Arabic (Mac) +10005 x-mac-hebrew Hebrew (Mac) +10006 x-mac-greek Greek (Mac) +10007 x-mac-cyrillic Cyrillic (Mac) +10008 x-mac-chinesesimp MAC Simplified Chinese (GB 2312); Chinese Simplified (Mac) +10010 x-mac-romanian Romanian (Mac) +10017 x-mac-ukrainian Ukrainian (Mac) +10021 x-mac-thai Thai (Mac) +10029 x-mac-ce MAC Latin 2; Central European (Mac) +10079 x-mac-icelandic Icelandic (Mac) +10081 x-mac-turkish Turkish (Mac) +10082 x-mac-croatian Croatian (Mac) +12000 utf-32 Unicode UTF-32, little endian byte order; available only to managed applications +12001 utf-32BE Unicode UTF-32, big endian byte order; available only to managed applications +20000 x-Chinese_CNS CNS Taiwan; Chinese Traditional (CNS) +20001 x-cp20001 TCA Taiwan +20002 x_Chinese-Eten Eten Taiwan; Chinese Traditional (Eten) +20003 x-cp20003 IBM5550 Taiwan +20004 x-cp20004 TeleText Taiwan +20005 x-cp20005 Wang Taiwan +20105 x-IA5 IA5 (IRV International Alphabet No. 5, 7-bit); Western European (IA5) +20106 x-IA5-German IA5 German (7-bit) +20107 x-IA5-Swedish IA5 Swedish (7-bit) +20108 x-IA5-Norwegian IA5 Norwegian (7-bit) +20127 us-ascii US-ASCII (7-bit) +20261 x-cp20261 T.61 +20269 x-cp20269 ISO 6937 Non-Spacing Accent +20273 IBM273 IBM EBCDIC Germany +20277 IBM277 IBM EBCDIC Denmark-Norway +20278 IBM278 IBM EBCDIC Finland-Sweden +20280 IBM280 IBM EBCDIC Italy +20284 IBM284 IBM EBCDIC Latin America-Spain +20285 IBM285 IBM EBCDIC United Kingdom +20290 IBM290 IBM EBCDIC Japanese Katakana Extended +20297 IBM297 IBM EBCDIC France +20420 IBM420 IBM EBCDIC Arabic +20423 IBM423 IBM EBCDIC Greek +20424 IBM424 IBM EBCDIC Hebrew +20833 x-EBCDIC-KoreanExtended IBM EBCDIC Korean Extended +20838 IBM-Thai IBM EBCDIC Thai +20866 koi8-r Russian (KOI8-R); Cyrillic (KOI8-R) +20871 IBM871 IBM EBCDIC Icelandic +20880 IBM880 IBM EBCDIC Cyrillic Russian +20905 IBM905 IBM EBCDIC Turkish +20924 IBM00924 IBM EBCDIC Latin 1/Open System (1047 + Euro symbol) +20932 EUC-JP Japanese (JIS 0208-1990 and 0212-1990) +20936 x-cp20936 Simplified Chinese (GB2312); Chinese Simplified (GB2312-80) +20949 x-cp20949 Korean Wansung +21025 cp1025 IBM EBCDIC Cyrillic Serbian-Bulgarian +21027 (deprecated) +21866 koi8-u Ukrainian (KOI8-U); Cyrillic (KOI8-U) +28591 iso-8859-1 ISO 8859-1 Latin 1; Western European (ISO) +28592 iso-8859-2 ISO 8859-2 Central European; Central European (ISO) +28593 iso-8859-3 ISO 8859-3 Latin 3 +28594 iso-8859-4 ISO 8859-4 Baltic +28595 iso-8859-5 ISO 8859-5 Cyrillic +28596 iso-8859-6 ISO 8859-6 Arabic +28597 iso-8859-7 ISO 8859-7 Greek +28598 iso-8859-8 ISO 8859-8 Hebrew; Hebrew (ISO-Visual) +28599 iso-8859-9 ISO 8859-9 Turkish +28603 iso-8859-13 ISO 8859-13 Estonian +28605 iso-8859-15 ISO 8859-15 Latin 9 +29001 x-Europa Europa 3 +38598 iso-8859-8-i ISO 8859-8 Hebrew; Hebrew (ISO-Logical) +50220 iso-2022-jp ISO 2022 Japanese with no halfwidth Katakana; Japanese (JIS) +50221 csISO2022JP ISO 2022 Japanese with halfwidth Katakana; Japanese (JIS-Allow 1 byte Kana) +50222 iso-2022-jp ISO 2022 Japanese JIS X 0201-1989; Japanese (JIS-Allow 1 byte Kana - SO/SI) +50225 iso-2022-kr ISO 2022 Korean +50227 x-cp50227 ISO 2022 Simplified Chinese; Chinese Simplified (ISO 2022) +50229 ISO 2022 Traditional Chinese +50930 EBCDIC Japanese (Katakana) Extended +50931 EBCDIC US-Canada and Japanese +50933 EBCDIC Korean Extended and Korean +50935 EBCDIC Simplified Chinese Extended and Simplified Chinese +50936 EBCDIC Simplified Chinese +50937 EBCDIC US-Canada and Traditional Chinese +50939 EBCDIC Japanese (Latin) Extended and Japanese +51932 euc-jp EUC Japanese +51936 EUC-CN EUC Simplified Chinese; Chinese Simplified (EUC) +51949 euc-kr EUC Korean +51950 EUC Traditional Chinese +52936 hz-gb-2312 HZ-GB2312 Simplified Chinese; Chinese Simplified (HZ) +54936 GB18030 Windows XP and later: GB18030 Simplified Chinese (4 byte); Chinese Simplified (GB18030) +57002 x-iscii-de ISCII Devanagari +57003 x-iscii-be ISCII Bangla +57004 x-iscii-ta ISCII Tamil +57005 x-iscii-te ISCII Telugu +57006 x-iscii-as ISCII Assamese +57007 x-iscii-or ISCII Odia +57008 x-iscii-ka ISCII Kannada +57009 x-iscii-ma ISCII Malayalam +57010 x-iscii-gu ISCII Gujarati +57011 x-iscii-pa ISCII Punjabi +65000 utf-7 Unicode (UTF-7) +65001 utf-8 Unicode (UTF-8) diff --git a/uchardet/uchardet/src/CharDistribution.cpp b/uchardet/uchardet/src/CharDistribution.cpp index 488d9bc3c..abf426712 100644 --- a/uchardet/uchardet/src/CharDistribution.cpp +++ b/uchardet/uchardet/src/CharDistribution.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -42,6 +42,7 @@ #include "EUCKRFreq.tab" #include "EUCTWFreq.tab" #include "GB2312Freq.tab" +//#include "GB18030Freq.tab" #define SURE_YES 0.99f #define SURE_NO 0.01f @@ -86,6 +87,13 @@ GB2312DistributionAnalysis::GB2312DistributionAnalysis() mTypicalDistributionRatio = GB2312_TYPICAL_DISTRIBUTION_RATIO; } +//GB18030DistributionAnalysis::GB18030DistributionAnalysis() +//{ +// mCharToFreqOrder = GB18030CharToFreqOrder; +// mTableSize = GB18030_TABLE_SIZE; +// mTypicalDistributionRatio = GB18030_TYPICAL_DISTRIBUTION_RATIO; +//} + Big5DistributionAnalysis::Big5DistributionAnalysis() { mCharToFreqOrder = Big5CharToFreqOrder; diff --git a/uchardet/uchardet/src/CharDistribution.h b/uchardet/uchardet/src/CharDistribution.h index 8705d3cbe..99410d22e 100644 --- a/uchardet/uchardet/src/CharDistribution.h +++ b/uchardet/uchardet/src/CharDistribution.h @@ -167,14 +167,32 @@ protected: // first byte range: 0xb0 -- 0xfe // second byte range: 0xa1 -- 0xfe //no validation needed here. State machine has done that - PRInt32 GetOrder(const char* str) - { if ((unsigned char)*str >= (unsigned char)0xb0 && (unsigned char)str[1] >= (unsigned char)0xa1) - return 94*((unsigned char)str[0]-(unsigned char)0xb0) + (unsigned char)str[1] - (unsigned char)0xa1; + PRInt32 GetOrder(const char* str) + { + if ((unsigned char)* str >= (unsigned char)0xb0 && (unsigned char)str[1] >= (unsigned char)0xa1) + return 94 * ((unsigned char)str[0] - (unsigned char)0xb0) + (unsigned char)str[1] - (unsigned char)0xa1; else return -1; } }; +class GB18030DistributionAnalysis : public CharDistributionAnalysis +{ +public: + GB18030DistributionAnalysis(); +protected: + //for GB18030 encoding, we are interested + // first byte range: 0xb0 -- 0xfe + // second byte range: 0xa1 -- 0xfe + //no validation needed here. State machine has done that + PRInt32 GetOrder(const char* str) + { + if ((unsigned char)* str >= (unsigned char)0xb0 && (unsigned char)str[1] >= (unsigned char)0xa1) + return 94 * ((unsigned char)str[0] - (unsigned char)0xb0) + (unsigned char)str[1] - (unsigned char)0xa1; + else + return -1; + } +}; class Big5DistributionAnalysis : public CharDistributionAnalysis { @@ -188,7 +206,7 @@ protected: PRInt32 GetOrder(const char* str) { if ((unsigned char)*str >= (unsigned char)0xa4) if ((unsigned char)str[1] >= (unsigned char)0xa1) - return 157*((unsigned char)str[0]-(unsigned char)0xa4) + (unsigned char)str[1] - (unsigned char)0xa1 +63; + return 157*((unsigned char)str[0]-(unsigned char)0xa4) + (unsigned char)str[1] - (unsigned char)0xa1 + 63; else return 157*((unsigned char)str[0]-(unsigned char)0xa4) + (unsigned char)str[1] - (unsigned char)0x40; else diff --git a/uchardet/uchardet/src/EUCTWFreq.tab b/uchardet/uchardet/src/EUCTWFreq.tab index 39f9d9771..3a189ae04 100644 --- a/uchardet/uchardet/src/EUCTWFreq.tab +++ b/uchardet/uchardet/src/EUCTWFreq.tab @@ -57,7 +57,7 @@ #define EUCTW_TYPICAL_DISTRIBUTION_RATIO (float)0.75 //Char to FreqOrder table , -#define EUCTW_TABLE_SIZE 5376 +#define EUCTW_TABLE_SIZE 8102 static const PRInt16 EUCTWCharToFreqOrder[] = { diff --git a/uchardet/uchardet/src/GB18030Freq.tab b/uchardet/uchardet/src/GB18030Freq.tab new file mode 100644 index 000000000..28a8a45c2 --- /dev/null +++ b/uchardet/uchardet/src/GB18030Freq.tab @@ -0,0 +1,492 @@ +/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* ***** BEGIN LICENSE BLOCK ***** + * Version: MPL 1.1/GPL 2.0/LGPL 2.1 + * + * The contents of this file are subject to the Mozilla Public License Version + * 1.1 (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * http://www.mozilla.org/MPL/ + * + * Software distributed under the License is distributed on an "AS IS" basis, + * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License + * for the specific language governing rights and limitations under the + * License. + * + * The Original Code is Mozilla Communicator client code. + * + * The Initial Developer of the Original Code is + * Netscape Communications Corporation. + * Portions created by the Initial Developer are Copyright (C) 1998 + * the Initial Developer. All Rights Reserved. + * + * Contributor(s): + * + * Alternatively, the contents of this file may be used under the terms of + * either the GNU General Public License Version 2 or later (the "GPL"), or + * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), + * in which case the provisions of the GPL or the LGPL are applicable instead + * of those above. If you wish to allow use of your version of this file only + * under the terms of either the GPL or the LGPL, and not to allow others to + * use your version of this file under the terms of the MPL, indicate your + * decision by deleting the provisions above and replace them with the notice + * and other provisions required by the GPL or the LGPL. If you do not delete + * the provisions above, a recipient may use your version of this file under + * the terms of any one of the MPL, the GPL or the LGPL. + * + * ***** END LICENSE BLOCK ***** */ + +//GB18030 most frequently used character table + + +//Char to FreqOrder table , from hz6763 + +/****************************************************************************** + * 512 --> 0.79 -- 0.79 + * 1024 --> 0.92 -- 0.13 + * 2048 --> 0.98 -- 0.06 + * 6768 --> 1.00 -- 0.02 + * + * Idea Distribution Ratio = 0.79135/(1-0.79135) = 3.79 + * Random Distribution Ration = 512 / (3755 - 512) = 0.157 + * + * Typical Distribution Ratio about 25% of Ideal one, still much higher that RDR + *****************************************************************************/ + +#define GB18030_TYPICAL_DISTRIBUTION_RATIO (float)0.9 + +#define GB18030_TABLE_SIZE 3760 + +static const PRInt16 GB18030CharToFreqOrder[] = +{ +1671, 749,1443,2364,3924,3807,2330,3921,1704,3463,2691,1511,1515, 572,3191,2205, +2361, 224,2558, 479,1711, 963,3162, 440,4060,1905,2966,2947,3580,2647,3961,3842, +2204, 869,4207, 970,2678,5626,2944,2956,1479,4048, 514,3595, 588,1346,2820,3409, + 249,4088,1746,1873,2047,1774, 581,1813, 358,1174,3590,1014,1561,4844,2245, 670, +1636,3112, 889,1286, 953, 556,2327,3060,1290,3141, 613, 185,3477,1367, 850,3820, +1715,2428,2642,2303,2732,3041,2562,2648,3566,3946,1349, 388,3098,2091,1360,3585, + 152,1687,1539, 738,1559, 59,1232,2925,2267,1388,1249,1741,1679,2960, 151,1566, +1125,1352,4271, 924,4296, 385,3166,4459, 310,1245,2850, 70,3285,2729,3534,3575, +2398,3298,3466,1960,2265, 217,3647, 864,1909,2084,4401,2773,1010,3269,5152, 853, +3051,3121,1244,4251,1895, 364,1499,1540,2313,1180,3655,2268, 562, 715,2417,3061, + 544, 336,3768,2380,1752,4075, 950, 280,2425,4382, 183,2759,3272, 333,4297,2155, +1688,2356,1444,1039,4540, 736,1177,3349,2443,2368,2144,2225, 565, 196,1482,3406, + 927,1335,4147, 692, 878,1311,1653,3911,3622,1378,4200,1840,2969,3149,2126,1816, +2534,1546,2393,2760, 737,2494, 13, 447, 245,2747, 38,2765,2129,2589,1079, 606, + 360, 471,3755,2890, 404, 848, 699,1785,1236, 370,2221,1023,3746,2074,2026,2023, +2388,1581,2119, 812,1141,3091,2536,1519, 804,2053, 406,1596,1090, 784, 548,4414, +1806,2264,2936,1100, 343,4114,5096, 622,3358, 743,3668,1510,1626,5020,3567,2513, +3195,4115,5627,2489,2991, 24,2065,2697,1087,2719, 48,1634, 315, 68, 985,2052, + 198,2239,1347,1107,1439, 597,2366,2172, 871,3307, 919,2487,2790,1867, 236,2570, +1413,3794, 906,3365,3381,1701,1982,1818,1524,2924,1205, 616,2586,2072,2004, 575, + 253,3099, 32,1365,1182, 197,1714,2454,1201, 554,3388,3224,2748, 756,2587, 250, +2567,1507,1517,3529,1922,2761,2337,3416,1961,1677,2452,2238,3153, 615, 911,1506, +1474,2495,1265,1906,2749,3756,3280,2161, 898,2714,1759,3450,2243,2444, 563, 26, +3286,2266,3769,3344,2707,3677, 611,1402, 531,1028,2871,4548,1375, 261,2948, 835, +1190,4134, 353, 840,2684,1900,3082,1435,2109,1207,1674, 329,1872,2781,4055,2686, +2104, 608,3318,2423,2957,2768,1108,3739,3512,3271,3985,2203,1771,3520,1418,2054, +1681,1153, 225,1627,2929, 162,2050,2511,3687,1954, 124,1859,2431,1684,3032,2894, + 585,4805,3969,2869,2704,2088,2032,2095,3656,2635,4362,2209, 256, 518,2042,2105, +3777,3657, 643,2298,1148,1779, 190, 989,3544, 414, 11,2135,2063,2979,1471, 403, +3678, 126, 770,1563, 671,2499,3216,2877, 600,1179, 307,2805,4937,1268,1297,2694, + 252,4032,1448,1494,1331,1394, 127,2256, 222,1647,1035,1481,3056,1915,1048, 873, +3651, 210, 33,1608,2516, 200,1520, 415, 102, 0,3389,1287, 817, 91,3299,2940, + 836,1814, 549,2197,1396,1669,2987,3582,2297,2848,4528,1070, 687, 20,1819, 121, +1552,1364,1461,1968,2617,3540,2824,2083, 177, 948,4938,2291, 110,4549,2066, 648, +3359,1755,2110,2114,4642,4845,1693,3937,3308,1257,1869,2123, 208,1804,3159,2992, +2531,2549,3361,2418,1350,2347,2800,2568,1291,2036,2680, 72, 842,1990, 212,1233, +1154,1586, 75,2027,3410,4900,1823,1337,2710,2676, 728,2810,1522,3026,4995, 157, + 755,1050,4022, 710, 785,1936,2194,2085,1406,2777,2400, 150,1250,4049,1206, 807, +1910, 534, 529,3309,1721,1660, 274, 39,2827, 661,2670,1578, 925,3248,3815,1094, +4278,4901,4252, 41,1150,3747,2572,2227,4501,3658,4902,3813,3357,3617,2884,2258, + 887, 538,4187,3199,1294,2439,3042,2329,2343,2497,1255, 107, 543,1527, 521,3478, +3568, 194,5062, 15, 961,3870,1241,1192,2664, 66,5215,3260,2111,1295,1127,2152, +3805,4135, 901,1164,1976, 398,1278, 530,1460, 748, 904,1054,1966,1426, 53,2909, + 509, 523,2279,1534, 536,1019, 239,1685, 460,2353, 673,1065,2401,3600,4298,2272, +1272,2363, 284,1753,3679,4064,1695, 81, 815,2677,2757,2731,1386, 859, 500,4221, +2190,2566, 757,1006,2519,2068,1166,1455, 337,2654,3203,1863,1682,1914,3025,1252, +1409,1366, 847, 714,2834,2038,3209, 964,2970,1901, 885,2553,1078,1756,3049, 301, +1572,3326, 688,2130,1996,2429,1805,1648,2930,3421,2750,3652,3088, 262,1158,1254, + 389,1641,1812, 526,1719, 923,2073,1073,1902, 468, 489,4625,1140, 857,2375,3070, +3319,2863, 380, 116,1328,2693,1161,2244, 273,1212,1884,2769,3011,1775,1142, 461, +3066,1200,2147,2212, 790, 702,2695,4222,1601,1058, 434,2338,5153,3640, 67,2360, +4099,2502, 618,3472,1329, 416,1132, 830,2782,1807,2653,3211,3510,1662, 192,2124, + 296,3979,1739,1611,3684, 23, 118, 324, 446,1239,1225, 293,2520,3814,3795,2535, +3116, 17,1074, 467,2692,2201, 387,2922, 45,1326,3055,1645,3659,2817, 958, 243, +1903,2320,1339,2825,1784,3289, 356, 576, 865,2315,2381,3377,3916,1088,3122,1713, +1655, 935, 628,4689,1034,1327, 441, 800, 720, 894,1979,2183,1528,5289,2702,1071, +4046,3572,2399,1571,3281, 79, 761,1103, 327, 134, 758,1899,1371,1615, 879, 442, + 215,2605,2579, 173,2048,2485,1057,2975,3317,1097,2253,3801,4263,1403,1650,2946, + 814,4968,3487,1548,2644,1567,1285, 2, 295,2636, 97, 946,3576, 832, 141,4257, +3273, 760,3821,3521,3156,2607, 949,1024,1733,1516,1803,1920,2125,2283,2665,3180, +1501,2064,3560,2171,1592, 803,3518,1416, 732,3897,4258,1363,1362,2458, 119,1427, + 602,1525,2608,1605,1639,3175, 694,3064, 10, 465, 76,2000,4846,4208, 444,3781, +1619,3353,2206,1273,3796, 740,2483, 320,1723,2377,3660,2619,1359,1137,1762,1724, +2345,2842,1850,1862, 912, 821,1866, 612,2625,1735,2573,3369,1093, 844, 89, 937, + 930,1424,3564,2413,2972,1004,3046,3019,2011, 711,3171,1452,4178, 428, 801,1943, + 432, 445,2811, 206,4136,1472, 730, 349, 73, 397,2802,2547, 998,1637,1167, 789, + 396,3217, 154,1218, 716,1120,1780,2819,4826,1931,3334,3762,2139,1215,2627, 552, +3664,3628,3232,1405,2383,3111,1356,2652,3577,3320,3101,1703, 640,1045,1370,1246, +4996, 371,1575,2436,1621,2210, 984,4033,1734,2638, 16,4529, 663,2755,3255,1451, +3917,2257,1253,1955,2234,1263,2951, 214,1229, 617, 485, 359,1831,1969, 473,2310, + 750,2058, 165, 80,2864,2419, 361,4344,2416,2479,1134, 796,3726,1266,2943, 860, +2715, 938, 390,2734,1313,1384, 248, 202, 877,1064,2854, 522,3907, 279,1602, 297, +2357, 395,3740, 137,2075, 944,4089,2584,1267,3802, 62,1533,2285, 178, 176, 780, +2440, 201,3707, 590, 478,1560,4354,2117,1075, 30, 74,4643,4004,1635,1441,2745, + 776,2596, 238,1077,1692,1912,2844, 605, 499,1742,3947, 241,3053, 980,1749, 936, +2640,4511,2582, 515,1543,2162,5322,2892,2993, 890,2148,1924, 665,1827,3581,1032, + 968,3163, 339,1044,1896, 270, 583,1791,1720,4367,1194,3488,3669, 43,2523,1657, + 163,2167, 290,1209,1622,3378, 550, 634,2508,2510, 695,2634,2384,2512,1476,1414, + 220,1469,2341,2138,2852,3183,2900,4939,2865,3502,1211,3680, 854,3227,1299,2976, +3172, 186,2998,1459, 443,1067,3251,1495, 321,1932,3054, 909, 753,1410,1828, 436, +2441,1119,1587,3164,2186,1258, 227, 231,1425,1890,3200,3942, 247, 959, 725,5254, +2741, 577,2158,2079, 929, 120, 174, 838,2813, 591,1115, 417,2024, 40,3240,1536, +1037, 291,4151,2354, 632,1298,2406,2500,3535,1825,1846,3451, 205,1171, 345,4238, + 18,1163, 811, 685,2208,1217, 425,1312,1508,1175,4308,2552,1033, 587,1381,3059, +2984,3482, 340,1316,4023,3972, 792,3176, 519, 777,4690, 918, 933,4130,2981,3741, + 90,3360,2911,2200,5184,4550, 609,3079,2030, 272,3379,2736, 363,3881,1130,1447, + 286, 779, 357,1169,3350,3137,1630,1220,2687,2391, 747,1277,3688,2618,2682,2601, +1156,3196,5290,4034,3102,1689,3596,3128, 874, 219,2783, 798, 508,1843,2461, 269, +1658,1776,1392,1913,2983,3287,2866,2159,2372, 829,4076, 46,4253,2873,1889,1894, + 915,1834,1631,2181,2318, 298, 664,2818,3555,2735, 954,3228,3117, 527,3511,2173, + 681,2712,3033,2247,2346,3467,1652, 155,2164,3382, 113,1994, 450, 899, 494, 994, +1237,2958,1875,2336,1926,3727, 545,1577,1550, 633,3473, 204,1305,3072,2410,1956, +2471, 707,2134, 841,2195,2196,2663,3843,1026,4940, 990,3252,4997, 368,1092, 437, +3212,3258,1933,1829, 675,2977,2893, 412, 943,3723,4644,3294,3283,2230,2373,5154, +2389,2241,2661,2323,1404,2524, 593, 787, 677,3008,1275,2059, 438,2709,2609,2240, +2269,2246,1446, 36,1568,1373,3892,1574,2301,1456,3962, 693,2276,5216,2035,1143, +2720,1919,1797,1811,2763,4137,2597,1830,1699,1488,1198,2090, 424,1694, 312,3634, +3390,4179,3335,2252,1214, 561,1059,3243,2295,2561, 975,5155,2321,2751,3772, 472, +1537,3282,3398,1047,2077,2348,2878,1323,3340,3076, 690,2906, 51, 369, 170,3541, +1060,2187,2688,3670,2541,1083,1683, 928,3918, 459, 109,4427, 599,3744,4286, 143, +2101,2730,2490, 82,1588,3036,2121, 281,1860, 477,4035,1238,2812,3020,2716,3312, +1530,2188,2055,1317, 843, 636,1808,1173,3495, 649, 181,1002, 147,3641,1159,2414, +3750,2289,2795, 813,3123,2610,1136,4368, 5,3391,4541,2174, 420, 429,1728, 754, +1228,2115,2219, 347,2223,2733, 735,1518,3003,2355,3134,1764,3948,3329,1888,2424, +1001,1234,1972,3321,3363,1672,1021,1450,1584, 226, 765, 655,2526,3404,3244,2302, +3665, 731, 594,2184, 319,1576, 621, 658,2656,4299,2099,3864,1279,2071,2598,2739, + 795,3086,3699,3908,1707,2352,2402,1382,3136,2475,1465,4847,3496,3865,1085,3004, +2591,1084, 213,2287,1963,3565,2250, 822, 793,4574,3187,1772,1789,3050, 595,1484, +1959,2770,1080,2650, 456, 422,2996, 940,3322,4328,4345,3092,2742, 965,2784, 739, +4124, 952,1358,2498,2949,2565, 332,2698,2378, 660,2260,2473,4194,3856,2919, 535, +1260,2651,1208,1428,1300,1949,1303,2942, 433,2455,2450,1251,1946, 614,1269, 641, +1306,1810,2737,3078,2912, 564,2365,1419,1415,1497,4460,2367,2185,1379,3005,1307, +3218,2175,1897,3063, 682,1157,4040,4005,1712,1160,1941,1399, 394, 402,2952,1573, +1151,2986,2404, 862, 299,2033,1489,3006, 346, 171,2886,3401,1726,2932, 168,2533, + 47,2507,1030,3735,1145,3370,1395,1318,1579,3609,4560,2857,4116,1457,2529,1965, + 504,1036,2690,2988,2405, 745,5871, 849,2397,2056,3081, 863,2359,3857,2096, 99, +1397,1769,2300,4428,1643,3455,1978,1757,3718,1440, 35,4879,3742,1296,4228,2280, + 160,5063,1599,2013, 166, 520,3479,1646,3345,3012, 490,1937,1545,1264,2182,2505, +1096,1188,1369,1436,2421,1667,2792,2460,1270,2122, 727,3167,2143, 806,1706,1012, +1800,3037, 960,2218,1882, 805, 139,2456,1139,1521, 851,1052,3093,3089, 342,2039, + 744,5097,1468,1502,1585,2087, 223, 939, 326,2140,2577, 892,2481,1623,4077, 982, +3708, 135,2131, 87,2503,3114,2326,1106, 876,1616, 547,2997,2831,2093,3441,4530, +4314, 9,3256,4229,4148, 659,1462,1986,1710,2046,2913,2231,4090,4880,5255,3392, +3274,1368,3689,4645,1477, 705,3384,3635,1068,1529,2941,1458,3782,1509, 100,1656, +2548, 718,2339, 408,1590,2780,3548,1838,4117,3719,1345,3530, 717,3442,2778,3220, +2898,1892,4590,3614,3371,2043,1998,1224,3483, 891, 635, 584,2559,3355, 733,1766, +1729,1172,3789,1891,2307, 781,2982,2271,1957,1580,5773,2633,2005,4195,3097,1535, +3213,1189,1934,5693,3262, 586,3118,1324,1598, 517,1564,2217,1868,1893,4445,3728, +2703,3139,1526,1787,1992,3882,2875,1549,1199,1056,2224,1904,2711,5098,4287, 338, +1993,3129,3489,2689,1809,2815,1997, 957,1855,3898,2550,3275,3057,1105,1319, 627, +1505,1911,1883,3526, 698,3629,3456,1833,1431, 746, 77,1261,2017,2296,1977,1885, + 125,1334,1600, 525,1798,1109,2222,1470,1945, 559,2236,1186,3443,2476,1929,1411, +2411,3135,1777,3372,2621,1841,1613,3229, 668,1430,1839,2643,2916, 195,1989,2671, +2358,1387, 629,3205,2293,5256,4439, 123,1310, 888,1879,4300,3021,3605,1003,1162, +3192,2910,2010, 140,2395,2859, 55,1082,2012,2901, 662, 419,2081,1438, 680,2774, +4654,3912,1620,1731,1625,5035,4065,2328, 512,1344, 802,5443,2163,2311,2537, 524, +3399, 98,1155,2103,1918,2606,3925,2816,1393,2465,1504,3773,2177,3963,1478,4346, + 180,1113,4655,3461,2028,1698, 833,2696,1235,1322,1594,4408,3623,3013,3225,2040, +3022, 541,2881, 607,3632,2029,1665,1219, 639,1385,1686,1099,2803,3231,1938,3188, +2858, 427, 676,2772,1168,2025, 454,3253,2486,3556, 230,1950, 580, 791,1991,1280, +1086,1974,2034, 630, 257,3338,2788,4903,1017, 86,4790, 966,2789,1995,1696,1131, + 259,3095,4188,1308, 179,1463,5257, 289,4107,1248, 42,3413,1725,2288, 896,1947, + 774,4474,4254, 604,3430,4264, 392,2514,2588, 452, 237,1408,3018, 988,4531,1970, +3034,3310, 540,2370,1562,1288,2990, 502,4765,1147, 4,1853,2708, 207, 294,2814, +4078,2902,2509, 684, 34,3105,3532,2551, 644, 709,2801,2344, 573,1727,3573,3557, +2021,1081,3100,4315,2100,3681, 199,2263,1837,2385, 146,3484,1195,2776,3949, 997, +1939,3973,1008,1091,1202,1962,1847,1149,4209,5444,1076, 493, 117,5400,2521, 972, +1490,2934,1796,4542,2374,1512,2933,2657, 413,2888,1135,2762,2314,2156,1355,2369, + 766,2007,2527,2170,3124,2491,2593,2632,4757,2437, 234,3125,3591,1898,1750,1376, +1942,3468,3138, 570,2127,2145,3276,4131, 962, 132,1445,4196, 19, 941,3624,3480, +3366,1973,1374,4461,3431,2629, 283,2415,2275, 808,2887,3620,2112,2563,1353,3610, + 955,1089,3103,1053, 96, 88,4097, 823,3808,1583, 399, 292,4091,3313, 421,1128, + 642,4006, 903,2539,1877,2082, 596, 29,4066,1790, 722,2157, 130, 995,1569, 769, +1485, 464, 513,2213, 288,1923,1101,2453,4316, 133, 486,2445, 50, 625, 487,2207, + 57, 423, 481,2962, 159,3729,1558, 491, 303, 482, 501, 240,2837, 112,3648,2392, +1783, 362, 8,3433,3422, 610,2793,3277,1390,1284,1654, 21,3823, 734, 367, 623, + 193, 287, 374,1009,1483, 816, 476, 313,2255,2340,1262,2150,2899,1146,2581, 782, +2116,1659,2018,1880, 255,3586,3314,1110,2867,2137,2564, 986,2767,5185,2006, 650, + 158, 926, 762, 881,3157,2717,2362,3587, 306,3690,3245,1542,3077,2427,1691,2478, +2118,2985,3490,2438, 539,2305, 983, 129,1754, 355,4201,2386, 827,2923, 104,1773, +2838,2771, 411,2905,3919, 376, 767, 122,1114, 828,2422,1817,3506, 266,3460,1007, +1609,4998, 945,2612,4429,2274, 726,1247,1964,2914,2199,2070,4002,4108, 657,3323, +1422, 579, 455,2764,4737,1222,2895,1670, 824,1223,1487,2525, 558, 861,3080, 598, +2659,2515,1967, 752,2583,2376,2214,4180, 977, 704,2464,4999,2622,4109,1210,2961, + 819,1541, 142,2284, 44, 418, 457,1126,3730,4347,4626,1644,1876,3671,1864, 302, +1063,5694, 624, 723,1984,3745,1314,1676,2488,1610,1449,3558,3569,2166,2098, 409, +1011,2325,3704,2306, 818,1732,1383,1824,1844,3757, 999,2705,3497,1216,1423,2683, +2426,2954,2501,2726,2229,1475,2554,5064,1971,1794,1666,2014,1343, 783, 724, 191, +2434,1354,2220,5065,1763,2752,2472,4152, 131, 175,2885,3434, 92,1466,4920,2616, +3871,3872,3866, 128,1551,1632, 669,1854,3682,4691,4125,1230, 188,2973,3290,1302, +1213, 560,3266, 917, 763,3909,3249,1760, 868,1958, 764,1782,2097, 145,2277,3774, +4462, 64,1491,3062, 971,2132,3606,2442, 221,1226,1617, 218, 323,1185,3207,3147, + 571, 619,1473,1005,1744,2281, 449,1887,2396,3685, 275, 375,3816,1743,3844,3731, + 845,1983,2350,4210,1377, 773, 967,3499,3052,3743,2725,4007,1697,1022,3943,1464, +3264,2855,2722,1952,1029,2839,2467, 84,4383,2215, 820,1391,2015,2448,3672, 377, +1948,2168, 797,2545,3536,2578,2645, 94,2874,1678, 405,1259,3071, 771, 546,1315, + 470,1243,3083, 895,2468, 981, 969,2037, 846,4181, 653,1276,2928, 14,2594, 557, +3007,2474, 156, 902,1338,1740,2574, 537,2518, 973,2282,2216,2433,1928, 138,2903, +1293,2631,1612, 646,3457, 839,2935, 111, 496,2191,2847, 589,3186, 149,3994,2060, +4031,2641,4067,3145,1870, 37,3597,2136,1025,2051,3009,3383,3549,1121,1016,3261, +1301, 251,2446,2599,2153, 872,3246, 637, 334,3705, 831, 884, 921,3065,3140,4092, +2198,1944, 246,2964, 108,2045,1152,1921,2308,1031, 203,3173,4170,1907,3890, 810, +1401,2003,1690, 506, 647,1242,2828,1761,1649,3208,2249,1589,3709,2931,5156,1708, + 498, 666,2613, 834,3817,1231, 184,2851,1124, 883,3197,2261,3710,1765,1553,2658, +1178,2639,2351, 93,1193, 942,2538,2141,4402, 235,1821, 870,1591,2192,1709,1871, +3341,1618,4126,2595,2334, 603, 651, 69, 701, 268,2662,3411,2555,1380,1606, 503, + 448, 254,2371,2646, 574,1187,2309,1770, 322,2235,1292,1801, 305, 566,1133, 229, +2067,2057, 706, 167, 483,2002,2672,3295,1820,3561,3067, 316, 378,2746,3452,1112, + 136,1981, 507,1651,2917,1117, 285,4591, 182,2580,3522,1304, 335,3303,1835,2504, +1795,1792,2248, 674,1018,2106,2449,1857,2292,2845, 976,3047,1781,2600,2727,1389, +1281, 52,3152, 153, 265,3950, 672,3485,3951,4463, 430,1183, 365, 278,2169, 27, +1407,1336,2304, 209,1340,1730,2202,1852,2403,2883, 979,1737,1062, 631,2829,2542, +3876,2592, 825,2086,2226,3048,3625, 352,1417,3724, 542, 991, 431,1351,3938,1861, +2294, 826,1361,2927,3142,3503,1738, 463,2462,2723, 582,1916,1595,2808, 400,3845, +3891,2868,3621,2254, 58,2492,1123, 910,2160,2614,1372,1603,1196,1072,3385,1700, +3267,1980, 696, 480,2430, 920, 799,1570,2920,1951,2041,4047,2540,1321,4223,2469, +3562,2228,1271,2602, 401,2833,3351,2575,5157, 907,2312,1256, 410, 263,3507,1582, + 996, 678,1849,2316,1480, 908,3545,2237, 703,2322, 667,1826,2849,1531,2604,2999, +2407,3146,2151,2630,1786,3711, 469,3542, 497,3899,2409, 858, 837,4446,3393,1274, + 786, 620,1845,2001,3311, 484, 308,3367,1204,1815,3691,2332,1532,2557,1842,2020, +2724,1927,2333,4440, 567, 22,1673,2728,4475,1987,1858,1144,1597, 101,1832,3601, + 12, 974,3783,4391, 951,1412, 1,3720, 453,4608,4041, 528,1041,1027,3230,2628, +1129, 875,1051,3291,1203,2262,1069,2860,2799,2149,2615,3278, 144,1758,3040, 31, + 475,1680, 366,2685,3184, 311,1642,4008,2466,5036,1593,1493,2809, 216,1420,1668, + 233, 304,2128,3284, 232,1429,1768,1040,2008,3407,2740,2967,2543, 242,2133, 778, +1565,2022,2620, 505,2189,2756,1098,2273, 372,1614, 708, 553,2846,2094,2278, 169, +3626,2835,4161, 228,2674,3165, 809,1454,1309, 466,1705,1095, 900,3423, 880,2667, +3751,5258,2317,3109,2571,4317,2766,1503,1342, 866,4447,1118, 63,2076, 314,1881, +1348,1061, 172, 978,3515,1747, 532, 511,3970, 6, 601, 905,2699,3300,1751, 276, +1467,3725,2668, 65,4239,2544,2779,2556,1604, 578,2451,1802, 992,2331,2624,1320, +3446, 713,1513,1013, 103,2786,2447,1661, 886,1702, 916, 654,3574,2031,1556, 751, +2178,2821,2179,1498,1538,2176, 271, 914,2251,2080,1325, 638,1953,2937,3877,2432, +2754, 95,3265,1716, 260,1227,4083, 775, 106,1357,3254, 426,1607, 555,2480, 772, +1985, 244,2546, 474, 495,1046,2611,1851,2061, 71,2089,1675,2590, 742,3758,2843, +3222,1433, 267,2180,2576,2826,2233,2092,3913,2435, 956,1745,3075, 856,2113,1116, + 451, 3,1988,2896,1398, 993,2463,1878,2049,1341,2718,2721,2870,2108, 712,2904, +4363,2753,2324, 277,2872,2349,2649, 384, 987, 435, 691,3000, 922, 164,3939, 652, +1500,1184,4153,2482,3373,2165,4848,2335,3775,3508,3154,2806,2830,1554,2102,1664, +2530,1434,2408, 893,1547,2623,3447,2832,2242,2532,3169,2856,3223,2078, 49,3770, +3469, 462, 318, 656,2259,3250,3069, 679,1629,2758, 344,1138,1104,3120,1836,1283, +3115,2154,1437,4448, 934, 759,1999, 794,2862,1038, 533,2560,1722,2342, 855,2626, +1197,1663,4476,3127, 85,4240,2528, 25,1111,1181,3673, 407,3470,4561,2679,2713, + 768,1925,2841,3986,1544,1165, 932, 373,1240,2146,1930,2673, 721,4766, 354,4333, + 391,2963, 187, 61,3364,1442,1102, 330,1940,1767, 341,3809,4118, 393,2496,2062, +2211, 105, 331, 300, 439, 913,1332, 626, 379,3304,1557, 328, 689,3952, 309,1555, + 931, 317,2517,3027, 325, 569, 686,2107,3084, 60,1042,1333,2794, 264,3177,4014, +1628, 258,3712, 7,4464,1176,1043,1778, 683, 114,1975, 78,1492, 383,1886, 510, + 386, 645,5291,2891,2069,3305,4138,3867,2939,2603,2493,1935,1066,1848,3588,1015, +1282,1289,4609, 697,1453,3044,2666,3611,1856,2412, 54, 719,1330, 568,3778,2459, +1748, 788, 492, 551,1191,1000, 488,3394,3763, 282,1799, 348,2016,1523,3155,2390, +1049, 382,2019,1788,1170, 729,2968,3523, 897,3926,2785,2938,3292, 350,2319,3238, +1718,1717,2655,3453,3143,4465, 161,2889,2980,2009,1421, 56,1908,1640,2387,2232, +1917,1874,2477,4921, 148, 83,3438, 592,4245,2882,1822,1055, 741, 115,1496,1624, + 381,1638,4592,1020, 516,3214, 458, 947,4575,1432, 211,1514,2926,1865,2142, 189, + 852,1221,1400,1486, 882,2299,4036, 351, 28,1122, 700,6479,6480,6481,6482,6483, //last 512 + +/*************************************************************************************** + *Everything below is of no interest for detection purpose * + *************************************************************************************** + +5508,6484,3900,3414,3974,4441,4024,3537,4037,5628,5099,3633,6485,3148,6486,3636, +5509,3257,5510,5973,5445,5872,4941,4403,3174,4627,5873,6276,2286,4230,5446,5874, +5122,6102,6103,4162,5447,5123,5323,4849,6277,3980,3851,5066,4246,5774,5067,6278, +3001,2807,5695,3346,5775,5974,5158,5448,6487,5975,5976,5776,3598,6279,5696,4806, +4211,4154,6280,6488,6489,6490,6281,4212,5037,3374,4171,6491,4562,4807,4722,4827, +5977,6104,4532,4079,5159,5324,5160,4404,3858,5359,5875,3975,4288,4610,3486,4512, +5325,3893,5360,6282,6283,5560,2522,4231,5978,5186,5449,2569,3878,6284,5401,3578, +4415,6285,4656,5124,5979,2506,4247,4449,3219,3417,4334,4969,4329,6492,4576,4828, +4172,4416,4829,5402,6286,3927,3852,5361,4369,4830,4477,4867,5876,4173,6493,6105, +4657,6287,6106,5877,5450,6494,4155,4868,5451,3700,5629,4384,6288,6289,5878,3189, +4881,6107,6290,6495,4513,6496,4692,4515,4723,5100,3356,6497,6291,3810,4080,5561, +3570,4430,5980,6498,4355,5697,6499,4724,6108,6109,3764,4050,5038,5879,4093,3226, +6292,5068,5217,4693,3342,5630,3504,4831,4377,4466,4309,5698,4431,5777,6293,5778, +4272,3706,6110,5326,3752,4676,5327,4273,5403,4767,5631,6500,5699,5880,3475,5039, +6294,5562,5125,4348,4301,4482,4068,5126,4593,5700,3380,3462,5981,5563,3824,5404, +4970,5511,3825,4738,6295,6501,5452,4516,6111,5881,5564,6502,6296,5982,6503,4213, +4163,3454,6504,6112,4009,4450,6113,4658,6297,6114,3035,6505,6115,3995,4904,4739, +4563,4942,4110,5040,3661,3928,5362,3674,6506,5292,3612,4791,5565,4149,5983,5328, +5259,5021,4725,4577,4564,4517,4364,6298,5405,4578,5260,4594,4156,4157,5453,3592, +3491,6507,5127,5512,4709,4922,5984,5701,4726,4289,6508,4015,6116,5128,4628,3424, +4241,5779,6299,4905,6509,6510,5454,5702,5780,6300,4365,4923,3971,6511,5161,3270, +3158,5985,4100, 867,5129,5703,6117,5363,3695,3301,5513,4467,6118,6512,5455,4232, +4242,4629,6513,3959,4478,6514,5514,5329,5986,4850,5162,5566,3846,4694,6119,5456, +4869,5781,3779,6301,5704,5987,5515,4710,6302,5882,6120,4392,5364,5705,6515,6121, +6516,6517,3736,5988,5457,5989,4695,2457,5883,4551,5782,6303,6304,6305,5130,4971, +6122,5163,6123,4870,3263,5365,3150,4871,6518,6306,5783,5069,5706,3513,3498,4409, +5330,5632,5366,5458,5459,3991,5990,4502,3324,5991,5784,3696,4518,5633,4119,6519, +4630,5634,4417,5707,4832,5992,3418,6124,5993,5567,4768,5218,6520,4595,3458,5367, +6125,5635,6126,4202,6521,4740,4924,6307,3981,4069,4385,6308,3883,2675,4051,3834, +4302,4483,5568,5994,4972,4101,5368,6309,5164,5884,3922,6127,6522,6523,5261,5460, +5187,4164,5219,3538,5516,4111,3524,5995,6310,6311,5369,3181,3386,2484,5188,3464, +5569,3627,5708,6524,5406,5165,4677,4492,6312,4872,4851,5885,4468,5996,6313,5709, +5710,6128,2470,5886,6314,5293,4882,5785,3325,5461,5101,6129,5711,5786,6525,4906, +6526,6527,4418,5887,5712,4808,2907,3701,5713,5888,6528,3765,5636,5331,6529,6530, +3593,5889,3637,4943,3692,5714,5787,4925,6315,6130,5462,4405,6131,6132,6316,5262, +6531,6532,5715,3859,5716,5070,4696,5102,3929,5788,3987,4792,5997,6533,6534,3920, +4809,5000,5998,6535,2974,5370,6317,5189,5263,5717,3826,6536,3953,5001,4883,3190, +5463,5890,4973,5999,4741,6133,6134,3607,5570,6000,4711,3362,3630,4552,5041,6318, +6001,2950,2953,5637,4646,5371,4944,6002,2044,4120,3429,6319,6537,5103,4833,6538, +6539,4884,4647,3884,6003,6004,4758,3835,5220,5789,4565,5407,6540,6135,5294,4697, +4852,6320,6321,3206,4907,6541,6322,4945,6542,6136,6543,6323,6005,4631,3519,6544, +5891,6545,5464,3784,5221,6546,5571,4659,6547,6324,6137,5190,6548,3853,6549,4016, +4834,3954,6138,5332,3827,4017,3210,3546,4469,5408,5718,3505,4648,5790,5131,5638, +5791,5465,4727,4318,6325,6326,5792,4553,4010,4698,3439,4974,3638,4335,3085,6006, +5104,5042,5166,5892,5572,6327,4356,4519,5222,5573,5333,5793,5043,6550,5639,5071, +4503,6328,6139,6551,6140,3914,3901,5372,6007,5640,4728,4793,3976,3836,4885,6552, +4127,6553,4451,4102,5002,6554,3686,5105,6555,5191,5072,5295,4611,5794,5296,6556, +5893,5264,5894,4975,5466,5265,4699,4976,4370,4056,3492,5044,4886,6557,5795,4432, +4769,4357,5467,3940,4660,4290,6141,4484,4770,4661,3992,6329,4025,4662,5022,4632, +4835,4070,5297,4663,4596,5574,5132,5409,5895,6142,4504,5192,4664,5796,5896,3885, +5575,5797,5023,4810,5798,3732,5223,4712,5298,4084,5334,5468,6143,4052,4053,4336, +4977,4794,6558,5335,4908,5576,5224,4233,5024,4128,5469,5225,4873,6008,5045,4729, +4742,4633,3675,4597,6559,5897,5133,5577,5003,5641,5719,6330,6560,3017,2382,3854, +4406,4811,6331,4393,3964,4946,6561,2420,3722,6562,4926,4378,3247,1736,4442,6332, +5134,6333,5226,3996,2918,5470,4319,4003,4598,4743,4744,4485,3785,3902,5167,5004, +5373,4394,5898,6144,4874,1793,3997,6334,4085,4214,5106,5642,4909,5799,6009,4419, +4189,3330,5899,4165,4420,5299,5720,5227,3347,6145,4081,6335,2876,3930,6146,3293, +3786,3910,3998,5900,5300,5578,2840,6563,5901,5579,6147,3531,5374,6564,6565,5580, +4759,5375,6566,6148,3559,5643,6336,6010,5517,6337,6338,5721,5902,3873,6011,6339, +6567,5518,3868,3649,5722,6568,4771,4947,6569,6149,4812,6570,2853,5471,6340,6341, +5644,4795,6342,6012,5723,6343,5724,6013,4349,6344,3160,6150,5193,4599,4514,4493, +5168,4320,6345,4927,3666,4745,5169,5903,5005,4928,6346,5725,6014,4730,4203,5046, +4948,3395,5170,6015,4150,6016,5726,5519,6347,5047,3550,6151,6348,4197,4310,5904, +6571,5581,2965,6152,4978,3960,4291,5135,6572,5301,5727,4129,4026,5905,4853,5728, +5472,6153,6349,4533,2700,4505,5336,4678,3583,5073,2994,4486,3043,4554,5520,6350, +6017,5800,4487,6351,3931,4103,5376,6352,4011,4321,4311,4190,5136,6018,3988,3233, +4350,5906,5645,4198,6573,5107,3432,4191,3435,5582,6574,4139,5410,6353,5411,3944, +5583,5074,3198,6575,6354,4358,6576,5302,4600,5584,5194,5412,6577,6578,5585,5413, +5303,4248,5414,3879,4433,6579,4479,5025,4854,5415,6355,4760,4772,3683,2978,4700, +3797,4452,3965,3932,3721,4910,5801,6580,5195,3551,5907,3221,3471,3029,6019,3999, +5908,5909,5266,5267,3444,3023,3828,3170,4796,5646,4979,4259,6356,5647,5337,3694, +6357,5648,5338,4520,4322,5802,3031,3759,4071,6020,5586,4836,4386,5048,6581,3571, +4679,4174,4949,6154,4813,3787,3402,3822,3958,3215,3552,5268,4387,3933,4950,4359, +6021,5910,5075,3579,6358,4234,4566,5521,6359,3613,5049,6022,5911,3375,3702,3178, +4911,5339,4521,6582,6583,4395,3087,3811,5377,6023,6360,6155,4027,5171,5649,4421, +4249,2804,6584,2270,6585,4000,4235,3045,6156,5137,5729,4140,4312,3886,6361,4330, +6157,4215,6158,3500,3676,4929,4331,3713,4930,5912,4265,3776,3368,5587,4470,4855, +3038,4980,3631,6159,6160,4132,4680,6161,6362,3923,4379,5588,4255,6586,4121,6587, +6363,4649,6364,3288,4773,4774,6162,6024,6365,3543,6588,4274,3107,3737,5050,5803, +4797,4522,5589,5051,5730,3714,4887,5378,4001,4523,6163,5026,5522,4701,4175,2791, +3760,6589,5473,4224,4133,3847,4814,4815,4775,3259,5416,6590,2738,6164,6025,5304, +3733,5076,5650,4816,5590,6591,6165,6592,3934,5269,6593,3396,5340,6594,5804,3445, +3602,4042,4488,5731,5732,3525,5591,4601,5196,6166,6026,5172,3642,4612,3202,4506, +4798,6366,3818,5108,4303,5138,5139,4776,3332,4304,2915,3415,4434,5077,5109,4856, +2879,5305,4817,6595,5913,3104,3144,3903,4634,5341,3133,5110,5651,5805,6167,4057, +5592,2945,4371,5593,6596,3474,4182,6367,6597,6168,4507,4279,6598,2822,6599,4777, +4713,5594,3829,6169,3887,5417,6170,3653,5474,6368,4216,2971,5228,3790,4579,6369, +5733,6600,6601,4951,4746,4555,6602,5418,5475,6027,3400,4665,5806,6171,4799,6028, +5052,6172,3343,4800,4747,5006,6370,4556,4217,5476,4396,5229,5379,5477,3839,5914, +5652,5807,4714,3068,4635,5808,6173,5342,4192,5078,5419,5523,5734,6174,4557,6175, +4602,6371,6176,6603,5809,6372,5735,4260,3869,5111,5230,6029,5112,6177,3126,4681, +5524,5915,2706,3563,4748,3130,6178,4018,5525,6604,6605,5478,4012,4837,6606,4534, +4193,5810,4857,3615,5479,6030,4082,3697,3539,4086,5270,3662,4508,4931,5916,4912, +5811,5027,3888,6607,4397,3527,3302,3798,2775,2921,2637,3966,4122,4388,4028,4054, +1633,4858,5079,3024,5007,3982,3412,5736,6608,3426,3236,5595,3030,6179,3427,3336, +3279,3110,6373,3874,3039,5080,5917,5140,4489,3119,6374,5812,3405,4494,6031,4666, +4141,6180,4166,6032,5813,4981,6609,5081,4422,4982,4112,3915,5653,3296,3983,6375, +4266,4410,5654,6610,6181,3436,5082,6611,5380,6033,3819,5596,4535,5231,5306,5113, +6612,4952,5918,4275,3113,6613,6376,6182,6183,5814,3073,4731,4838,5008,3831,6614, +4888,3090,3848,4280,5526,5232,3014,5655,5009,5737,5420,5527,6615,5815,5343,5173, +5381,4818,6616,3151,4953,6617,5738,2796,3204,4360,2989,4281,5739,5174,5421,5197, +3132,5141,3849,5142,5528,5083,3799,3904,4839,5480,2880,4495,3448,6377,6184,5271, +5919,3771,3193,6034,6035,5920,5010,6036,5597,6037,6378,6038,3106,5422,6618,5423, +5424,4142,6619,4889,5084,4890,4313,5740,6620,3437,5175,5307,5816,4199,5198,5529, +5817,5199,5656,4913,5028,5344,3850,6185,2955,5272,5011,5818,4567,4580,5029,5921, +3616,5233,6621,6622,6186,4176,6039,6379,6380,3352,5200,5273,2908,5598,5234,3837, +5308,6623,6624,5819,4496,4323,5309,5201,6625,6626,4983,3194,3838,4167,5530,5922, +5274,6381,6382,3860,3861,5599,3333,4292,4509,6383,3553,5481,5820,5531,4778,6187, +3955,3956,4324,4389,4218,3945,4325,3397,2681,5923,4779,5085,4019,5482,4891,5382, +5383,6040,4682,3425,5275,4094,6627,5310,3015,5483,5657,4398,5924,3168,4819,6628, +5925,6629,5532,4932,4613,6041,6630,4636,6384,4780,4204,5658,4423,5821,3989,4683, +5822,6385,4954,6631,5345,6188,5425,5012,5384,3894,6386,4490,4104,6632,5741,5053, +6633,5823,5926,5659,5660,5927,6634,5235,5742,5824,4840,4933,4820,6387,4859,5928, +4955,6388,4143,3584,5825,5346,5013,6635,5661,6389,5014,5484,5743,4337,5176,5662, +6390,2836,6391,3268,6392,6636,6042,5236,6637,4158,6638,5744,5663,4471,5347,3663, +4123,5143,4293,3895,6639,6640,5311,5929,5826,3800,6189,6393,6190,5664,5348,3554, +3594,4749,4603,6641,5385,4801,6043,5827,4183,6642,5312,5426,4761,6394,5665,6191, +4715,2669,6643,6644,5533,3185,5427,5086,5930,5931,5386,6192,6044,6645,4781,4013, +5745,4282,4435,5534,4390,4267,6045,5746,4984,6046,2743,6193,3501,4087,5485,5932, +5428,4184,4095,5747,4061,5054,3058,3862,5933,5600,6646,5144,3618,6395,3131,5055, +5313,6396,4650,4956,3855,6194,3896,5202,4985,4029,4225,6195,6647,5828,5486,5829, +3589,3002,6648,6397,4782,5276,6649,6196,6650,4105,3803,4043,5237,5830,6398,4096, +3643,6399,3528,6651,4453,3315,4637,6652,3984,6197,5535,3182,3339,6653,3096,2660, +6400,6654,3449,5934,4250,4236,6047,6401,5831,6655,5487,3753,4062,5832,6198,6199, +6656,3766,6657,3403,4667,6048,6658,4338,2897,5833,3880,2797,3780,4326,6659,5748, +5015,6660,5387,4351,5601,4411,6661,3654,4424,5935,4339,4072,5277,4568,5536,6402, +6662,5238,6663,5349,5203,6200,5204,6201,5145,4536,5016,5056,4762,5834,4399,4957, +6202,6403,5666,5749,6664,4340,6665,5936,5177,5667,6666,6667,3459,4668,6404,6668, +6669,4543,6203,6670,4276,6405,4480,5537,6671,4614,5205,5668,6672,3348,2193,4763, +6406,6204,5937,5602,4177,5669,3419,6673,4020,6205,4443,4569,5388,3715,3639,6407, +6049,4058,6206,6674,5938,4544,6050,4185,4294,4841,4651,4615,5488,6207,6408,6051, +5178,3241,3509,5835,6208,4958,5836,4341,5489,5278,6209,2823,5538,5350,5206,5429, +6675,4638,4875,4073,3516,4684,4914,4860,5939,5603,5389,6052,5057,3237,5490,3791, +6676,6409,6677,4821,4915,4106,5351,5058,4243,5539,4244,5604,4842,4916,5239,3028, +3716,5837,5114,5605,5390,5940,5430,6210,4332,6678,5540,4732,3667,3840,6053,4305, +3408,5670,5541,6410,2744,5240,5750,6679,3234,5606,6680,5607,5671,3608,4283,4159, +4400,5352,4783,6681,6411,6682,4491,4802,6211,6412,5941,6413,6414,5542,5751,6683, +4669,3734,5942,6684,6415,5943,5059,3328,4670,4144,4268,6685,6686,6687,6688,4372, +3603,6689,5944,5491,4373,3440,6416,5543,4784,4822,5608,3792,4616,5838,5672,3514, +5391,6417,4892,6690,4639,6691,6054,5673,5839,6055,6692,6056,5392,6212,4038,5544, +5674,4497,6057,6693,5840,4284,5675,4021,4545,5609,6418,4454,6419,6213,4113,4472, +5314,3738,5087,5279,4074,5610,4959,4063,3179,4750,6058,6420,6214,3476,4498,4716, +5431,4960,4685,6215,5241,6694,6421,6216,6695,5841,5945,6422,3748,5946,5179,3905, +5752,5545,5947,4374,6217,4455,6423,4412,6218,4803,5353,6696,3832,5280,6219,4327, +4702,6220,6221,6059,4652,5432,6424,3749,4751,6425,5753,4986,5393,4917,5948,5030, +5754,4861,4733,6426,4703,6697,6222,4671,5949,4546,4961,5180,6223,5031,3316,5281, +6698,4862,4295,4934,5207,3644,6427,5842,5950,6428,6429,4570,5843,5282,6430,6224, +5088,3239,6060,6699,5844,5755,6061,6431,2701,5546,6432,5115,5676,4039,3993,3327, +4752,4425,5315,6433,3941,6434,5677,4617,4604,3074,4581,6225,5433,6435,6226,6062, +4823,5756,5116,6227,3717,5678,4717,5845,6436,5679,5846,6063,5847,6064,3977,3354, +6437,3863,5117,6228,5547,5394,4499,4524,6229,4605,6230,4306,4500,6700,5951,6065, +3693,5952,5089,4366,4918,6701,6231,5548,6232,6702,6438,4704,5434,6703,6704,5953, +4168,6705,5680,3420,6706,5242,4407,6066,3812,5757,5090,5954,4672,4525,3481,5681, +4618,5395,5354,5316,5955,6439,4962,6707,4526,6440,3465,4673,6067,6441,5682,6708, +5435,5492,5758,5683,4619,4571,4674,4804,4893,4686,5493,4753,6233,6068,4269,6442, +6234,5032,4705,5146,5243,5208,5848,6235,6443,4963,5033,4640,4226,6236,5849,3387, +6444,6445,4436,4437,5850,4843,5494,4785,4894,6709,4361,6710,5091,5956,3331,6237, +4987,5549,6069,6711,4342,3517,4473,5317,6070,6712,6071,4706,6446,5017,5355,6713, +6714,4988,5436,6447,4734,5759,6715,4735,4547,4456,4754,6448,5851,6449,6450,3547, +5852,5318,6451,6452,5092,4205,6716,6238,4620,4219,5611,6239,6072,4481,5760,5957, +5958,4059,6240,6453,4227,4537,6241,5761,4030,4186,5244,5209,3761,4457,4876,3337, +5495,5181,6242,5959,5319,5612,5684,5853,3493,5854,6073,4169,5613,5147,4895,6074, +5210,6717,5182,6718,3830,6243,2798,3841,6075,6244,5855,5614,3604,4606,5496,5685, +5118,5356,6719,6454,5960,5357,5961,6720,4145,3935,4621,5119,5962,4261,6721,6455, +4786,5963,4375,4582,6245,6246,6247,6076,5437,4877,5856,3376,4380,6248,4160,6722, +5148,6456,5211,6457,6723,4718,6458,6724,6249,5358,4044,3297,6459,6250,5857,5615, +5497,5245,6460,5498,6725,6251,6252,5550,3793,5499,2959,5396,6461,6462,4572,5093, +5500,5964,3806,4146,6463,4426,5762,5858,6077,6253,4755,3967,4220,5965,6254,4989, +5501,6464,4352,6726,6078,4764,2290,5246,3906,5438,5283,3767,4964,2861,5763,5094, +6255,6256,4622,5616,5859,5860,4707,6727,4285,4708,4824,5617,6257,5551,4787,5212, +4965,4935,4687,6465,6728,6466,5686,6079,3494,4413,2995,5247,5966,5618,6729,5967, +5764,5765,5687,5502,6730,6731,6080,5397,6467,4990,6258,6732,4538,5060,5619,6733, +4719,5688,5439,5018,5149,5284,5503,6734,6081,4607,6259,5120,3645,5861,4583,6260, +4584,4675,5620,4098,5440,6261,4863,2379,3306,4585,5552,5689,4586,5285,6735,4864, +6736,5286,6082,6737,4623,3010,4788,4381,4558,5621,4587,4896,3698,3161,5248,4353, +4045,6262,3754,5183,4588,6738,6263,6739,6740,5622,3936,6741,6468,6742,6264,5095, +6469,4991,5968,6743,4992,6744,6083,4897,6745,4256,5766,4307,3108,3968,4444,5287, +3889,4343,6084,4510,6085,4559,6086,4898,5969,6746,5623,5061,4919,5249,5250,5504, +5441,6265,5320,4878,3242,5862,5251,3428,6087,6747,4237,5624,5442,6266,5553,4539, +6748,2585,3533,5398,4262,6088,5150,4736,4438,6089,6267,5505,4966,6749,6268,6750, +6269,5288,5554,3650,6090,6091,4624,6092,5690,6751,5863,4270,5691,4277,5555,5864, +6752,5692,4720,4865,6470,5151,4688,4825,6753,3094,6754,6471,3235,4653,6755,5213, +5399,6756,3201,4589,5865,4967,6472,5866,6473,5019,3016,6757,5321,4756,3957,4573, +6093,4993,5767,4721,6474,6758,5625,6759,4458,6475,6270,6760,5556,4994,5214,5252, +6271,3875,5768,6094,5034,5506,4376,5769,6761,2120,6476,5253,5770,6762,5771,5970, +3990,5971,5557,5558,5772,6477,6095,2787,4641,5972,5121,6096,6097,6272,6763,3703, +5867,5507,6273,4206,6274,4789,6098,6764,3619,3646,3833,3804,2394,3788,4936,3978, +4866,4899,6099,6100,5559,6478,6765,3599,5868,6101,5869,5870,6275,6766,4527,6767, +*******************************************************************************/ +}; + + diff --git a/uchardet/uchardet/src/GB2312Freq.tab b/uchardet/uchardet/src/GB2312Freq.tab index aee12caac..d9f9f1150 100644 --- a/uchardet/uchardet/src/GB2312Freq.tab +++ b/uchardet/uchardet/src/GB2312Freq.tab @@ -35,6 +35,15 @@ * * ***** END LICENSE BLOCK ***** */ +////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////// +// +// TODO: until we don't have a better solution, we use GB18030's Table here +// +////////////////////////////////////////////////////////////////////////// +////////////////////////////////////////////////////////////////////////// + + //GB2312 most frequently used character table //Char to FreqOrder table , from hz6763 diff --git a/uchardet/uchardet/src/nsBig5Prober.cpp b/uchardet/uchardet/src/nsBig5Prober.cpp index 3e47d6e1f..3e413f894 100644 --- a/uchardet/uchardet/src/nsBig5Prober.cpp +++ b/uchardet/uchardet/src/nsBig5Prober.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -46,7 +46,7 @@ void nsBig5Prober::Reset(void) nsProbingState nsBig5Prober::HandleData(const char* aBuf, PRUint32 aLen) { - PRUint32 codingState; + nsSMState codingState; for (PRUint32 i = 0; i < aLen; i++) { diff --git a/uchardet/uchardet/src/nsCharSetProber.cpp b/uchardet/uchardet/src/nsCharSetProber.cpp index 79d5ace0f..835582c1c 100644 --- a/uchardet/uchardet/src/nsCharSetProber.cpp +++ b/uchardet/uchardet/src/nsCharSetProber.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -74,7 +74,7 @@ PRBool nsCharSetProber::FilterWithoutEnglishLetters(const char* aBuf, PRUint32 a if (meetMSB && curPtr > prevPtr) while (prevPtr < curPtr) *newptr++ = *prevPtr++; - newLen = (PRUint32) (newptr - *newBuf); + newLen = static_cast(newptr - *newBuf); return PR_TRUE; } @@ -119,7 +119,7 @@ PRBool nsCharSetProber::FilterWithEnglishLetters(const char* aBuf, PRUint32 aLen while (prevPtr < curPtr) *newptr++ = *prevPtr++; - newLen = (PRUint32) (newptr - *newBuf); + newLen = static_cast(newptr - *newBuf); return PR_TRUE; } diff --git a/uchardet/uchardet/src/nsCodingStateMachine.h b/uchardet/uchardet/src/nsCodingStateMachine.h index 886111814..a1ae79e92 100644 --- a/uchardet/uchardet/src/nsCodingStateMachine.h +++ b/uchardet/uchardet/src/nsCodingStateMachine.h @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -42,9 +42,11 @@ /* Apart from these 3 generic states, machine states are specific to * each charset prober. */ -#define eStart 0 -#define eError 1 -#define eItsMe 2 +typedef enum { + eStart = 0, + eError = 1, + eItsMe = 2 +} nsSMState; #define GETCLASS(c) GETFROMPCK(((unsigned char)(c)), mModel->classTable) @@ -61,7 +63,7 @@ typedef struct class nsCodingStateMachine { public: nsCodingStateMachine(const SMModel* sm) : mModel(sm) { mCurrentState = eStart; } - PRUint32 NextState(char c){ + nsSMState NextState(char c){ //for each byte we get its class , if it is first byte, we also get byte length PRUint32 byteCls = GETCLASS(c); if (mCurrentState == eStart) @@ -70,8 +72,8 @@ public: mCurrentCharLen = mModel->charLenTable[byteCls]; } //from byte's class and stateTable, we get its next state - mCurrentState = GETFROMPCK(mCurrentState * mModel->classFactor + byteCls, - mModel->stateTable); + mCurrentState=(nsSMState)GETFROMPCK(mCurrentState*(mModel->classFactor)+byteCls, + mModel->stateTable); mCurrentBytePos++; return mCurrentState; } @@ -80,7 +82,7 @@ public: const char * GetCodingStateMachine() {return mModel->name;} protected: - PRUint32 mCurrentState; + nsSMState mCurrentState; PRUint32 mCurrentCharLen; PRUint32 mCurrentBytePos; @@ -92,6 +94,7 @@ extern const SMModel Big5SMModel; extern const SMModel EUCJPSMModel; extern const SMModel EUCKRSMModel; extern const SMModel EUCTWSMModel; +extern const SMModel GB2312SMModel; extern const SMModel GB18030SMModel; extern const SMModel SJISSMModel; diff --git a/uchardet/uchardet/src/nsEUCJPProber.cpp b/uchardet/uchardet/src/nsEUCJPProber.cpp index f84d15461..578bc5f2b 100644 --- a/uchardet/uchardet/src/nsEUCJPProber.cpp +++ b/uchardet/uchardet/src/nsEUCJPProber.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -52,7 +52,7 @@ void nsEUCJPProber::Reset(void) nsProbingState nsEUCJPProber::HandleData(const char* aBuf, PRUint32 aLen) { - PRUint32 codingState; + nsSMState codingState; for (PRUint32 i = 0; i < aLen; i++) { diff --git a/uchardet/uchardet/src/nsEUCKRProber.cpp b/uchardet/uchardet/src/nsEUCKRProber.cpp index 6aae8ae64..fc03c5b6e 100644 --- a/uchardet/uchardet/src/nsEUCKRProber.cpp +++ b/uchardet/uchardet/src/nsEUCKRProber.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -47,7 +47,7 @@ void nsEUCKRProber::Reset(void) nsProbingState nsEUCKRProber::HandleData(const char* aBuf, PRUint32 aLen) { - PRUint32 codingState; + nsSMState codingState; for (PRUint32 i = 0; i < aLen; i++) { diff --git a/uchardet/uchardet/src/nsEUCTWProber.cpp b/uchardet/uchardet/src/nsEUCTWProber.cpp index 7e61ea1e0..a06e074b3 100644 --- a/uchardet/uchardet/src/nsEUCTWProber.cpp +++ b/uchardet/uchardet/src/nsEUCTWProber.cpp @@ -47,7 +47,7 @@ void nsEUCTWProber::Reset(void) nsProbingState nsEUCTWProber::HandleData(const char* aBuf, PRUint32 aLen) { - PRUint32 codingState; + nsSMState codingState; for (PRUint32 i = 0; i < aLen; i++) { diff --git a/uchardet/uchardet/src/nsEscCharsetProber.cpp b/uchardet/uchardet/src/nsEscCharsetProber.cpp index d093ee479..5d8580af1 100644 --- a/uchardet/uchardet/src/nsEscCharsetProber.cpp +++ b/uchardet/uchardet/src/nsEscCharsetProber.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -75,7 +75,7 @@ void nsEscCharSetProber::Reset(void) nsProbingState nsEscCharSetProber::HandleData(const char* aBuf, PRUint32 aLen) { - PRUint32 codingState; + nsSMState codingState; PRInt32 j; PRUint32 i; diff --git a/uchardet/uchardet/src/nsGB18030Prober.cpp b/uchardet/uchardet/src/nsGB18030Prober.cpp new file mode 100644 index 000000000..f6d5c5b76 --- /dev/null +++ b/uchardet/uchardet/src/nsGB18030Prober.cpp @@ -0,0 +1,96 @@ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* ***** BEGIN LICENSE BLOCK ***** + * Version: MPL 1.1/GPL 2.0/LGPL 2.1 + * + * The contents of this file are subject to the Mozilla Public License Version + * 1.1 (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * http://www.mozilla.org/MPL/ + * + * Software distributed under the License is distributed on an "AS IS" basis, + * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License + * for the specific language governing rights and limitations under the + * License. + * + * The Original Code is mozilla.org code. + * + * The Initial Developer of the Original Code is + * Netscape Communications Corporation. + * Portions created by the Initial Developer are Copyright (C) 1998 + * the Initial Developer. All Rights Reserved. + * + * Contributor(s): + * + * Alternatively, the contents of this file may be used under the terms of + * either the GNU General Public License Version 2 or later (the "GPL"), or + * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), + * in which case the provisions of the GPL or the LGPL are applicable instead + * of those above. If you wish to allow use of your version of this file only + * under the terms of either the GPL or the LGPL, and not to allow others to + * use your version of this file under the terms of the MPL, indicate your + * decision by deleting the provisions above and replace them with the notice + * and other provisions required by the GPL or the LGPL. If you do not delete + * the provisions above, a recipient may use your version of this file under + * the terms of any one of the MPL, the GPL or the LGPL. + * + * ***** END LICENSE BLOCK ***** */ + +// for S-JIS encoding, obeserve characteristic: +// 1, kana character (or hankaku?) often have hight frequency of appereance +// 2, kana character often exist in group +// 3, certain combination of kana is never used in japanese language + +#include "nsGB18030Prober.h" + +void nsGB18030Prober::Reset(void) +{ + mCodingSM->Reset(); + mState = eDetecting; + mDistributionAnalyser.Reset(mIsPreferredLanguage); + //mContextAnalyser.Reset(); +} + +nsProbingState nsGB18030Prober::HandleData(const char* aBuf, PRUint32 aLen) +{ + nsSMState codingState; + + for (PRUint32 i = 0; i < aLen; i++) + { + codingState = mCodingSM->NextState(aBuf[i]); + if (codingState == eItsMe) + { + mState = eFoundIt; + break; + } + if (codingState == eStart) + { + PRUint32 charLen = mCodingSM->GetCurrentCharLen(); + + if (i == 0) + { + mLastChar[1] = aBuf[0]; + mDistributionAnalyser.HandleOneChar(mLastChar, charLen); + } + else + mDistributionAnalyser.HandleOneChar(aBuf+i-1, charLen); + } + } + + mLastChar[0] = aBuf[aLen-1]; + + if (mState == eDetecting) + if (mDistributionAnalyser.GotEnoughData() && GetConfidence() > SHORTCUT_THRESHOLD) + mState = eFoundIt; +// else +// mDistributionAnalyser.HandleData(aBuf, aLen); + + return mState; +} + +float nsGB18030Prober::GetConfidence(void) +{ + float distribCf = mDistributionAnalyser.GetConfidence(); + + return (float)distribCf; +} + diff --git a/uchardet/uchardet/src/nsGB18030Prober.h b/uchardet/uchardet/src/nsGB18030Prober.h new file mode 100644 index 000000000..70583c5d3 --- /dev/null +++ b/uchardet/uchardet/src/nsGB18030Prober.h @@ -0,0 +1,77 @@ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* ***** BEGIN LICENSE BLOCK ***** + * Version: MPL 1.1/GPL 2.0/LGPL 2.1 + * + * The contents of this file are subject to the Mozilla Public License Version + * 1.1 (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * http://www.mozilla.org/MPL/ + * + * Software distributed under the License is distributed on an "AS IS" basis, + * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License + * for the specific language governing rights and limitations under the + * License. + * + * The Original Code is mozilla.org code. + * + * The Initial Developer of the Original Code is + * Netscape Communications Corporation. + * Portions created by the Initial Developer are Copyright (C) 1998 + * the Initial Developer. All Rights Reserved. + * + * Contributor(s): + * + * Alternatively, the contents of this file may be used under the terms of + * either the GNU General Public License Version 2 or later (the "GPL"), or + * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), + * in which case the provisions of the GPL or the LGPL are applicable instead + * of those above. If you wish to allow use of your version of this file only + * under the terms of either the GPL or the LGPL, and not to allow others to + * use your version of this file under the terms of the MPL, indicate your + * decision by deleting the provisions above and replace them with the notice + * and other provisions required by the GPL or the LGPL. If you do not delete + * the provisions above, a recipient may use your version of this file under + * the terms of any one of the MPL, the GPL or the LGPL. + * + * ***** END LICENSE BLOCK ***** */ + +#ifndef nsGB18030Prober_h__ +#define nsGB18030Prober_h__ + +#include "nsCharSetProber.h" +#include "nsCodingStateMachine.h" +#include "CharDistribution.h" + +// NOT VALID: We use GB18030 to replace GB2312, because 18030 is a superset. +// it superseded GB2312, but it is NOT a superset + +class nsGB18030Prober : public nsCharSetProber { +public: + nsGB18030Prober(PRBool aIsPreferredLanguage) + :mIsPreferredLanguage(aIsPreferredLanguage) + {mCodingSM = new nsCodingStateMachine(&GB18030SMModel); + Reset();} + virtual ~nsGB18030Prober(void){delete mCodingSM;} + nsProbingState HandleData(const char* aBuf, PRUint32 aLen); + const char* GetCharSetName() {return "GB18030";} + nsProbingState GetState(void) {return mState;} + void Reset(void); + float GetConfidence(void); + void SetOpion() {} + +protected: + void GetDistribution(PRUint32 aCharLen, const char* aStr); + + nsCodingStateMachine* mCodingSM; + nsProbingState mState; + + //GB18030ContextAnalysis mContextAnalyser; + GB18030DistributionAnalysis mDistributionAnalyser; + char mLastChar[2]; + PRBool mIsPreferredLanguage; + +}; + + +#endif /* nsGB18030Prober_h__ */ + diff --git a/uchardet/uchardet/src/nsGB2312Prober.cpp b/uchardet/uchardet/src/nsGB2312Prober.cpp index eac076236..873269b91 100644 --- a/uchardet/uchardet/src/nsGB2312Prober.cpp +++ b/uchardet/uchardet/src/nsGB2312Prober.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -42,7 +42,7 @@ #include "nsGB2312Prober.h" -void nsGB18030Prober::Reset(void) +void nsGB2312Prober::Reset(void) { mCodingSM->Reset(); mState = eDetecting; @@ -50,9 +50,9 @@ void nsGB18030Prober::Reset(void) //mContextAnalyser.Reset(); } -nsProbingState nsGB18030Prober::HandleData(const char* aBuf, PRUint32 aLen) +nsProbingState nsGB2312Prober::HandleData(const char* aBuf, PRUint32 aLen) { - PRUint32 codingState; + nsSMState codingState; for (PRUint32 i = 0; i < aLen; i++) { @@ -87,7 +87,7 @@ nsProbingState nsGB18030Prober::HandleData(const char* aBuf, PRUint32 aLen) return mState; } -float nsGB18030Prober::GetConfidence(void) +float nsGB2312Prober::GetConfidence(void) { float distribCf = mDistributionAnalyser.GetConfidence(); diff --git a/uchardet/uchardet/src/nsGB2312Prober.h b/uchardet/uchardet/src/nsGB2312Prober.h index 26ebf8443..69c7616d5 100644 --- a/uchardet/uchardet/src/nsGB2312Prober.h +++ b/uchardet/uchardet/src/nsGB2312Prober.h @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -42,17 +42,18 @@ #include "nsCodingStateMachine.h" #include "CharDistribution.h" -// We use GB18030 to replace GB2312, because 18030 is a superset. +// NOT VALID: We use GB18030 to replace GB2312, because 18030 is a superset. +// it superseded GB2312, but it is NOT a superset -class nsGB18030Prober: public nsCharSetProber { +class nsGB2312Prober : public nsCharSetProber { public: - nsGB18030Prober(PRBool aIsPreferredLanguage) + nsGB2312Prober(PRBool aIsPreferredLanguage) :mIsPreferredLanguage(aIsPreferredLanguage) - {mCodingSM = new nsCodingStateMachine(&GB18030SMModel); + {mCodingSM = new nsCodingStateMachine(&GB2312SMModel); Reset();} - virtual ~nsGB18030Prober(void){delete mCodingSM;} + virtual ~nsGB2312Prober(void){delete mCodingSM;} nsProbingState HandleData(const char* aBuf, PRUint32 aLen); - const char* GetCharSetName() {return "GB18030";} + const char* GetCharSetName() {return "GB2312";} nsProbingState GetState(void) {return mState;} void Reset(void); float GetConfidence(void); diff --git a/uchardet/uchardet/src/nsMBCSGroupProber.cpp b/uchardet/uchardet/src/nsMBCSGroupProber.cpp index 057ddb11a..98d71367a 100644 --- a/uchardet/uchardet/src/nsMBCSGroupProber.cpp +++ b/uchardet/uchardet/src/nsMBCSGroupProber.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -47,7 +47,8 @@ const char *ProberName[] = "UTF-8", "SJIS", "EUC-JP", - "GB18030", + "GB2312", + //"GB18030", "EUC-KR", "Big5", "EUC-TW", @@ -57,23 +58,29 @@ const char *ProberName[] = nsMBCSGroupProber::nsMBCSGroupProber(PRUint32 aLanguageFilter) { - for (PRUint32 i = 0; i < NUM_OF_PROBERS; i++) + for (PRUint32 i = 0; i < NUM_OF_PROBERS; i++) { mProbers[i] = nsnull; - - mProbers[0] = new nsUTF8Prober(); + } + PRUint32 i = 0; + mProbers[i] = new nsUTF8Prober(); if (aLanguageFilter & NS_FILTER_JAPANESE) { - mProbers[1] = new nsSJISProber(aLanguageFilter == NS_FILTER_JAPANESE); - mProbers[2] = new nsEUCJPProber(aLanguageFilter == NS_FILTER_JAPANESE); + mProbers[++i] = new nsSJISProber(aLanguageFilter == NS_FILTER_JAPANESE); + mProbers[++i] = new nsEUCJPProber(aLanguageFilter == NS_FILTER_JAPANESE); + } + if (aLanguageFilter & NS_FILTER_CHINESE_SIMPLIFIED) + { + mProbers[++i] = new nsGB2312Prober(aLanguageFilter == NS_FILTER_CHINESE_SIMPLIFIED); + //~mProbers[++i] = new nsGB18030Prober(aLanguageFilter == NS_FILTER_CHINESE_SIMPLIFIED); } - if (aLanguageFilter & NS_FILTER_CHINESE_SIMPLIFIED) - mProbers[3] = new nsGB18030Prober(aLanguageFilter == NS_FILTER_CHINESE_SIMPLIFIED); if (aLanguageFilter & NS_FILTER_KOREAN) - mProbers[4] = new nsEUCKRProber(aLanguageFilter == NS_FILTER_KOREAN); + { + mProbers[++i] = new nsEUCKRProber(aLanguageFilter == NS_FILTER_KOREAN); + } if (aLanguageFilter & NS_FILTER_CHINESE_TRADITIONAL) { - mProbers[5] = new nsBig5Prober(aLanguageFilter == NS_FILTER_CHINESE_TRADITIONAL); - mProbers[6] = new nsEUCTWProber(aLanguageFilter == NS_FILTER_CHINESE_TRADITIONAL); + mProbers[++i] = new nsBig5Prober(aLanguageFilter == NS_FILTER_CHINESE_TRADITIONAL); + mProbers[++i] = new nsEUCTWProber(aLanguageFilter == NS_FILTER_CHINESE_TRADITIONAL); } Reset(); } diff --git a/uchardet/uchardet/src/nsMBCSGroupProber.h b/uchardet/uchardet/src/nsMBCSGroupProber.h index c4e996497..7a9aa1820 100644 --- a/uchardet/uchardet/src/nsMBCSGroupProber.h +++ b/uchardet/uchardet/src/nsMBCSGroupProber.h @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -43,6 +43,7 @@ #include "nsUTF8Prober.h" #include "nsEUCJPProber.h" #include "nsGB2312Prober.h" +//~#include "nsGB18030Prober.h" #include "nsEUCKRProber.h" #include "nsBig5Prober.h" #include "nsEUCTWProber.h" diff --git a/uchardet/uchardet/src/nsMBCSSM.cpp b/uchardet/uchardet/src/nsMBCSSM.cpp index 50700968a..814983ea8 100644 --- a/uchardet/uchardet/src/nsMBCSSM.cpp +++ b/uchardet/uchardet/src/nsMBCSSM.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -260,7 +260,9 @@ const SMModel EUCTWSMModel = { "EUC-TW", }; -/* obsolete GB2312 by GB18030 + +// GB-2312 + static PRUint32 GB2312_cls [ 256 / 8 ] = { //PCK4BITS(0,1,1,1,1,1,1,1), // 00 - 07 PCK4BITS(1,1,1,1,1,1,1,1), // 00 - 07 @@ -305,14 +307,16 @@ PCK4BITS(eItsMe,eItsMe,eItsMe,eItsMe,eError,eError,eStart,eStart) //08-0f static const PRUint32 GB2312CharLenTable[] = {0, 1, 2, 0}; -SMModel GB2312SMModel = { +const SMModel GB2312SMModel = { {eIdxSft4bits, eSftMsk4bits, eBitSft4bits, eUnitMsk4bits, GB2312_cls }, 4, {eIdxSft4bits, eSftMsk4bits, eBitSft4bits, eUnitMsk4bits, GB2312_st }, GB2312CharLenTable, "GB2312", }; -*/ + + +// GB-18030 // the following state machine data was created by perl script in // intl/chardet/tools. It should be the same as in PSM detector. @@ -352,7 +356,7 @@ PCK4BITS(6,6,6,6,6,6,6,0) // f8 - ff }; -static const PRUint32 GB18030_st [ 6] = { +static const PRUint32 GB18030_st [6] = { PCK4BITS(eError,eStart,eStart,eStart,eStart,eStart, 3,eError),//00-07 PCK4BITS(eError,eError,eError,eError,eError,eError,eItsMe,eItsMe),//08-0f PCK4BITS(eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eError,eError,eStart),//10-17 @@ -361,6 +365,7 @@ PCK4BITS(eError,eError, 5,eError,eError,eError,eItsMe,eError),//20-27 PCK4BITS(eError,eError,eStart,eStart,eStart,eStart,eStart,eStart) //28-2f }; + // To be accurate, the length of class 6 can be either 2 or 4. // But it is not necessary to discriminate between the two since // it is used for frequency analysis only, and we are validing @@ -376,6 +381,7 @@ const SMModel GB18030SMModel = { "GB18030", }; + // sjis static const PRUint32 SJIS_cls [ 256 / 8 ] = { diff --git a/uchardet/uchardet/src/nsSBCharSetProber.cpp b/uchardet/uchardet/src/nsSBCharSetProber.cpp index 001529f83..b400f0b53 100644 --- a/uchardet/uchardet/src/nsSBCharSetProber.cpp +++ b/uchardet/uchardet/src/nsSBCharSetProber.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * diff --git a/uchardet/uchardet/src/nsSJISProber.cpp b/uchardet/uchardet/src/nsSJISProber.cpp index 1c354a7b9..ca71b8bfc 100644 --- a/uchardet/uchardet/src/nsSJISProber.cpp +++ b/uchardet/uchardet/src/nsSJISProber.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -52,7 +52,7 @@ void nsSJISProber::Reset(void) nsProbingState nsSJISProber::HandleData(const char* aBuf, PRUint32 aLen) { - PRUint32 codingState; + nsSMState codingState; for (PRUint32 i = 0; i < aLen; i++) { diff --git a/uchardet/uchardet/src/nsUTF8Prober.cpp b/uchardet/uchardet/src/nsUTF8Prober.cpp index 93677dee1..d6538a493 100644 --- a/uchardet/uchardet/src/nsUTF8Prober.cpp +++ b/uchardet/uchardet/src/nsUTF8Prober.cpp @@ -1,4 +1,4 @@ -/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* ***** BEGIN LICENSE BLOCK ***** * Version: MPL 1.1/GPL 2.0/LGPL 2.1 * @@ -46,7 +46,7 @@ void nsUTF8Prober::Reset(void) nsProbingState nsUTF8Prober::HandleData(const char* aBuf, PRUint32 aLen) { - PRUint32 codingState; + nsSMState codingState; for (PRUint32 i = 0; i < aLen; i++) {