Minor refactoring
This commit is contained in:
parent
844f1a487d
commit
b98c5db32d
|
@ -349,11 +349,7 @@ struct hb_apply_context_t
|
|||
may_skip (const hb_apply_context_t *c,
|
||||
const hb_glyph_info_t &info) const
|
||||
{
|
||||
unsigned int property;
|
||||
|
||||
property = _hb_glyph_info_get_glyph_props (&info);
|
||||
|
||||
if (!c->match_properties (info.codepoint, property, lookup_props))
|
||||
if (!c->check_glyph_property (&info, lookup_props))
|
||||
return SKIP_YES;
|
||||
|
||||
if (unlikely (_hb_glyph_info_is_default_ignorable (&info) &&
|
||||
|
@ -537,10 +533,12 @@ struct hb_apply_context_t
|
|||
}
|
||||
|
||||
inline bool
|
||||
match_properties (hb_codepoint_t glyph,
|
||||
unsigned int glyph_props,
|
||||
check_glyph_property (const hb_glyph_info_t *info,
|
||||
unsigned int lookup_props) const
|
||||
{
|
||||
hb_codepoint_t glyph = info->codepoint;
|
||||
unsigned int glyph_props = _hb_glyph_info_get_glyph_props (info);
|
||||
|
||||
/* Not covered, if, for example, glyph class is ligature and
|
||||
* lookup_props includes LookupFlags::IgnoreLigatures
|
||||
*/
|
||||
|
@ -553,17 +551,6 @@ struct hb_apply_context_t
|
|||
return true;
|
||||
}
|
||||
|
||||
inline bool
|
||||
check_glyph_property (hb_glyph_info_t *info,
|
||||
unsigned int lookup_props) const
|
||||
{
|
||||
unsigned int property;
|
||||
|
||||
property = _hb_glyph_info_get_glyph_props (info);
|
||||
|
||||
return match_properties (info->codepoint, property, lookup_props);
|
||||
}
|
||||
|
||||
inline void _set_glyph_props (hb_codepoint_t glyph_index,
|
||||
unsigned int class_guess = 0,
|
||||
bool ligature = false,
|
||||
|
|
Loading…
Reference in New Issue