X-Git-Url: https://git.saurik.com/apple/icu.git/blobdiff_plain/b75a7d8f3b4adbae880cab104ce2c6a50eee4db2..ef6cf650f4a75c3f97de06b51fa104f2069b9ea2:/icuSources/layout/ClassDefinitionTables.h?ds=sidebyside diff --git a/icuSources/layout/ClassDefinitionTables.h b/icuSources/layout/ClassDefinitionTables.h index 96bb76a5..3f881acd 100644 --- a/icuSources/layout/ClassDefinitionTables.h +++ b/icuSources/layout/ClassDefinitionTables.h @@ -1,7 +1,6 @@ /* - * @(#)ClassDefinitionTables.h 1.5 00/03/15 * - * (C) Copyright IBM Corp. 1998-2003 - All Rights Reserved + * (C) Copyright IBM Corp. 1998-2013 - All Rights Reserved * */ @@ -22,8 +21,20 @@ struct ClassDefinitionTable { le_uint16 classFormat; - le_int32 getGlyphClass(LEGlyphID glyphID) const; - le_bool hasGlyphClass(le_int32 glyphClass) const; + le_int32 getGlyphClass(const LETableReference &base, LEGlyphID glyphID, LEErrorCode &success) const; + le_bool hasGlyphClass(const LETableReference &base, le_int32 glyphClass, LEErrorCode &success) const; + + le_int32 getGlyphClass(LEGlyphID glyphID) const { + LETableReference base((const le_uint8*)this); + LEErrorCode ignored = LE_NO_ERROR; + return getGlyphClass(base,glyphID,ignored); + } + + le_bool hasGlyphClass(le_int32 glyphClass) const { + LETableReference base((const le_uint8*)this); + LEErrorCode ignored = LE_NO_ERROR; + return hasGlyphClass(base,glyphClass,ignored); + } }; struct ClassDefFormat1Table : ClassDefinitionTable @@ -32,9 +43,11 @@ struct ClassDefFormat1Table : ClassDefinitionTable le_uint16 glyphCount; le_uint16 classValueArray[ANY_NUMBER]; - le_int32 getGlyphClass(LEGlyphID glyphID) const; - le_bool hasGlyphClass(le_int32 glyphClass) const; + le_int32 getGlyphClass(const LETableReference &base, LEGlyphID glyphID, LEErrorCode &success) const; + le_bool hasGlyphClass(const LETableReference &base, le_int32 glyphClass, LEErrorCode &success) const; }; +LE_VAR_ARRAY(ClassDefFormat1Table, classValueArray) + struct ClassRangeRecord { @@ -48,9 +61,10 @@ struct ClassDefFormat2Table : ClassDefinitionTable le_uint16 classRangeCount; GlyphRangeRecord classRangeRecordArray[ANY_NUMBER]; - le_int32 getGlyphClass(LEGlyphID glyphID) const; - le_bool hasGlyphClass(le_int32 glyphClass) const; + le_int32 getGlyphClass(const LETableReference &base, LEGlyphID glyphID, LEErrorCode &success) const; + le_bool hasGlyphClass(const LETableReference &base, le_int32 glyphClass, LEErrorCode &success) const; }; +LE_VAR_ARRAY(ClassDefFormat2Table, classRangeRecordArray) U_NAMESPACE_END #endif