From ec99fdb7e83ebc70993385a9b852cc05bf4693bf Mon Sep 17 00:00:00 2001 From: Khaled Hosny Date: Mon, 26 Jul 2021 01:35:13 +0200 Subject: [PATCH] [sebset] Use [s|g]et_flag for retain_all_layout_features Looks like this was missed when adding hb_subset_input_[s|g]et_flag() --- docs/harfbuzz-sections.txt | 2 -- src/hb-subset-input.cc | 19 +++++-------------- src/hb-subset.h | 11 +++++------ 3 files changed, 10 insertions(+), 22 deletions(-) diff --git a/docs/harfbuzz-sections.txt b/docs/harfbuzz-sections.txt index 4c02eac57..a56b8b43b 100644 --- a/docs/harfbuzz-sections.txt +++ b/docs/harfbuzz-sections.txt @@ -721,8 +721,6 @@ hb_subset_input_glyph_set hb_subset_input_nameid_set hb_subset_input_namelangid_set hb_subset_input_layout_features_set -hb_subset_input_set_retain_all_features -hb_subset_input_get_retain_all_features hb_subset_input_no_subset_tables_set hb_subset_input_drop_tables_set hb_subset_input_get_flag diff --git a/src/hb-subset-input.cc b/src/hb-subset-input.cc index 619e61f0b..2b9e2a6f3 100644 --- a/src/hb-subset-input.cc +++ b/src/hb-subset-input.cc @@ -325,20 +325,6 @@ hb_subset_input_layout_features_set (hb_subset_input_t *input) return input->layout_features; } -HB_EXTERN void -hb_subset_input_set_retain_all_features (hb_subset_input_t *input, - hb_bool_t value) -{ - input->retain_all_layout_features = value; -} - -HB_EXTERN hb_bool_t -hb_subset_input_get_retain_all_features (hb_subset_input_t *input) -{ - return input->retain_all_layout_features; -} - - /** * hb_subset_input_drop_tables_set: * @input: a #hb_subset_input_t object. @@ -407,6 +393,8 @@ hb_subset_input_get_flag (hb_subset_input_t *input, return input->notdef_outline; case HB_SUBSET_FLAG_NO_PRUNE_UNICODE_RANGES: return input->no_prune_unicode_ranges; + case HB_SUBSET_FLAG_RETAIN_ALL_FEATURES: + return input->retain_all_layout_features; default: return false; } @@ -453,6 +441,9 @@ hb_subset_input_set_flag (hb_subset_input_t *input, case HB_SUBSET_FLAG_NO_PRUNE_UNICODE_RANGES: input->no_prune_unicode_ranges = value; break; + case HB_SUBSET_FLAG_RETAIN_ALL_FEATURES: + input->retain_all_layout_features = value; + break; default: // Do nothing. break; diff --git a/src/hb-subset.h b/src/hb-subset.h index 64148adee..9b7e35492 100644 --- a/src/hb-subset.h +++ b/src/hb-subset.h @@ -61,6 +61,10 @@ typedef struct hb_subset_input_t hb_subset_input_t; * retained in the final subset. Defaults to false. * @HB_SUBSET_FLAG_NO_PRUNE_UNICODE_RANGES: If set then the unicode ranges in * OS/2 will not be recalculated. + * @HB_SUBSET_FLAG_RETAIN_ALL_FEATURES: If set all layout features will be + * retained. If unset then the set accessed by + * hb_subset_input_layout_features_set() will be used to determine the features + * to be retained. * * List of boolean properties that can be configured on the subset input. * @@ -76,6 +80,7 @@ typedef enum HB_SUBSET_FLAG_PASSTHROUGH_UNRECOGNIZED, HB_SUBSET_FLAG_NOTDEF_OUTLINE, HB_SUBSET_FLAG_NO_PRUNE_UNICODE_RANGES, + HB_SUBSET_FLAG_RETAIN_ALL_FEATURES, } hb_subset_flag_t; HB_EXTERN hb_subset_input_t * @@ -113,12 +118,6 @@ 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 void -hb_subset_input_set_retain_all_features (hb_subset_input_t *input, - hb_bool_t value); -HB_EXTERN hb_bool_t -hb_subset_input_get_retain_all_features (hb_subset_input_t *input); - HB_EXTERN hb_set_t * hb_subset_input_no_subset_tables_set (hb_subset_input_t *input);