Fix mistake in function extraTryFontsForFamily

Taiwan and mainland China were inverted in the extraTryFontsForFamily
method. This patch fixes it and makes sure to match the rest of the
Chinese LANGIDs.

Task-number: QTBUG-33307
Change-Id: I45048ff5e9c00d20f8e922902701129e80ed459d
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
bb10
Allan Sandfeld Jensen 2014-08-14 12:19:22 +02:00
parent a128347c9b
commit cd912ce067
1 changed files with 4 additions and 4 deletions

View File

@ -1582,11 +1582,11 @@ QStringList QWindowsFontDatabase::extraTryFontsForFamily(const QString &family)
if (!tryFonts) {
LANGID lid = GetUserDefaultLangID();
switch (lid&0xff) {
case LANG_CHINESE: // Chinese (Taiwan)
if ( lid == 0x0804 ) // Taiwan
tryFonts = ch_TW_tryFonts;
else
case LANG_CHINESE: // Chinese
if ( lid == 0x0804 || lid == 0x1004) // China mainland and Singapore
tryFonts = ch_CN_tryFonts;
else
tryFonts = ch_TW_tryFonts; // Taiwan, Hong Kong and Macau
break;
case LANG_JAPANESE:
tryFonts = jp_tryFonts;