[subset] rename _collect_subset_layout to _collect_layout_indices.
Better describes what the function does.
This commit is contained in:
parent
f2441a4b65
commit
59deb754b3
|
@ -87,12 +87,13 @@ _remap_indexes (const hb_set_t *indexes,
|
||||||
#ifndef HB_NO_SUBSET_LAYOUT
|
#ifndef HB_NO_SUBSET_LAYOUT
|
||||||
typedef void (*layout_collect_func_t) (hb_face_t *face, hb_tag_t table_tag, const hb_tag_t *scripts, const hb_tag_t *languages, const hb_tag_t *features, hb_set_t *lookup_indexes /* OUT */);
|
typedef void (*layout_collect_func_t) (hb_face_t *face, hb_tag_t table_tag, const hb_tag_t *scripts, const hb_tag_t *languages, const hb_tag_t *features, hb_set_t *lookup_indexes /* OUT */);
|
||||||
|
|
||||||
|
|
||||||
template <typename T>
|
template <typename T>
|
||||||
static void _collect_subset_layout (hb_face_t *face,
|
static void _collect_layout_indices (hb_face_t *face,
|
||||||
const T& table,
|
const T& table,
|
||||||
const hb_set_t *layout_features_to_retain,
|
const hb_set_t *layout_features_to_retain,
|
||||||
layout_collect_func_t layout_collect_func,
|
layout_collect_func_t layout_collect_func,
|
||||||
hb_set_t *lookup_indices /* OUT */)
|
hb_set_t *lookup_indices /* OUT */)
|
||||||
{
|
{
|
||||||
hb_vector_t<hb_tag_t> features;
|
hb_vector_t<hb_tag_t> features;
|
||||||
if (!features.alloc (table.get_feature_count () + 1))
|
if (!features.alloc (table.get_feature_count () + 1))
|
||||||
|
@ -143,11 +144,11 @@ _closure_glyphs_lookups_features (hb_face_t *face,
|
||||||
hb_blob_ptr_t<T> table = hb_sanitize_context_t ().reference_table<T> (face);
|
hb_blob_ptr_t<T> table = hb_sanitize_context_t ().reference_table<T> (face);
|
||||||
hb_tag_t table_tag = table->tableTag;
|
hb_tag_t table_tag = table->tableTag;
|
||||||
hb_set_t lookup_indices;
|
hb_set_t lookup_indices;
|
||||||
_collect_subset_layout<T> (face,
|
_collect_layout_indices<T> (face,
|
||||||
*table,
|
*table,
|
||||||
layout_features_to_retain,
|
layout_features_to_retain,
|
||||||
hb_ot_layout_collect_lookups,
|
hb_ot_layout_collect_lookups,
|
||||||
&lookup_indices);
|
&lookup_indices);
|
||||||
|
|
||||||
if (table_tag == HB_OT_TAG_GSUB)
|
if (table_tag == HB_OT_TAG_GSUB)
|
||||||
hb_ot_layout_lookups_substitute_closure (face,
|
hb_ot_layout_lookups_substitute_closure (face,
|
||||||
|
@ -160,11 +161,11 @@ _closure_glyphs_lookups_features (hb_face_t *face,
|
||||||
|
|
||||||
// Collect and prune features
|
// Collect and prune features
|
||||||
hb_set_t feature_indices;
|
hb_set_t feature_indices;
|
||||||
_collect_subset_layout<T> (face,
|
_collect_layout_indices<T> (face,
|
||||||
*table,
|
*table,
|
||||||
layout_features_to_retain,
|
layout_features_to_retain,
|
||||||
hb_ot_layout_collect_features,
|
hb_ot_layout_collect_features,
|
||||||
&feature_indices);
|
&feature_indices);
|
||||||
|
|
||||||
table->prune_features (lookups, &feature_indices);
|
table->prune_features (lookups, &feature_indices);
|
||||||
hb_map_t duplicate_feature_map;
|
hb_map_t duplicate_feature_map;
|
||||||
|
|
Loading…
Reference in New Issue