[config] Disable AAT map

Part of https://github.com/harfbuzz/harfbuzz/issues/1652
This commit is contained in:
Behdad Esfahbod 2019-06-19 17:08:26 -07:00
parent d8bf6723a1
commit f4de0c7754
2 changed files with 13 additions and 8 deletions

View File

@ -26,6 +26,10 @@
* Google Author(s): Behdad Esfahbod
*/
#include "hb.hh"
#ifndef HB_NO_SHAPE_AAT
#include "hb-aat-map.hh"
#include "hb-aat-layout.hh"
@ -34,10 +38,6 @@
void hb_aat_map_builder_t::add_feature (hb_tag_t tag,
unsigned int value)
{
#ifdef HB_NO_SHAPE_AAT
return;
#endif
if (tag == HB_TAG ('a','a','l','t'))
{
feature_info_t *info = features.push();
@ -57,10 +57,6 @@ void hb_aat_map_builder_t::add_feature (hb_tag_t tag,
void
hb_aat_map_builder_t::compile (hb_aat_map_t &m)
{
#ifdef HB_NO_SHAPE_AAT
return;
#endif
/* Sort features and merge duplicates */
if (features.length)
{
@ -74,3 +70,6 @@ hb_aat_map_builder_t::compile (hb_aat_map_t &m)
hb_aat_layout_compile_map (this, &m);
}
#endif

View File

@ -98,8 +98,10 @@ hb_ot_shape_planner_t::compile (hb_ot_shape_plan_t &plan,
plan.props = props;
plan.shaper = shaper;
map.compile (plan.map, key);
#ifndef HB_NO_SHAPE_AAT
if (apply_morx)
aat_map.compile (plan.aat_map);
#endif
#ifndef HB_NO_OT_SHAPE_FRACTIONS
plan.frac_mask = plan.map.get_1_mask (HB_TAG ('f','r','a','c'));
@ -201,7 +203,9 @@ hb_ot_shape_plan_t::init0 (hb_face_t *face,
const hb_shape_plan_key_t *key)
{
map.init ();
#ifndef HB_NO_SHAPE_AAT
aat_map.init ();
#endif
hb_ot_shape_planner_t planner (face,
&key->props);
@ -229,7 +233,9 @@ hb_ot_shape_plan_t::fini ()
shaper->data_destroy (const_cast<void *> (data));
map.fini ();
#ifndef HB_NO_SHAPE_AAT
aat_map.fini ();
#endif
}
void