Rename add_class to collect_class
This commit is contained in:
parent
5cf53c06e6
commit
89ad3c6cc5
|
@ -1719,7 +1719,7 @@ struct ClassDefFormat1
|
|||
}
|
||||
|
||||
template <typename set_t>
|
||||
bool add_class (set_t *glyphs, unsigned int klass) const
|
||||
bool collect_class (set_t *glyphs, unsigned int klass) const
|
||||
{
|
||||
unsigned int count = classValue.len;
|
||||
for (unsigned int i = 0; i < count; i++)
|
||||
|
@ -1879,7 +1879,7 @@ struct ClassDefFormat2
|
|||
}
|
||||
|
||||
template <typename set_t>
|
||||
bool add_class (set_t *glyphs, unsigned int klass) const
|
||||
bool collect_class (set_t *glyphs, unsigned int klass) const
|
||||
{
|
||||
unsigned int count = rangeRecord.len;
|
||||
for (unsigned int i = 0; i < count; i++)
|
||||
|
@ -2036,11 +2036,11 @@ struct ClassDef
|
|||
/* Might return false if array looks unsorted.
|
||||
* Used for faster rejection of corrupt data. */
|
||||
template <typename set_t>
|
||||
bool add_class (set_t *glyphs, unsigned int klass) const
|
||||
bool collect_class (set_t *glyphs, unsigned int klass) const
|
||||
{
|
||||
switch (u.format) {
|
||||
case 1: return u.format1.add_class (glyphs, klass);
|
||||
case 2: return u.format2.add_class (glyphs, klass);
|
||||
case 1: return u.format1.collect_class (glyphs, klass);
|
||||
case 2: return u.format2.collect_class (glyphs, klass);
|
||||
default:return false;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -464,7 +464,7 @@ struct GDEF
|
|||
unsigned int get_glyph_class (hb_codepoint_t glyph) const
|
||||
{ return (this+glyphClassDef).get_class (glyph); }
|
||||
void get_glyphs_in_class (unsigned int klass, hb_set_t *glyphs) const
|
||||
{ (this+glyphClassDef).add_class (glyphs, klass); }
|
||||
{ (this+glyphClassDef).collect_class (glyphs, klass); }
|
||||
|
||||
bool has_mark_attachment_types () const { return markAttachClassDef != 0; }
|
||||
unsigned int get_mark_attachment_type (hb_codepoint_t glyph) const
|
||||
|
|
|
@ -810,7 +810,7 @@ static inline void collect_glyph (hb_set_t *glyphs, const HBUINT16 &value, const
|
|||
static inline void collect_class (hb_set_t *glyphs, const HBUINT16 &value, const void *data)
|
||||
{
|
||||
const ClassDef &class_def = *reinterpret_cast<const ClassDef *>(data);
|
||||
class_def.add_class (glyphs, value);
|
||||
class_def.collect_class (glyphs, value);
|
||||
}
|
||||
static inline void collect_coverage (hb_set_t *glyphs, const HBUINT16 &value, const void *data)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue