Changeset 318 for trunk/src/gui/text/qfontdatabase.cpp
- Timestamp:
- Nov 13, 2009, 11:57:53 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/gui/text/qfontdatabase.cpp
r223 r318 145 145 uint yres = 0, uint avgwidth = 0, bool add = false); 146 146 #endif // Q_WS_X11 147 #ifdef Q_WS_PM 148 QList<QFontDatabase::WritingSystem> systems; 149 #endif 147 150 #if defined(Q_WS_QWS) || defined(Q_WS_PM) 148 151 QByteArray fileName; … … 224 227 free(pixelSizes[count].encodings); 225 228 #endif 229 #ifdef Q_WS_PM 230 pixelSizes[count].systems.~QList<QFontDatabase::WritingSystem>(); 231 #endif 226 232 #if defined(Q_WS_QWS) || defined(Q_WS_PM) 227 233 pixelSizes[count].fileName.~QByteArray(); … … 279 285 pixelSizes[count].count = 0; 280 286 pixelSizes[count].encodings = 0; 287 #endif 288 #ifdef Q_WS_PM 289 new (&pixelSizes[count].systems) QList<QFontDatabase::WritingSystem>; 281 290 #endif 282 291 #if defined(Q_WS_QWS) || defined(Q_WS_PM) … … 965 974 #endif // Q_WS_X11 966 975 976 #if defined(Q_WS_PM) 977 static bool sizeSupportsScript(int script, QtFontSize *size) 978 { 979 // empty writing system list means we support all 980 // (see qfontdatabase_pm.cpp for explanation) 981 if (size->systems.isEmpty()) 982 return true; 983 foreach (QFontDatabase::WritingSystem ws, size->systems) { 984 if (scriptForWritingSystem[ws] == script) 985 return true; 986 } 987 return false; 988 } 989 #endif // Q_WS_PM 990 967 991 #if !defined(Q_WS_MAC) 968 992 static … … 1046 1070 } 1047 1071 #endif 1072 #ifdef Q_WS_PM 1073 if (!sizeSupportsScript(script, style->pixelSizes + x)) { 1074 FM_DEBUG(" size %3d does not support the script we want", 1075 style->pixelSizes[x].pixelSize); 1076 continue; 1077 } 1078 #endif 1048 1079 1049 1080 unsigned int d; … … 1090 1121 } 1091 1122 #endif // Q_WS_X11 1123 #ifdef Q_WS_PM 1124 if (size) { 1125 if (!sizeSupportsScript(script, size)) { 1126 size = 0; 1127 FM_DEBUG(" foundry doesn't support the script we want"); 1128 continue; 1129 } 1130 } 1131 #endif 1092 1132 1093 1133 unsigned int this_score = 0x0000;
Note:
See TracChangeset
for help on using the changeset viewer.