[aat] Reduce unsafe_to_concat calls

pull/4023/head
Behdad Esfahbod 2 years ago
parent 8b17c6ca30
commit dd42939e31
  1. 2
      src/hb-aat-layout-common.hh
  2. 2
      src/hb-aat-layout-kerx-table.hh
  3. 3
      src/hb-aat-layout-morx-table.hh

@ -783,8 +783,6 @@ struct StateTableDriver
if (!c->in_place)
buffer->clear_output ();
buffer->unsafe_to_concat ();
int state = StateTableT::STATE_START_OF_TEXT;
// If there's only one range, we already checked the flag.
auto *last_range = ac->range_flags && (ac->range_flags->length > 1) ? &(*ac->range_flags)[0] : nullptr;

@ -869,6 +869,8 @@ struct KerxTable
bool apply (AAT::hb_aat_apply_context_t *c) const
{
c->buffer->unsafe_to_concat ();
typedef typename T::SubTable SubTable;
bool ret = false;

@ -1154,6 +1154,9 @@ struct mortmorx
const hb_aat_map_t &map) const
{
if (unlikely (!c->buffer->successful)) return;
c->buffer->unsafe_to_concat ();
c->set_lookup_index (0);
const Chain<Types> *chain = &firstChain;
unsigned int count = chainCount;

Loading…
Cancel
Save