[CBDT] Use CHAR instead of int8_t

This commit is contained in:
Behdad Esfahbod 2016-12-02 15:21:43 -08:00
parent efca7bf97f
commit b92ba7bafc
2 changed files with 15 additions and 14 deletions

View File

@ -650,6 +650,7 @@ struct IntType
DEFINE_SIZE_STATIC (Size); DEFINE_SIZE_STATIC (Size);
}; };
typedef IntType<int8_t , 1> CHAR; /* 8-bit signed integer. */
typedef IntType<uint8_t , 1> BYTE; /* 8-bit unsigned integer. */ typedef IntType<uint8_t , 1> BYTE; /* 8-bit unsigned integer. */
typedef IntType<uint16_t, 2> USHORT; /* 16-bit unsigned integer. */ typedef IntType<uint16_t, 2> USHORT; /* 16-bit unsigned integer. */
typedef IntType<int16_t, 2> SHORT; /* 16-bit signed integer. */ typedef IntType<int16_t, 2> SHORT; /* 16-bit signed integer. */

View File

@ -35,26 +35,26 @@ struct SmallGlyphMetrics
{ {
BYTE height; BYTE height;
BYTE width; BYTE width;
int8_t bearingX; CHAR bearingX;
int8_t bearingY; CHAR bearingY;
BYTE advance; BYTE advance;
DEFINE_SIZE_STATIC(5); DEFINE_SIZE_STATIC(5);
}; };
struct SBitLineMetrics { struct SBitLineMetrics {
int8_t ascender; CHAR ascender;
int8_t decender; CHAR decender;
BYTE widthMax; BYTE widthMax;
int8_t caretSlopeNumerator; CHAR caretSlopeNumerator;
int8_t caretSlopeDenominator; CHAR caretSlopeDenominator;
int8_t caretOffset; CHAR caretOffset;
int8_t minOriginSB; CHAR minOriginSB;
int8_t minAdvanceSB; CHAR minAdvanceSB;
int8_t maxBeforeBL; CHAR maxBeforeBL;
int8_t minAfterBL; CHAR minAfterBL;
int8_t padding1; CHAR padding1;
int8_t padding2; CHAR padding2;
DEFINE_SIZE_STATIC(12); DEFINE_SIZE_STATIC(12);
}; };
@ -72,7 +72,7 @@ struct BitmapSizeTable
BYTE ppemX; BYTE ppemX;
BYTE ppemY; BYTE ppemY;
BYTE bitDepth; BYTE bitDepth;
int8_t flags; CHAR flags;
DEFINE_SIZE_STATIC(48); DEFINE_SIZE_STATIC(48);
}; };