[kerx] Remove set-digests since accelerator is not shared

pull/4711/head
Behdad Esfahbod 10 months ago
parent ebbec7713b
commit 5f32c60d05
  1. 18
      src/hb-aat-layout-kerx-table.hh

@ -123,29 +123,13 @@ struct KerxSubTableFormat0
{
const KerxSubTableFormat0 &table;
hb_aat_apply_context_t *c;
hb_set_digest_t left_set, right_set;
template <typename set_t>
void collect_glyphs (set_t &left, set_t &right)
{
for (const KernPair& pair : table.pairs)
{
left_set.add (pair.left);
right_set.add (pair.right);
}
}
accelerator_t (const KerxSubTableFormat0 &table_,
hb_aat_apply_context_t *c_) :
table (table_), c (c_)
{
collect_glyphs (left_set, right_set);
}
table (table_), c (c_) {}
int get_kerning (hb_codepoint_t left, hb_codepoint_t right) const
{
if (!left_set[left] || !right_set[right])
return 0;
return table.get_kerning (left, right, c);
}
};

Loading…
Cancel
Save