#115114 autodetect universal detects french as Central European (ISO-8859-2)
removing latin2 and win1250 prober to prevent latin1 confusion. r=ftang, sr=scc, a=rjesup, adt git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_0_BRANCH@119745 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -55,8 +55,11 @@ nsSBCSGroupProber::nsSBCSGroupProber()
|
||||
mProbers[7] = new nsSingleByteCharSetProber(&Win1253Model);
|
||||
mProbers[8] = new nsSingleByteCharSetProber(&Latin5BulgarianModel);
|
||||
mProbers[9] = new nsSingleByteCharSetProber(&Win1251BulgarianModel);
|
||||
mProbers[10] = new nsSingleByteCharSetProber(&Latin2HungarianModel);
|
||||
mProbers[11] = new nsSingleByteCharSetProber(&Win1250HungarianModel);
|
||||
|
||||
// disable latin2 before latin1 is available, otherwise all latin1
|
||||
// will be detected as latin2 because of their similarity.
|
||||
//mProbers[10] = new nsSingleByteCharSetProber(&Latin2HungarianModel);
|
||||
//mProbers[11] = new nsSingleByteCharSetProber(&Win1250HungarianModel);
|
||||
|
||||
Reset();
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
#define nsSBCSGroupProber_h__
|
||||
|
||||
|
||||
#define NUM_OF_SBCS_PROBERS 12
|
||||
#define NUM_OF_SBCS_PROBERS 10
|
||||
|
||||
class nsSingleByteCharSetProber;
|
||||
class nsSBCSGroupProber: public nsCharSetProber {
|
||||
|
||||
@@ -98,7 +98,7 @@ float nsSingleByteCharSetProber::GetConfidence(void)
|
||||
float r;
|
||||
|
||||
if (mTotalSeqs > 0) {
|
||||
r = ((float)1.2) * mSeqCounters[POSITIVE_CAT] / mTotalSeqs / mModel->mTypicalPositiveRatio;
|
||||
r = ((float)1.0) * mSeqCounters[POSITIVE_CAT] / mTotalSeqs / mModel->mTypicalPositiveRatio;
|
||||
r = r*mFreqChar/mTotalChar;
|
||||
if (r >= (float)1.00)
|
||||
r = (float)0.99;
|
||||
|
||||
Reference in New Issue
Block a user