1. fix shift_jis, ucs2, utf8 verifier. 2. Add iso-2022-kr, iso-2022-cn, hz verifier

This commit is contained in:
ftang%netscape.com 1999-07-14 15:23:06 +00:00
Родитель 190597c08b
Коммит 7923efc8ec
18 изменённых файлов: 614 добавлений и 811 удалений

Просмотреть файл

@ -25,7 +25,7 @@
#include "nsVerifier.h"
static PRUint32 BIG5_cls [ 256 / 8 ] = {
PCK4BITS(0,1,1,1,1,1,1,1), // 00 - 07
PCK4BITS(1,1,1,1,1,1,1,1), // 08 - 0f
PCK4BITS(1,1,1,1,1,1,0,0), // 08 - 0f
PCK4BITS(1,1,1,1,1,1,1,1), // 10 - 17
PCK4BITS(1,1,1,0,1,1,1,1), // 18 - 1f
PCK4BITS(1,1,1,1,1,1,1,1), // 20 - 27

Просмотреть файл

@ -25,7 +25,7 @@
#include "nsVerifier.h"
static PRUint32 CP1252_cls [ 256 / 8 ] = {
PCK4BITS(0,2,2,2,2,2,2,2), // 00 - 07
PCK4BITS(2,2,2,2,2,2,2,2), // 08 - 0f
PCK4BITS(2,2,2,2,2,2,0,0), // 08 - 0f
PCK4BITS(2,2,2,2,2,2,2,2), // 10 - 17
PCK4BITS(2,2,2,0,2,2,2,2), // 18 - 1f
PCK4BITS(2,2,2,2,2,2,2,2), // 20 - 27

Просмотреть файл

@ -53,6 +53,11 @@ NS_DEFINE_CID(kZHStringPSMDetectorCID, NS_ZH_STRING_PSMDETECTOR_CID);
NS_DEFINE_CID(kCJKPSMDetectorCID, NS_CJK_PSMDETECTOR_CID);
NS_DEFINE_CID(kCJKStringPSMDetectorCID, NS_CJK_STRING_PSMDETECTOR_CID);
#include "nsCyrillicDetector.h"
NS_DEFINE_CID(kRUProbDetectorCID, NS_RU_PROBDETECTOR_CID);
NS_DEFINE_CID(kRUStringProbDetectorCID, NS_RU_STRING_PROBDETECTOR_CID);
NS_DEFINE_CID(kUKProbDetectorCID, NS_UK_PROBDETECTOR_CID);
NS_DEFINE_CID(kUKStringProbDetectorCID, NS_UK_STRING_PROBDETECTOR_CID);
#define INCLUDE_DBGDETECTOR
@ -92,30 +97,28 @@ extern "C" NS_EXPORT nsresult NSGetFactory(nsISupports* aServMgr,
factory = NEW_XML_ENCODING_OBSERVER_FACTORY();
} else if (aClass.Equals(kCharsetDetectionAdaptorCID)) {
factory = NEW_DETECTION_ADAPTOR_FACTORY();
} else if (aClass.Equals(kJAPSMDetectorCID)) {
factory = NEW_JA_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kJAStringPSMDetectorCID)) {
factory = NEW_JA_STRING_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kKOPSMDetectorCID)) {
factory = NEW_KO_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kKOStringPSMDetectorCID)) {
factory = NEW_KO_STRING_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kZHCNPSMDetectorCID)) {
factory = NEW_ZHCN_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kZHCNStringPSMDetectorCID)) {
factory = NEW_ZHCN_STRING_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kZHTWPSMDetectorCID)) {
factory = NEW_ZHTW_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kZHTWStringPSMDetectorCID)) {
factory = NEW_ZHTW_STRING_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kZHPSMDetectorCID)) {
factory = NEW_ZH_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kZHStringPSMDetectorCID)) {
factory = NEW_ZH_STRING_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kCJKPSMDetectorCID)) {
factory = NEW_CJK_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kCJKStringPSMDetectorCID)) {
factory = NEW_CJK_STRING_PSMDETECTOR_FACTORY();
} else if (aClass.Equals(kJAPSMDetectorCID) ||
aClass.Equals(kJAStringPSMDetectorCID) ||
aClass.Equals(kKOPSMDetectorCID) ||
aClass.Equals(kKOStringPSMDetectorCID) ||
aClass.Equals(kZHCNPSMDetectorCID) ||
aClass.Equals(kZHCNStringPSMDetectorCID) ||
aClass.Equals(kZHTWPSMDetectorCID) ||
aClass.Equals(kZHTWStringPSMDetectorCID) ||
aClass.Equals(kZHPSMDetectorCID) ||
aClass.Equals(kZHStringPSMDetectorCID) ||
aClass.Equals(kCJKPSMDetectorCID) ||
aClass.Equals(kCJKStringPSMDetectorCID)
)
{
factory = NEW_PSMDETECTOR_FACTORY(aClass);
} else if (aClass.Equals(kRUProbDetectorCID) ||
aClass.Equals(kRUStringProbDetectorCID) ||
aClass.Equals(kUKProbDetectorCID) ||
aClass.Equals(kUKStringProbDetectorCID)
)
{
factory = NEW_PROBDETECTOR_FACTORY(aClass);
#ifdef INCLUDE_DBGDETECTOR
} else if (aClass.Equals(k1stBlkDbgDetectorCID)) {
factory = NEW_1STBLKDBG_DETECTOR_FACTORY();
@ -228,6 +231,26 @@ extern "C" NS_EXPORT nsresult NSRegisterSelf(nsISupports* aServMgr, const char *
NS_STRCDETECTOR_PROGID_BASE "cjkpsm",
path,
PR_TRUE, PR_TRUE);
rv = compMgr->RegisterComponent(kRUProbDetectorCID,
"Probability based Russian Charset Detector",
NS_CHARSET_DETECTOR_PROGID_BASE "ruprob",
path,
PR_TRUE, PR_TRUE);
rv = compMgr->RegisterComponent(kUKProbDetectorCID,
"Probability based Ukrainian Charset Detector",
NS_CHARSET_DETECTOR_PROGID_BASE "ukprob",
path,
PR_TRUE, PR_TRUE);
rv = compMgr->RegisterComponent(kRUStringProbDetectorCID,
"Probability based Russian String Charset Detector",
NS_STRCDETECTOR_PROGID_BASE "ruprob",
path,
PR_TRUE, PR_TRUE);
rv = compMgr->RegisterComponent(kUKStringProbDetectorCID,
"Probability based Ukrainian String Charset Detector",
NS_STRCDETECTOR_PROGID_BASE "ukprob",
path,
PR_TRUE, PR_TRUE);
#ifdef INCLUDE_DBGDETECTOR
rv = compMgr->RegisterComponent(k1stBlkDbgDetectorCID,
"Debuging Detector 1st block",
@ -278,6 +301,10 @@ extern "C" NS_EXPORT nsresult NSUnregisterSelf(nsISupports* aServMgr, const char
rv = compMgr->UnregisterComponent(kZHStringPSMDetectorCID, path);
rv = compMgr->UnregisterComponent(kCJKPSMDetectorCID, path);
rv = compMgr->UnregisterComponent(kCJKStringPSMDetectorCID, path);
rv = compMgr->UnregisterComponent(kRUProbDetectorCID, path);
rv = compMgr->UnregisterComponent(kUKProbDetectorCID, path);
rv = compMgr->UnregisterComponent(kRUStringProbDetectorCID, path);
rv = compMgr->UnregisterComponent(kUKStringProbDetectorCID, path);
#ifdef INCLUDE_DBGDETECTOR
rv = compMgr->UnregisterComponent(k1stBlkDbgDetectorCID, path);
rv = compMgr->UnregisterComponent(k2ndBlkDbgDetectorCID, path);

Просмотреть файл

@ -69,6 +69,7 @@ NS_IMETHODIMP nsMyObserver::Notify(
const char* aCharset, nsDetectionConfident aConf)
{
nsresult rv = NS_OK;
rv = mWebShellSvc->SetRendering( PR_FALSE);
rv = mWebShellSvc->ReloadDocument( aCharset, kCharsetFromAutoDetection);
return NS_OK;
}
@ -79,6 +80,7 @@ NS_IMETHODIMP nsMyObserver::Init( nsIWebShellServices* aWebShellSvc)
{
NS_IF_ADDREF(aWebShellSvc);
mWebShellSvc = aWebShellSvc;
return NS_OK;
}
return NS_ERROR_ILLEGAL_VALUE;
}
@ -174,7 +176,7 @@ NS_IMETHODIMP nsDetectionAdaptor::Init(
if(nsnull == mobs)
return NS_ERROR_OUT_OF_MEMORY;
rv = this->QueryInterface(nsICharsetDetectionObserver::GetIID(),
rv = mobs->QueryInterface(nsICharsetDetectionObserver::GetIID(),
(void**) &aObserver);
if(NS_SUCCEEDED(rv)) {
@ -193,7 +195,9 @@ NS_IMETHODIMP nsDetectionAdaptor::Init(
mDontFeedToDetector = PR_FALSE;
return NS_OK;
}
} else {
delete mobs;
}
}
return NS_ERROR_ILLEGAL_VALUE;
}

Просмотреть файл

@ -25,7 +25,7 @@
#include "nsVerifier.h"
static PRUint32 EUCJP_cls [ 256 / 8 ] = {
PCK4BITS(5,4,4,4,4,4,4,4), // 00 - 07
PCK4BITS(4,4,4,4,4,4,4,4), // 08 - 0f
PCK4BITS(4,4,4,4,4,4,5,5), // 08 - 0f
PCK4BITS(4,4,4,4,4,4,4,4), // 10 - 17
PCK4BITS(4,4,4,5,4,4,4,4), // 18 - 1f
PCK4BITS(4,4,4,4,4,4,4,4), // 20 - 27

Просмотреть файл

@ -25,7 +25,7 @@
#include "nsVerifier.h"
static PRUint32 EUCKR_cls [ 256 / 8 ] = {
PCK4BITS(0,1,1,1,1,1,1,1), // 00 - 07
PCK4BITS(1,1,1,1,1,1,1,1), // 08 - 0f
PCK4BITS(1,1,1,1,1,1,0,0), // 08 - 0f
PCK4BITS(1,1,1,1,1,1,1,1), // 10 - 17
PCK4BITS(1,1,1,0,1,1,1,1), // 18 - 1f
PCK4BITS(1,1,1,1,1,1,1,1), // 20 - 27

Просмотреть файл

@ -25,7 +25,7 @@
#include "nsVerifier.h"
static PRUint32 EUCTW_cls [ 256 / 8 ] = {
PCK4BITS(0,2,2,2,2,2,2,2), // 00 - 07
PCK4BITS(2,2,2,2,2,2,2,2), // 08 - 0f
PCK4BITS(2,2,2,2,2,2,0,0), // 08 - 0f
PCK4BITS(2,2,2,2,2,2,2,2), // 10 - 17
PCK4BITS(2,2,2,0,2,2,2,2), // 18 - 1f
PCK4BITS(2,2,2,2,2,2,2,2), // 20 - 27

Просмотреть файл

@ -25,7 +25,7 @@
#include "nsVerifier.h"
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), // 08 - 0f
PCK4BITS(1,1,1,1,1,1,0,0), // 08 - 0f
PCK4BITS(1,1,1,1,1,1,1,1), // 10 - 17
PCK4BITS(1,1,1,0,1,1,1,1), // 18 - 1f
PCK4BITS(1,1,1,1,1,1,1,1), // 20 - 27

Просмотреть файл

@ -0,0 +1,89 @@
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public License
* Version 1.0 (the "NPL"); you may not use this file except in
* compliance with the NPL. You may obtain a copy of the NPL at
* http://www.mozilla.org/NPL/
*
* Software distributed under the NPL is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
* for the specific language governing rights and limitations under the
* NPL.
*
* The Initial Developer of this code under the NPL is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
* Reserved.
*/
/*
* DO NOT EDIT THIS DOCUMENT MANUALLY !!!
* THIS FILE IS AUTOMATICALLY GENERATED BY THE TOOLS UNDER
* mozilla/intl/chardet/tools/
* Please contact ftang@netscape.com or mozilla-i18n@mozilla.org
* if you have any question. Thanks
*/
#include "nsVerifier.h"
static PRUint32 HZ_cls [ 256 / 8 ] = {
PCK4BITS(1,0,0,0,0,0,0,0), // 00 - 07
PCK4BITS(0,0,0,0,0,0,0,0), // 08 - 0f
PCK4BITS(0,0,0,0,0,0,0,0), // 10 - 17
PCK4BITS(0,0,0,1,0,0,0,0), // 18 - 1f
PCK4BITS(0,0,0,0,0,0,0,0), // 20 - 27
PCK4BITS(0,0,0,0,0,0,0,0), // 28 - 2f
PCK4BITS(0,0,0,0,0,0,0,0), // 30 - 37
PCK4BITS(0,0,0,0,0,0,0,0), // 38 - 3f
PCK4BITS(0,0,0,0,0,0,0,0), // 40 - 47
PCK4BITS(0,0,0,0,0,0,0,0), // 48 - 4f
PCK4BITS(0,0,0,0,0,0,0,0), // 50 - 57
PCK4BITS(0,0,0,0,0,0,0,0), // 58 - 5f
PCK4BITS(0,0,0,0,0,0,0,0), // 60 - 67
PCK4BITS(0,0,0,0,0,0,0,0), // 68 - 6f
PCK4BITS(0,0,0,0,0,0,0,0), // 70 - 77
PCK4BITS(0,0,0,4,0,5,2,0), // 78 - 7f
PCK4BITS(1,1,1,1,1,1,1,1), // 80 - 87
PCK4BITS(1,1,1,1,1,1,1,1), // 88 - 8f
PCK4BITS(1,1,1,1,1,1,1,1), // 90 - 97
PCK4BITS(1,1,1,1,1,1,1,1), // 98 - 9f
PCK4BITS(1,1,1,1,1,1,1,1), // a0 - a7
PCK4BITS(1,1,1,1,1,1,1,1), // a8 - af
PCK4BITS(1,1,1,1,1,1,1,1), // b0 - b7
PCK4BITS(1,1,1,1,1,1,1,1), // b8 - bf
PCK4BITS(1,1,1,1,1,1,1,1), // c0 - c7
PCK4BITS(1,1,1,1,1,1,1,1), // c8 - cf
PCK4BITS(1,1,1,1,1,1,1,1), // d0 - d7
PCK4BITS(1,1,1,1,1,1,1,1), // d8 - df
PCK4BITS(1,1,1,1,1,1,1,1), // e0 - e7
PCK4BITS(1,1,1,1,1,1,1,1), // e8 - ef
PCK4BITS(1,1,1,1,1,1,1,1), // f0 - f7
PCK4BITS(1,1,1,1,1,1,1,1) // f8 - ff
};
static PRUint32 HZ_st [ 6] = {
PCK4BITS(eStart,eError, 3,eStart,eStart,eStart,eError,eError),//00-07
PCK4BITS(eError,eError,eError,eError,eItsMe,eItsMe,eItsMe,eItsMe),//08-0f
PCK4BITS(eItsMe,eItsMe,eError,eError,eStart,eStart, 4,eError),//10-17
PCK4BITS( 5,eError, 6,eError, 5, 5, 4,eError),//18-1f
PCK4BITS( 4,eError, 4, 4, 4,eError, 4,eError),//20-27
PCK4BITS( 4,eItsMe,eStart,eStart,eStart,eStart,eStart,eStart) //28-2f
};
static nsVerifier nsHZVerifier = {
"HZ-GB-2312",
{
eIdxSft4bits,
eSftMsk4bits,
eBitSft4bits,
eUnitMsk4bits,
HZ_cls
},
6,
{
eIdxSft4bits,
eSftMsk4bits,
eBitSft4bits,
eUnitMsk4bits,
HZ_st
}
};

Просмотреть файл

@ -0,0 +1,91 @@
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public License
* Version 1.0 (the "NPL"); you may not use this file except in
* compliance with the NPL. You may obtain a copy of the NPL at
* http://www.mozilla.org/NPL/
*
* Software distributed under the NPL is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
* for the specific language governing rights and limitations under the
* NPL.
*
* The Initial Developer of this code under the NPL is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
* Reserved.
*/
/*
* DO NOT EDIT THIS DOCUMENT MANUALLY !!!
* THIS FILE IS AUTOMATICALLY GENERATED BY THE TOOLS UNDER
* mozilla/intl/chardet/tools/
* Please contact ftang@netscape.com or mozilla-i18n@mozilla.org
* if you have any question. Thanks
*/
#include "nsVerifier.h"
static PRUint32 ISO2022CN_cls [ 256 / 8 ] = {
PCK4BITS(2,0,0,0,0,0,0,0), // 00 - 07
PCK4BITS(0,0,0,0,0,0,0,0), // 08 - 0f
PCK4BITS(0,0,0,0,0,0,0,0), // 10 - 17
PCK4BITS(0,0,0,1,0,0,0,0), // 18 - 1f
PCK4BITS(0,0,0,0,0,0,0,0), // 20 - 27
PCK4BITS(0,3,0,0,0,0,0,0), // 28 - 2f
PCK4BITS(0,0,0,0,0,0,0,0), // 30 - 37
PCK4BITS(0,0,0,0,0,0,0,0), // 38 - 3f
PCK4BITS(0,0,0,4,0,0,0,0), // 40 - 47
PCK4BITS(0,0,0,0,0,0,0,0), // 48 - 4f
PCK4BITS(0,0,0,0,0,0,0,0), // 50 - 57
PCK4BITS(0,0,0,0,0,0,0,0), // 58 - 5f
PCK4BITS(0,0,0,0,0,0,0,0), // 60 - 67
PCK4BITS(0,0,0,0,0,0,0,0), // 68 - 6f
PCK4BITS(0,0,0,0,0,0,0,0), // 70 - 77
PCK4BITS(0,0,0,0,0,0,0,0), // 78 - 7f
PCK4BITS(2,2,2,2,2,2,2,2), // 80 - 87
PCK4BITS(2,2,2,2,2,2,2,2), // 88 - 8f
PCK4BITS(2,2,2,2,2,2,2,2), // 90 - 97
PCK4BITS(2,2,2,2,2,2,2,2), // 98 - 9f
PCK4BITS(2,2,2,2,2,2,2,2), // a0 - a7
PCK4BITS(2,2,2,2,2,2,2,2), // a8 - af
PCK4BITS(2,2,2,2,2,2,2,2), // b0 - b7
PCK4BITS(2,2,2,2,2,2,2,2), // b8 - bf
PCK4BITS(2,2,2,2,2,2,2,2), // c0 - c7
PCK4BITS(2,2,2,2,2,2,2,2), // c8 - cf
PCK4BITS(2,2,2,2,2,2,2,2), // d0 - d7
PCK4BITS(2,2,2,2,2,2,2,2), // d8 - df
PCK4BITS(2,2,2,2,2,2,2,2), // e0 - e7
PCK4BITS(2,2,2,2,2,2,2,2), // e8 - ef
PCK4BITS(2,2,2,2,2,2,2,2), // f0 - f7
PCK4BITS(2,2,2,2,2,2,2,2) // f8 - ff
};
static PRUint32 ISO2022CN_st [ 8] = {
PCK4BITS(eStart, 3,eError,eStart,eStart,eStart,eStart,eStart),//00-07
PCK4BITS(eStart,eError,eError,eError,eError,eError,eError,eError),//08-0f
PCK4BITS(eError,eError,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe),//10-17
PCK4BITS(eItsMe,eItsMe,eItsMe,eError,eError,eError, 4,eError),//18-1f
PCK4BITS(eError,eError,eError,eItsMe,eError,eError,eError,eError),//20-27
PCK4BITS( 5, 6,eError,eError,eError,eError,eError,eError),//28-2f
PCK4BITS(eError,eError,eError,eItsMe,eError,eError,eError,eError),//30-37
PCK4BITS(eError,eError,eError,eError,eError,eItsMe,eError,eStart) //38-3f
};
static nsVerifier nsISO2022CNVerifier = {
"ISO-2022-CN",
{
eIdxSft4bits,
eSftMsk4bits,
eBitSft4bits,
eUnitMsk4bits,
ISO2022CN_cls
},
9,
{
eIdxSft4bits,
eSftMsk4bits,
eBitSft4bits,
eUnitMsk4bits,
ISO2022CN_st
}
};

Просмотреть файл

@ -25,15 +25,15 @@
#include "nsVerifier.h"
static PRUint32 ISO2022JP_cls [ 256 / 8 ] = {
PCK4BITS(2,0,0,0,0,0,0,0), // 00 - 07
PCK4BITS(0,0,0,0,0,0,0,0), // 08 - 0f
PCK4BITS(0,0,0,0,0,0,2,2), // 08 - 0f
PCK4BITS(0,0,0,0,0,0,0,0), // 10 - 17
PCK4BITS(0,0,0,1,0,0,0,0), // 18 - 1f
PCK4BITS(0,0,0,0,0,0,0,0), // 20 - 27
PCK4BITS(0,0,0,0,0,0,0,0), // 28 - 2f
PCK4BITS(0,0,0,0,7,0,0,0), // 20 - 27
PCK4BITS(3,0,0,0,0,0,0,0), // 28 - 2f
PCK4BITS(0,0,0,0,0,0,0,0), // 30 - 37
PCK4BITS(0,0,0,0,0,0,0,0), // 38 - 3f
PCK4BITS(0,0,0,0,0,0,0,0), // 40 - 47
PCK4BITS(0,0,0,0,0,0,0,0), // 48 - 4f
PCK4BITS(6,0,4,0,0,0,0,0), // 40 - 47
PCK4BITS(0,0,5,0,0,0,0,0), // 48 - 4f
PCK4BITS(0,0,0,0,0,0,0,0), // 50 - 57
PCK4BITS(0,0,0,0,0,0,0,0), // 58 - 5f
PCK4BITS(0,0,0,0,0,0,0,0), // 60 - 67
@ -59,9 +59,13 @@ PCK4BITS(2,2,2,2,2,2,2,2) // f8 - ff
};
static PRUint32 ISO2022JP_st [ 2] = {
PCK4BITS(eStart,eItsMe,eError,eError,eError,eError,eItsMe,eItsMe),//00-07
PCK4BITS(eItsMe,eStart,eStart,eStart,eStart,eStart,eStart,eStart) //08-0f
static PRUint32 ISO2022JP_st [ 6] = {
PCK4BITS(eStart, 3,eError,eStart,eStart,eStart,eStart,eStart),//00-07
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//08-0f
PCK4BITS(eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe),//10-17
PCK4BITS(eError,eError,eError, 5,eError,eError,eError, 4),//18-1f
PCK4BITS(eError,eError,eError,eError,eItsMe,eError,eItsMe,eError),//20-27
PCK4BITS(eError,eError,eError,eError,eItsMe,eItsMe,eError,eError) //28-2f
};
@ -74,7 +78,7 @@ static nsVerifier nsISO2022JPVerifier = {
eUnitMsk4bits,
ISO2022JP_cls
},
3,
8,
{
eIdxSft4bits,
eSftMsk4bits,

Просмотреть файл

@ -0,0 +1,88 @@
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
*
* The contents of this file are subject to the Netscape Public License
* Version 1.0 (the "NPL"); you may not use this file except in
* compliance with the NPL. You may obtain a copy of the NPL at
* http://www.mozilla.org/NPL/
*
* Software distributed under the NPL is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
* for the specific language governing rights and limitations under the
* NPL.
*
* The Initial Developer of this code under the NPL is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All Rights
* Reserved.
*/
/*
* DO NOT EDIT THIS DOCUMENT MANUALLY !!!
* THIS FILE IS AUTOMATICALLY GENERATED BY THE TOOLS UNDER
* mozilla/intl/chardet/tools/
* Please contact ftang@netscape.com or mozilla-i18n@mozilla.org
* if you have any question. Thanks
*/
#include "nsVerifier.h"
static PRUint32 ISO2022KR_cls [ 256 / 8 ] = {
PCK4BITS(2,0,0,0,0,0,0,0), // 00 - 07
PCK4BITS(0,0,0,0,0,0,0,0), // 08 - 0f
PCK4BITS(0,0,0,0,0,0,0,0), // 10 - 17
PCK4BITS(0,0,0,1,0,0,0,0), // 18 - 1f
PCK4BITS(0,0,0,0,3,0,0,0), // 20 - 27
PCK4BITS(0,4,0,0,0,0,0,0), // 28 - 2f
PCK4BITS(0,0,0,0,0,0,0,0), // 30 - 37
PCK4BITS(0,0,0,0,0,0,0,0), // 38 - 3f
PCK4BITS(0,0,0,5,0,0,0,0), // 40 - 47
PCK4BITS(0,0,0,0,0,0,0,0), // 48 - 4f
PCK4BITS(0,0,0,0,0,0,0,0), // 50 - 57
PCK4BITS(0,0,0,0,0,0,0,0), // 58 - 5f
PCK4BITS(0,0,0,0,0,0,0,0), // 60 - 67
PCK4BITS(0,0,0,0,0,0,0,0), // 68 - 6f
PCK4BITS(0,0,0,0,0,0,0,0), // 70 - 77
PCK4BITS(0,0,0,0,0,0,0,0), // 78 - 7f
PCK4BITS(2,2,2,2,2,2,2,2), // 80 - 87
PCK4BITS(2,2,2,2,2,2,2,2), // 88 - 8f
PCK4BITS(2,2,2,2,2,2,2,2), // 90 - 97
PCK4BITS(2,2,2,2,2,2,2,2), // 98 - 9f
PCK4BITS(2,2,2,2,2,2,2,2), // a0 - a7
PCK4BITS(2,2,2,2,2,2,2,2), // a8 - af
PCK4BITS(2,2,2,2,2,2,2,2), // b0 - b7
PCK4BITS(2,2,2,2,2,2,2,2), // b8 - bf
PCK4BITS(2,2,2,2,2,2,2,2), // c0 - c7
PCK4BITS(2,2,2,2,2,2,2,2), // c8 - cf
PCK4BITS(2,2,2,2,2,2,2,2), // d0 - d7
PCK4BITS(2,2,2,2,2,2,2,2), // d8 - df
PCK4BITS(2,2,2,2,2,2,2,2), // e0 - e7
PCK4BITS(2,2,2,2,2,2,2,2), // e8 - ef
PCK4BITS(2,2,2,2,2,2,2,2), // f0 - f7
PCK4BITS(2,2,2,2,2,2,2,2) // f8 - ff
};
static PRUint32 ISO2022KR_st [ 5] = {
PCK4BITS(eStart, 3,eError,eStart,eStart,eStart,eError,eError),//00-07
PCK4BITS(eError,eError,eError,eError,eItsMe,eItsMe,eItsMe,eItsMe),//08-0f
PCK4BITS(eItsMe,eItsMe,eError,eError,eError, 4,eError,eError),//10-17
PCK4BITS(eError,eError,eError,eError, 5,eError,eError,eError),//18-1f
PCK4BITS(eError,eError,eError,eItsMe,eStart,eStart,eStart,eStart) //20-27
};
static nsVerifier nsISO2022KRVerifier = {
"ISO-2022-KR",
{
eIdxSft4bits,
eSftMsk4bits,
eBitSft4bits,
eUnitMsk4bits,
ISO2022KR_cls
},
6,
{
eIdxSft4bits,
eSftMsk4bits,
eBitSft4bits,
eUnitMsk4bits,
ISO2022KR_st
}
};

Разница между файлами не показана из-за своего большого размера Загрузить разницу

Просмотреть файл

@ -77,17 +77,6 @@
nsIFactory* NEW_JA_PSMDETECTOR_FACTORY();
nsIFactory* NEW_JA_STRING_PSMDETECTOR_FACTORY();
nsIFactory* NEW_KO_PSMDETECTOR_FACTORY();
nsIFactory* NEW_KO_STRING_PSMDETECTOR_FACTORY();
nsIFactory* NEW_ZHCN_PSMDETECTOR_FACTORY();
nsIFactory* NEW_ZHCN_STRING_PSMDETECTOR_FACTORY();
nsIFactory* NEW_ZHTW_PSMDETECTOR_FACTORY();
nsIFactory* NEW_ZHTW_STRING_PSMDETECTOR_FACTORY();
nsIFactory* NEW_ZH_PSMDETECTOR_FACTORY();
nsIFactory* NEW_ZH_STRING_PSMDETECTOR_FACTORY();
nsIFactory* NEW_CJK_PSMDETECTOR_FACTORY();
nsIFactory* NEW_CJK_STRING_PSMDETECTOR_FACTORY();
nsIFactory* NEW_PSMDETECTOR_FACTORY(const nsCID& aClass);
#endif // nsPSMDetectors_h__

Просмотреть файл

@ -25,7 +25,7 @@
#include "nsVerifier.h"
static PRUint32 SJIS_cls [ 256 / 8 ] = {
PCK4BITS(0,1,1,1,1,1,1,1), // 00 - 07
PCK4BITS(1,1,1,1,1,1,1,1), // 08 - 0f
PCK4BITS(1,1,1,1,1,1,0,0), // 08 - 0f
PCK4BITS(1,1,1,1,1,1,1,1), // 10 - 17
PCK4BITS(1,1,1,0,1,1,1,1), // 18 - 1f
PCK4BITS(1,1,1,1,1,1,1,1), // 20 - 27
@ -52,17 +52,17 @@ PCK4BITS(2,2,2,2,2,2,2,2), // c0 - c7
PCK4BITS(2,2,2,2,2,2,2,2), // c8 - cf
PCK4BITS(2,2,2,2,2,2,2,2), // d0 - d7
PCK4BITS(2,2,2,2,2,2,2,2), // d8 - df
PCK4BITS(5,5,5,5,5,5,5,5), // e0 - e7
PCK4BITS(5,5,5,5,5,5,5,5), // e8 - ef
PCK4BITS(5,5,5,5,5,5,5,5), // f0 - f7
PCK4BITS(5,5,5,5,5,0,0,0) // f8 - ff
PCK4BITS(3,3,3,3,3,3,3,3), // e0 - e7
PCK4BITS(3,3,3,3,3,3,3,3), // e8 - ef
PCK4BITS(3,3,3,3,3,3,3,3), // f0 - f7
PCK4BITS(3,3,3,3,3,0,0,0) // f8 - ff
};
static PRUint32 SJIS_st [ 3] = {
PCK4BITS(eError,eStart,eStart, 3,eError, 3,eError,eError),//00-07
PCK4BITS(eError,eError,eError,eError,eItsMe,eItsMe,eItsMe,eItsMe),//08-0f
PCK4BITS(eItsMe,eItsMe,eError,eError,eStart,eStart,eError,eStart) //10-17
PCK4BITS(eError,eStart,eStart, 3,eError,eError,eError,eError),//00-07
PCK4BITS(eError,eError,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eError),//08-0f
PCK4BITS(eError,eStart,eStart,eStart,eStart,eStart,eStart,eStart) //10-17
};
@ -75,7 +75,7 @@ static nsVerifier nsSJISVerifier = {
eUnitMsk4bits,
SJIS_cls
},
6,
5,
{
eIdxSft4bits,
eSftMsk4bits,

Просмотреть файл

@ -24,51 +24,49 @@
*/
#include "nsVerifier.h"
static PRUint32 UCS2BE_cls [ 256 / 8 ] = {
PCK4BITS(1,7,7,7,7,7,7,7), // 00 - 07
PCK4BITS(7,7,4,7,7,3,7,7), // 08 - 0f
PCK4BITS(7,7,7,7,7,7,7,7), // 10 - 17
PCK4BITS(7,7,7,7,7,7,7,7), // 18 - 1f
PCK4BITS(7,7,7,7,7,7,7,7), // 20 - 27
PCK4BITS(0,0,0,0,0,0,0,0), // 28 - 2f
PCK4BITS(7,7,7,7,0,0,0,0), // 30 - 37
PCK4BITS(0,0,7,7,7,7,7,7), // 38 - 3f
PCK4BITS(7,0,0,0,0,0,0,0), // 40 - 47
PCK4BITS(0,0,0,0,0,0,7,7), // 48 - 4f
PCK4BITS(7,7,7,7,7,7,7,7), // 50 - 57
PCK4BITS(7,7,7,7,7,7,7,7), // 58 - 5f
PCK4BITS(7,7,7,7,7,7,7,7), // 60 - 67
PCK4BITS(7,7,7,7,7,7,7,7), // 68 - 6f
PCK4BITS(7,7,7,7,7,7,7,7), // 70 - 77
PCK4BITS(7,7,7,7,7,7,7,7), // 78 - 7f
PCK4BITS(2,2,2,2,2,2,2,2), // 80 - 87
PCK4BITS(2,2,2,2,2,2,2,2), // 88 - 8f
PCK4BITS(2,2,2,2,2,2,2,2), // 90 - 97
PCK4BITS(2,2,2,2,2,2,2,2), // 98 - 9f
PCK4BITS(7,7,7,7,7,7,7,7), // a0 - a7
PCK4BITS(7,7,7,7,7,7,7,7), // a8 - af
PCK4BITS(7,7,7,7,7,7,7,7), // b0 - b7
PCK4BITS(7,7,7,7,7,7,7,7), // b8 - bf
PCK4BITS(7,7,7,7,7,7,7,7), // c0 - c7
PCK4BITS(7,7,7,7,7,7,7,7), // c8 - cf
PCK4BITS(7,7,7,7,7,7,7,7), // d0 - d7
PCK4BITS(7,7,7,7,7,7,7,7), // d8 - df
PCK4BITS(7,7,7,7,7,7,7,7), // e0 - e7
PCK4BITS(7,7,7,7,7,7,7,7), // e8 - ef
PCK4BITS(7,7,7,7,7,7,7,7), // f0 - f7
PCK4BITS(7,7,7,7,7,7,5,6) // f8 - ff
PCK4BITS(0,0,0,0,0,0,0,0), // 00 - 07
PCK4BITS(0,0,1,0,0,2,0,0), // 08 - 0f
PCK4BITS(0,0,0,0,0,0,0,0), // 10 - 17
PCK4BITS(0,0,0,3,0,0,0,0), // 18 - 1f
PCK4BITS(0,0,0,0,0,0,0,0), // 20 - 27
PCK4BITS(0,3,3,3,3,3,0,0), // 28 - 2f
PCK4BITS(0,0,0,0,0,0,0,0), // 30 - 37
PCK4BITS(0,0,0,0,0,0,0,0), // 38 - 3f
PCK4BITS(0,0,0,0,0,0,0,0), // 40 - 47
PCK4BITS(0,0,0,0,0,0,0,0), // 48 - 4f
PCK4BITS(0,0,0,0,0,0,0,0), // 50 - 57
PCK4BITS(0,0,0,0,0,0,0,0), // 58 - 5f
PCK4BITS(0,0,0,0,0,0,0,0), // 60 - 67
PCK4BITS(0,0,0,0,0,0,0,0), // 68 - 6f
PCK4BITS(0,0,0,0,0,0,0,0), // 70 - 77
PCK4BITS(0,0,0,0,0,0,0,0), // 78 - 7f
PCK4BITS(0,0,0,0,0,0,0,0), // 80 - 87
PCK4BITS(0,0,0,0,0,0,0,0), // 88 - 8f
PCK4BITS(0,0,0,0,0,0,0,0), // 90 - 97
PCK4BITS(0,0,0,0,0,0,0,0), // 98 - 9f
PCK4BITS(0,0,0,0,0,0,0,0), // a0 - a7
PCK4BITS(0,0,0,0,0,0,0,0), // a8 - af
PCK4BITS(0,0,0,0,0,0,0,0), // b0 - b7
PCK4BITS(0,0,0,0,0,0,0,0), // b8 - bf
PCK4BITS(0,0,0,0,0,0,0,0), // c0 - c7
PCK4BITS(0,0,0,0,0,0,0,0), // c8 - cf
PCK4BITS(0,0,0,0,0,0,0,0), // d0 - d7
PCK4BITS(0,0,0,0,0,0,0,0), // d8 - df
PCK4BITS(0,0,0,0,0,0,0,0), // e0 - e7
PCK4BITS(0,0,0,0,0,0,0,0), // e8 - ef
PCK4BITS(0,0,0,0,0,0,0,0), // f0 - f7
PCK4BITS(0,0,0,0,0,0,4,5) // f8 - ff
};
static PRUint32 UCS2BE_st [ 9] = {
PCK4BITS(eError, 5, 3, 6, 6, 7, 8, 3),//00-07
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//08-0f
PCK4BITS(eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe),//10-17
PCK4BITS( 4, 4, 4, 4, 4, 4, 4, 4),//18-1f
PCK4BITS(eError, 5, 3, 6, 6, 3, 3, 3),//20-27
PCK4BITS( 4, 4,eError, 4, 4, 4, 4, 4),//28-2f
PCK4BITS( 4, 4, 4,eError, 4, 4, 4, 4),//30-37
PCK4BITS( 4, 4, 4, 4, 4, 4,eItsMe, 4),//38-3f
PCK4BITS( 4, 4, 4, 4, 4,eError, 4, 4) //40-47
static PRUint32 UCS2BE_st [ 7] = {
PCK4BITS( 5, 7, 7,eError, 4, 3,eError,eError),//00-07
PCK4BITS(eError,eError,eError,eError,eItsMe,eItsMe,eItsMe,eItsMe),//08-0f
PCK4BITS(eItsMe,eItsMe, 6, 6, 6, 6,eError,eError),//10-17
PCK4BITS( 6, 6, 6, 6, 6,eItsMe, 6, 6),//18-1f
PCK4BITS( 6, 6, 6, 6, 5, 7, 7,eError),//20-27
PCK4BITS( 5, 8, 6, 6,eError, 6, 6, 6),//28-2f
PCK4BITS( 6, 6, 6, 6,eError,eError,eStart,eStart) //30-37
};
@ -81,7 +79,7 @@ static nsVerifier nsUCS2BEVerifier = {
eUnitMsk4bits,
UCS2BE_cls
},
8,
6,
{
eIdxSft4bits,
eSftMsk4bits,

Просмотреть файл

@ -24,51 +24,49 @@
*/
#include "nsVerifier.h"
static PRUint32 UCS2LE_cls [ 256 / 8 ] = {
PCK4BITS(1,7,7,7,7,7,7,7), // 00 - 07
PCK4BITS(7,7,4,7,7,3,7,7), // 08 - 0f
PCK4BITS(7,7,7,7,7,7,7,7), // 10 - 17
PCK4BITS(7,7,7,7,7,7,7,7), // 18 - 1f
PCK4BITS(7,7,7,7,7,7,7,7), // 20 - 27
PCK4BITS(0,0,0,0,0,0,0,0), // 28 - 2f
PCK4BITS(7,7,7,7,0,0,0,0), // 30 - 37
PCK4BITS(0,0,7,7,7,7,7,7), // 38 - 3f
PCK4BITS(7,0,0,0,0,0,0,0), // 40 - 47
PCK4BITS(0,0,0,0,0,0,7,7), // 48 - 4f
PCK4BITS(7,7,7,7,7,7,7,7), // 50 - 57
PCK4BITS(7,7,7,7,7,7,7,7), // 58 - 5f
PCK4BITS(7,7,7,7,7,7,7,7), // 60 - 67
PCK4BITS(7,7,7,7,7,7,7,7), // 68 - 6f
PCK4BITS(7,7,7,7,7,7,7,7), // 70 - 77
PCK4BITS(7,7,7,7,7,7,7,7), // 78 - 7f
PCK4BITS(2,2,2,2,2,2,2,2), // 80 - 87
PCK4BITS(2,2,2,2,2,2,2,2), // 88 - 8f
PCK4BITS(2,2,2,2,2,2,2,2), // 90 - 97
PCK4BITS(2,2,2,2,2,2,2,2), // 98 - 9f
PCK4BITS(7,7,7,7,7,7,7,7), // a0 - a7
PCK4BITS(7,7,7,7,7,7,7,7), // a8 - af
PCK4BITS(7,7,7,7,7,7,7,7), // b0 - b7
PCK4BITS(7,7,7,7,7,7,7,7), // b8 - bf
PCK4BITS(7,7,7,7,7,7,7,7), // c0 - c7
PCK4BITS(7,7,7,7,7,7,7,7), // c8 - cf
PCK4BITS(7,7,7,7,7,7,7,7), // d0 - d7
PCK4BITS(7,7,7,7,7,7,7,7), // d8 - df
PCK4BITS(7,7,7,7,7,7,7,7), // e0 - e7
PCK4BITS(7,7,7,7,7,7,7,7), // e8 - ef
PCK4BITS(7,7,7,7,7,7,7,7), // f0 - f7
PCK4BITS(7,7,7,7,7,7,5,6) // f8 - ff
PCK4BITS(0,0,0,0,0,0,0,0), // 00 - 07
PCK4BITS(0,0,1,0,0,2,0,0), // 08 - 0f
PCK4BITS(0,0,0,0,0,0,0,0), // 10 - 17
PCK4BITS(0,0,0,3,0,0,0,0), // 18 - 1f
PCK4BITS(0,0,0,0,0,0,0,0), // 20 - 27
PCK4BITS(0,3,3,3,3,3,0,0), // 28 - 2f
PCK4BITS(0,0,0,0,0,0,0,0), // 30 - 37
PCK4BITS(0,0,0,0,0,0,0,0), // 38 - 3f
PCK4BITS(0,0,0,0,0,0,0,0), // 40 - 47
PCK4BITS(0,0,0,0,0,0,0,0), // 48 - 4f
PCK4BITS(0,0,0,0,0,0,0,0), // 50 - 57
PCK4BITS(0,0,0,0,0,0,0,0), // 58 - 5f
PCK4BITS(0,0,0,0,0,0,0,0), // 60 - 67
PCK4BITS(0,0,0,0,0,0,0,0), // 68 - 6f
PCK4BITS(0,0,0,0,0,0,0,0), // 70 - 77
PCK4BITS(0,0,0,0,0,0,0,0), // 78 - 7f
PCK4BITS(0,0,0,0,0,0,0,0), // 80 - 87
PCK4BITS(0,0,0,0,0,0,0,0), // 88 - 8f
PCK4BITS(0,0,0,0,0,0,0,0), // 90 - 97
PCK4BITS(0,0,0,0,0,0,0,0), // 98 - 9f
PCK4BITS(0,0,0,0,0,0,0,0), // a0 - a7
PCK4BITS(0,0,0,0,0,0,0,0), // a8 - af
PCK4BITS(0,0,0,0,0,0,0,0), // b0 - b7
PCK4BITS(0,0,0,0,0,0,0,0), // b8 - bf
PCK4BITS(0,0,0,0,0,0,0,0), // c0 - c7
PCK4BITS(0,0,0,0,0,0,0,0), // c8 - cf
PCK4BITS(0,0,0,0,0,0,0,0), // d0 - d7
PCK4BITS(0,0,0,0,0,0,0,0), // d8 - df
PCK4BITS(0,0,0,0,0,0,0,0), // e0 - e7
PCK4BITS(0,0,0,0,0,0,0,0), // e8 - ef
PCK4BITS(0,0,0,0,0,0,0,0), // f0 - f7
PCK4BITS(0,0,0,0,0,0,4,5) // f8 - ff
};
static PRUint32 UCS2LE_st [ 9] = {
PCK4BITS( 3, 3, 5, 6, 3, 8, 7, 3),//00-07
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//08-0f
PCK4BITS(eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe),//10-17
PCK4BITS(eError, 4, 4, 4, 4, 4, 4, 4),//18-1f
PCK4BITS( 3, 3, 5, 6, 3, 3, 3, 3),//20-27
PCK4BITS( 4,eError, 4, 4, 4, 4, 4, 4),//28-2f
PCK4BITS( 4, 4, 4,eError,eError, 4, 4, 4),//30-37
PCK4BITS(eError, 4, 4, 4, 4,eItsMe, 4, 4),//38-3f
PCK4BITS(eError, 4, 4, 4, 4, 4,eError, 4) //40-47
static PRUint32 UCS2LE_st [ 7] = {
PCK4BITS( 6, 6, 7, 6, 4, 3,eError,eError),//00-07
PCK4BITS(eError,eError,eError,eError,eItsMe,eItsMe,eItsMe,eItsMe),//08-0f
PCK4BITS(eItsMe,eItsMe, 5, 5, 5,eError,eItsMe,eError),//10-17
PCK4BITS( 5, 5, 5,eError, 5,eError, 6, 6),//18-1f
PCK4BITS( 7, 6, 8, 8, 5, 5, 5,eError),//20-27
PCK4BITS( 5, 5, 5,eError,eError,eError, 5, 5),//28-2f
PCK4BITS( 5, 5, 5,eError, 5,eError,eStart,eStart) //30-37
};
@ -81,7 +79,7 @@ static nsVerifier nsUCS2LEVerifier = {
eUnitMsk4bits,
UCS2LE_cls
},
8,
6,
{
eIdxSft4bits,
eSftMsk4bits,

Просмотреть файл

@ -25,7 +25,7 @@
#include "nsVerifier.h"
static PRUint32 UTF8_cls [ 256 / 8 ] = {
PCK4BITS(0,1,1,1,1,1,1,1), // 00 - 07
PCK4BITS(1,1,1,1,1,1,1,1), // 08 - 0f
PCK4BITS(1,1,1,1,1,1,0,0), // 08 - 0f
PCK4BITS(1,1,1,1,1,1,1,1), // 10 - 17
PCK4BITS(1,1,1,0,1,1,1,1), // 18 - 1f
PCK4BITS(1,1,1,1,1,1,1,1), // 20 - 27
@ -40,50 +40,52 @@ PCK4BITS(1,1,1,1,1,1,1,1), // 60 - 67
PCK4BITS(1,1,1,1,1,1,1,1), // 68 - 6f
PCK4BITS(1,1,1,1,1,1,1,1), // 70 - 77
PCK4BITS(1,1,1,1,1,1,1,1), // 78 - 7f
PCK4BITS(2,2,3,3,3,3,3,3), // 80 - 87
PCK4BITS(2,2,2,2,3,3,3,3), // 80 - 87
PCK4BITS(4,4,4,4,4,4,4,4), // 88 - 8f
PCK4BITS(5,5,5,5,5,5,5,5), // 90 - 97
PCK4BITS(5,5,5,5,5,5,5,5), // 98 - 9f
PCK4BITS(6,6,6,6,6,6,6,6), // a0 - a7
PCK4BITS(6,6,6,6,6,6,6,6), // a8 - af
PCK4BITS(6,6,6,6,6,6,6,6), // b0 - b7
PCK4BITS(6,6,6,6,6,6,6,6), // b8 - bf
PCK4BITS(0,0,7,7,7,7,7,7), // c0 - c7
PCK4BITS(7,7,7,7,7,7,7,7), // c8 - cf
PCK4BITS(7,7,7,7,7,7,7,7), // d0 - d7
PCK4BITS(7,7,7,7,7,7,7,7), // d8 - df
PCK4BITS(8,8,8,8,8,8,8,8), // e0 - e7
PCK4BITS(8,8,8,8,8,8,9,9), // e8 - ef
PCK4BITS(4,4,4,4,4,4,4,4), // 90 - 97
PCK4BITS(4,4,4,4,4,4,4,4), // 98 - 9f
PCK4BITS(5,5,5,5,5,5,5,5), // a0 - a7
PCK4BITS(5,5,5,5,5,5,5,5), // a8 - af
PCK4BITS(5,5,5,5,5,5,5,5), // b0 - b7
PCK4BITS(5,5,5,5,5,5,5,5), // b8 - bf
PCK4BITS(0,0,6,6,6,6,6,6), // c0 - c7
PCK4BITS(6,6,6,6,6,6,6,6), // c8 - cf
PCK4BITS(6,6,6,6,6,6,6,6), // d0 - d7
PCK4BITS(6,6,6,6,6,6,6,6), // d8 - df
PCK4BITS(7,8,8,8,8,8,8,8), // e0 - e7
PCK4BITS(8,8,8,8,8,9,8,8), // e8 - ef
PCK4BITS(10,11,11,11,11,11,11,11), // f0 - f7
PCK4BITS(12,13,13,13,14,15,0,0) // f8 - ff
};
static PRUint32 UTF8_st [ 24] = {
PCK4BITS(eError,eStart,eError,eError,eError,eError,eError, 3),//00-07
PCK4BITS( 8, 4, 9, 5, 10, 6, 7, 11),//08-0f
static PRUint32 UTF8_st [ 26] = {
PCK4BITS(eError,eStart,eError,eError,eError,eError, 12, 10),//00-07
PCK4BITS( 9, 11, 8, 7, 6, 5, 4, 3),//08-0f
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//10-17
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//18-1f
PCK4BITS(eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe),//20-27
PCK4BITS(eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe,eItsMe),//28-2f
PCK4BITS(eError,eError,eStart,eStart,eStart,eStart,eStart,eError),//30-37
PCK4BITS(eError,eError, 5, 5, 5, 5,eError,eError),//30-37
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//38-3f
PCK4BITS(eError,eError, 3, 3, 3, 3, 3,eError),//40-47
PCK4BITS(eError,eError,eError, 5, 5, 5,eError,eError),//40-47
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//48-4f
PCK4BITS(eError,eError, 4, 4, 4, 4, 4,eError),//50-57
PCK4BITS(eError,eError, 7, 7, 7, 7,eError,eError),//50-57
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//58-5f
PCK4BITS(eError,eError, 5, 5, 5, 5, 5,eError),//60-67
PCK4BITS(eError,eError,eError,eError, 7, 7,eError,eError),//60-67
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//68-6f
PCK4BITS(eError,eError, 6, 6, 6, 6, 6,eError),//70-77
PCK4BITS(eError,eError, 9, 9, 9, 9,eError,eError),//70-77
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//78-7f
PCK4BITS(eError,eError,eError,eError,eError,eError, 3,eError),//80-87
PCK4BITS(eError,eError,eError,eError,eError, 9,eError,eError),//80-87
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//88-8f
PCK4BITS(eError,eError,eError,eError,eError, 3, 3,eError),//90-97
PCK4BITS(eError,eError, 12, 12, 12, 12,eError,eError),//90-97
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//98-9f
PCK4BITS(eError,eError,eError,eError, 3, 3, 3,eError),//a0-a7
PCK4BITS(eError,eError,eError,eError,eError, 12,eError,eError),//a0-a7
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//a8-af
PCK4BITS(eError,eError,eError, 3, 3, 3, 3,eError),//b0-b7
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError) //b8-bf
PCK4BITS(eError,eError, 12, 12, 12,eError,eError,eError),//b0-b7
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError),//b8-bf
PCK4BITS(eError,eError,eStart,eStart,eStart,eStart,eError,eError),//c0-c7
PCK4BITS(eError,eError,eError,eError,eError,eError,eError,eError) //c8-cf
};