From e3e1ae876646937302593d37ea68e1e650621fcb Mon Sep 17 00:00:00 2001 From: Garret Rieger Date: Fri, 13 Aug 2021 10:53:20 -0700 Subject: [PATCH] [subset] proposed update to subset set apis. --- src/hb-subset.h | 37 ++++++++++++++++++++++++------------- 1 file changed, 24 insertions(+), 13 deletions(-) diff --git a/src/hb-subset.h b/src/hb-subset.h index 4f17bc5b8..bc6540d9b 100644 --- a/src/hb-subset.h +++ b/src/hb-subset.h @@ -79,6 +79,29 @@ typedef enum { /*< flags >*/ HB_SUBSET_FLAGS_NO_PRUNE_UNICODE_RANGES = 0x00000100u, } hb_subset_flags_t; +/** + * hb_subset_sets_t: + * @HB_SUBSET_SETS_LAYOUT_FEATURE_TAG: the set of layout feature tags that will be retained + * in the subset. + * @HB_SUBSET_SETS_NAME_INDEX: the set of name ids that will be retained. + * @HB_SUBSET_SETS_NAME_LANG_INDEX: the set of name lang ids that will be retained. + * @HB_SUBSET_SETS_NO_SUBSET_TABLE_TAG: the set of table tags which specifies tables that should not be + * subsetted. + * @HB_SUBSET_SETS_DROP_TABLE_TAG: the set of table tags which specifies tables which will be dropped + * in the subset. + * + * List of sets that can be configured on the subset input. + * + * Since: REPLACE + **/ +typedef enum { /*< flags >*/ + HB_SUBSET_SETS_LAYOUT_FEATURE_TAG = 0, + HB_SUBSET_SETS_NAME_INDEX, + HB_SUBSET_SETS_NAME_LANG_INDEX, + HB_SUBSET_SETS_NO_SUBSET_TABLE_TAG, + HB_SUBSET_SETS_DROP_TABLE_TAG, +} hb_subset_sets_t; + HB_EXTERN hb_subset_input_t * hb_subset_input_create_or_fail (void); @@ -106,19 +129,7 @@ HB_EXTERN hb_set_t * hb_subset_input_glyph_set (hb_subset_input_t *input); HB_EXTERN hb_set_t * -hb_subset_input_nameid_set (hb_subset_input_t *input); - -HB_EXTERN hb_set_t * -hb_subset_input_namelangid_set (hb_subset_input_t *input); - -HB_EXTERN hb_set_t * -hb_subset_input_layout_features_set (hb_subset_input_t *input); - -HB_EXTERN hb_set_t * -hb_subset_input_no_subset_tables_set (hb_subset_input_t *input); - -HB_EXTERN hb_set_t * -hb_subset_input_drop_tables_set (hb_subset_input_t *input); +hb_subset_input_set (hb_subset_input_t *input, hb_subset_sets_t set_type); HB_EXTERN hb_subset_flags_t hb_subset_input_get_flags (hb_subset_input_t *input);