Changeset 220 for trunk/src/gui/text/qfontdatabase.cpp
- Timestamp:
- Oct 12, 2009, 11:37:39 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/gui/text/qfontdatabase.cpp
r124 r220 54 54 #include <locale.h> 55 55 #endif 56 #ifdef Q_WS_PM 57 #include "qt_os2.h" 58 #endif 59 56 60 #include <stdlib.h> 57 61 #include <limits.h> … … 74 78 # define for if(0){}else for 75 79 #endif 80 81 #define SMOOTH_SCALABLE 0xffff 76 82 77 83 QT_BEGIN_NAMESPACE … … 146 152 int fileIndex; 147 153 #endif 154 #ifdef Q_WS_PM 155 unsigned short pointSize; // in deca-points 156 LONG lMatch; 157 #endif 148 158 }; 149 159 … … 209 219 weightName = setwidthName = 0; 210 220 #endif // Q_WS_X11 221 #if defined(Q_WS_PM) 222 faceName[0] = 0; 223 #endif 211 224 } 212 225 … … 242 255 bool antialiased; 243 256 #endif 244 257 #ifdef Q_WS_PM 258 CHAR faceName[FACESIZE]; 259 #endif 260 261 #ifdef Q_WS_PM 262 QtFontSize *pixelSize(unsigned short size, bool = false, 263 unsigned short pointSize = 0); 264 #else 245 265 QtFontSize *pixelSize(unsigned short size, bool = false); 266 #endif 246 267 }; 247 268 … … 259 280 } 260 281 282 #ifdef Q_WS_PM 283 QtFontSize *QtFontStyle::pixelSize(unsigned short size, bool add, 284 unsigned short pointSize) 285 #else 261 286 QtFontSize *QtFontStyle::pixelSize(unsigned short size, bool add) 287 #endif 262 288 { 263 289 for (int i = 0; i < count; i++) { 290 #ifdef Q_WS_PM 291 if (pixelSizes[i].pixelSize == size && 292 (size == SMOOTH_SCALABLE || !pointSize || 293 pixelSizes[i].pointSize == pointSize)) 294 return pixelSizes + i; 295 #else 264 296 if (pixelSizes[i].pixelSize == size) 265 297 return pixelSizes + i; 298 #endif 266 299 } 267 300 if (!add) … … 280 313 new (&pixelSizes[count].fileName) QByteArray; 281 314 pixelSizes[count].fileIndex = 0; 315 #endif 316 #ifdef Q_WS_PM 317 pixelSizes[count].pointSize = pointSize; 318 pixelSizes[count].lMatch = 0; 282 319 #endif 283 320 return pixelSizes + (count++); … … 364 401 { 365 402 memset(writingSystems, 0, sizeof(writingSystems)); 403 #ifdef Q_WS_PM 404 // the concept of writing systems isn't used, let's support just Any 405 writingSystems[QFontDatabase::Any] = Supported; 406 #endif 366 407 } 367 408 ~QtFontFamily() { … … 867 908 } 868 909 869 #define SMOOTH_SCALABLE 0xffff870 871 910 QT_BEGIN_INCLUDE_NAMESPACE 872 911 #if defined(Q_WS_X11)
Note:
See TracChangeset
for help on using the changeset viewer.