... |
... |
@@ -37,7 +37,7 @@ |
37
|
37
|
typedef struct FTC_BasicAttrRec_
|
38
|
38
|
{
|
39
|
39
|
FTC_ScalerRec scaler;
|
40
|
|
- FT_UInt load_flags;
|
|
40
|
+ FT_Int32 load_flags;
|
41
|
41
|
|
42
|
42
|
} FTC_BasicAttrRec, *FTC_BasicAttrs;
|
43
|
43
|
|
... |
... |
@@ -143,10 +143,9 @@ |
143
|
143
|
FT_Face face = size->face;
|
144
|
144
|
|
145
|
145
|
|
146
|
|
- error = FT_Load_Glyph(
|
147
|
|
- face,
|
148
|
|
- gindex,
|
149
|
|
- (FT_Int)family->attrs.load_flags | FT_LOAD_RENDER );
|
|
146
|
+ error = FT_Load_Glyph( face,
|
|
147
|
+ gindex,
|
|
148
|
+ family->attrs.load_flags | FT_LOAD_RENDER );
|
150
|
149
|
if ( !error )
|
151
|
150
|
*aface = face;
|
152
|
151
|
}
|
... |
... |
@@ -176,9 +175,7 @@ |
176
|
175
|
{
|
177
|
176
|
face = size->face;
|
178
|
177
|
|
179
|
|
- error = FT_Load_Glyph( face,
|
180
|
|
- gindex,
|
181
|
|
- (FT_Int)family->attrs.load_flags );
|
|
178
|
+ error = FT_Load_Glyph( face, gindex, family->attrs.load_flags );
|
182
|
179
|
if ( !error )
|
183
|
180
|
{
|
184
|
181
|
if ( face->glyph->format == FT_GLYPH_FORMAT_BITMAP ||
|
... |
... |
@@ -310,23 +307,10 @@ |
310
|
307
|
if ( anode )
|
311
|
308
|
*anode = NULL;
|
312
|
309
|
|
313
|
|
- /*
|
314
|
|
- * Internal `FTC_BasicAttr->load_flags' is of type `FT_UInt',
|
315
|
|
- * but public `FT_ImageType->flags' is of type `FT_Int32'.
|
316
|
|
- *
|
317
|
|
- * On 16bit systems, higher bits of type->flags cannot be handled.
|
318
|
|
- */
|
319
|
|
-#if 0xFFFFFFFFUL > FT_UINT_MAX
|
320
|
|
- if ( (type->flags & (FT_ULong)FT_UINT_MAX) )
|
321
|
|
- FT_TRACE1(( "FTC_ImageCache_Lookup:"
|
322
|
|
- " higher bits in load_flags 0x%lx are dropped\n",
|
323
|
|
- (FT_ULong)type->flags & ~((FT_ULong)FT_UINT_MAX) ));
|
324
|
|
-#endif
|
325
|
|
-
|
326
|
310
|
query.attrs.scaler.face_id = type->face_id;
|
327
|
311
|
query.attrs.scaler.width = type->width;
|
328
|
312
|
query.attrs.scaler.height = type->height;
|
329
|
|
- query.attrs.load_flags = (FT_UInt)type->flags;
|
|
313
|
+ query.attrs.load_flags = type->flags;
|
330
|
314
|
|
331
|
315
|
query.attrs.scaler.pixel = 1;
|
332
|
316
|
query.attrs.scaler.x_res = 0; /* make compilers happy */
|
... |
... |
@@ -392,20 +376,20 @@ |
392
|
376
|
*anode = NULL;
|
393
|
377
|
|
394
|
378
|
/*
|
395
|
|
- * Internal `FTC_BasicAttr->load_flags' is of type `FT_UInt',
|
|
379
|
+ * Internal `FTC_BasicAttr->load_flags' is of type `FT_Int32',
|
396
|
380
|
* but public `FT_Face->face_flags' is of type `FT_Long'.
|
397
|
381
|
*
|
398
|
382
|
* On long > int systems, higher bits of load_flags cannot be handled.
|
399
|
383
|
*/
|
400
|
|
-#if FT_ULONG_MAX > FT_UINT_MAX
|
401
|
|
- if ( load_flags > FT_UINT_MAX )
|
|
384
|
+#if FT_ULONG_MAX > 0xFFFFFFFFUL
|
|
385
|
+ if ( load_flags > 0xFFFFFFFFUL )
|
402
|
386
|
FT_TRACE1(( "FTC_ImageCache_LookupScaler:"
|
403
|
387
|
" higher bits in load_flags 0x%lx are dropped\n",
|
404
|
|
- load_flags & ~((FT_ULong)FT_UINT_MAX) ));
|
|
388
|
+ load_flags & ~0xFFFFFFFFUL ));
|
405
|
389
|
#endif
|
406
|
390
|
|
407
|
391
|
query.attrs.scaler = scaler[0];
|
408
|
|
- query.attrs.load_flags = (FT_UInt)load_flags;
|
|
392
|
+ query.attrs.load_flags = (FT_Int32)load_flags;
|
409
|
393
|
|
410
|
394
|
hash = FTC_BASIC_ATTR_HASH( &query.attrs ) + gindex;
|
411
|
395
|
|
... |
... |
@@ -508,23 +492,10 @@ |
508
|
492
|
|
509
|
493
|
*ansbit = NULL;
|
510
|
494
|
|
511
|
|
- /*
|
512
|
|
- * Internal `FTC_BasicAttr->load_flags' is of type `FT_UInt',
|
513
|
|
- * but public `FT_ImageType->flags' is of type `FT_Int32'.
|
514
|
|
- *
|
515
|
|
- * On 16bit systems, higher bits of type->flags cannot be handled.
|
516
|
|
- */
|
517
|
|
-#if 0xFFFFFFFFUL > FT_UINT_MAX
|
518
|
|
- if ( (type->flags & (FT_ULong)FT_UINT_MAX) )
|
519
|
|
- FT_TRACE1(( "FTC_ImageCache_Lookup:"
|
520
|
|
- " higher bits in load_flags 0x%lx are dropped\n",
|
521
|
|
- (FT_ULong)type->flags & ~((FT_ULong)FT_UINT_MAX) ));
|
522
|
|
-#endif
|
523
|
|
-
|
524
|
495
|
query.attrs.scaler.face_id = type->face_id;
|
525
|
496
|
query.attrs.scaler.width = type->width;
|
526
|
497
|
query.attrs.scaler.height = type->height;
|
527
|
|
- query.attrs.load_flags = (FT_UInt)type->flags;
|
|
498
|
+ query.attrs.load_flags = type->flags;
|
528
|
499
|
|
529
|
500
|
query.attrs.scaler.pixel = 1;
|
530
|
501
|
query.attrs.scaler.x_res = 0; /* make compilers happy */
|
... |
... |
@@ -592,20 +563,20 @@ |
592
|
563
|
*ansbit = NULL;
|
593
|
564
|
|
594
|
565
|
/*
|
595
|
|
- * Internal `FTC_BasicAttr->load_flags' is of type `FT_UInt',
|
|
566
|
+ * Internal `FTC_BasicAttr->load_flags' is of type `FT_Int32',
|
596
|
567
|
* but public `FT_Face->face_flags' is of type `FT_Long'.
|
597
|
568
|
*
|
598
|
569
|
* On long > int systems, higher bits of load_flags cannot be handled.
|
599
|
570
|
*/
|
600
|
|
-#if FT_ULONG_MAX > FT_UINT_MAX
|
601
|
|
- if ( load_flags > FT_UINT_MAX )
|
|
571
|
+#if FT_ULONG_MAX > 0xFFFFFFFFUL
|
|
572
|
+ if ( load_flags > 0xFFFFFFFFUL )
|
602
|
573
|
FT_TRACE1(( "FTC_ImageCache_LookupScaler:"
|
603
|
574
|
" higher bits in load_flags 0x%lx are dropped\n",
|
604
|
|
- load_flags & ~((FT_ULong)FT_UINT_MAX) ));
|
|
575
|
+ load_flags & ~0xFFFFFFFFUL ));
|
605
|
576
|
#endif
|
606
|
577
|
|
607
|
578
|
query.attrs.scaler = scaler[0];
|
608
|
|
- query.attrs.load_flags = (FT_UInt)load_flags;
|
|
579
|
+ query.attrs.load_flags = (FT_Int32)load_flags;
|
609
|
580
|
|
610
|
581
|
/* beware, the hash must be the same for all glyph ranges! */
|
611
|
582
|
hash = FTC_BASIC_ATTR_HASH( &query.attrs ) +
|