diff --git a/src/hb-open-type.hh b/src/hb-open-type.hh index f0999b633..5199d1c48 100644 --- a/src/hb-open-type.hh +++ b/src/hb-open-type.hh @@ -122,6 +122,15 @@ typedef IntType HBINT32; /* 32-bit signed integer. */ * Works for unsigned, but not signed, since we rely on compiler for sign-extension. */ typedef IntType HBUINT24; /* 24-bit unsigned integer. */ +/* 15-bit unsigned number; top bit used for extension. */ +struct HBUINT15 : HBUINT16 +{ + /* TODO Flesh out; actually mask top bit. */ + HBUINT15& operator = (uint16_t i ) { HBUINT16::operator= (i); return *this; } + public: + DEFINE_SIZE_STATIC (2); +}; + /* 16-bit signed integer (HBINT16) that describes a quantity in FUnits. */ typedef HBINT16 FWORD; diff --git a/src/hb-ot-layout-common.hh b/src/hb-ot-layout-common.hh index 71e43f041..1a00c53cc 100644 --- a/src/hb-ot-layout-common.hh +++ b/src/hb-ot-layout-common.hh @@ -2543,7 +2543,7 @@ struct VarRegionList public: HBUINT16 axisCount; - HBUINT16 regionCount; + HBUINT15 regionCount; protected: UnsizedArrayOf axesZ;