diff options
author | Matthias Clasen <mclasen@redhat.com> | 2021-11-16 19:31:20 -0500 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2021-11-16 19:32:46 -0500 |
commit | b3dd3103eff027344413af1b8572d906c79a6868 (patch) | |
tree | 1518bc336718b64e730770795413ab6bb61072e8 /pango | |
parent | ac8f01fe00b57c511c1caf8dcef01bff249ea8f9 (diff) | |
download | pango-b3dd3103eff027344413af1b8572d906c79a6868.tar.gz |
build: Bump the harfbuzz req
We are using the hb metrics api in more places
now, so just require 2.6.0 where it was introduced.
That version is almost 2 years old now, so that
is hopefully not too much of a burden.
Diffstat (limited to 'pango')
-rw-r--r-- | pango/pangofc-font.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/pango/pangofc-font.c b/pango/pangofc-font.c index bcb14d7d..74503b91 100644 --- a/pango/pangofc-font.c +++ b/pango/pangofc-font.c @@ -331,10 +331,11 @@ pango_fc_font_get_coverage (PangoFont *font, */ static void get_face_metrics (PangoFcFont *fcfont, - PangoFontMetrics *metrics) + PangoFontMetrics *metrics) { hb_font_t *hb_font = pango_font_get_hb_font (PANGO_FONT (fcfont)); hb_font_extents_t extents; + hb_position_t position; FcMatrix *fc_matrix; gboolean have_transform = FALSE; @@ -342,10 +343,10 @@ get_face_metrics (PangoFcFont *fcfont, hb_font_get_extents_for_direction (hb_font, HB_DIRECTION_LTR, &extents); if (FcPatternGetMatrix (fcfont->font_pattern, - FC_MATRIX, 0, &fc_matrix) == FcResultMatch) + FC_MATRIX, 0, &fc_matrix) == FcResultMatch) { have_transform = (fc_matrix->xx != 1 || fc_matrix->xy != 0 || - fc_matrix->yx != 0 || fc_matrix->yy != 1); + fc_matrix->yx != 0 || fc_matrix->yy != 1); } if (have_transform) @@ -366,10 +367,6 @@ get_face_metrics (PangoFcFont *fcfont, metrics->strikethrough_thickness = PANGO_SCALE; metrics->strikethrough_position = metrics->ascent / 2; - /* FIXME: use the right hb version */ -#if HB_VERSION_ATLEAST(2,5,4) - hb_position_t position; - if (hb_ot_metrics_get_position (hb_font, HB_OT_METRICS_TAG_UNDERLINE_SIZE, &position)) metrics->underline_thickness = position; @@ -381,7 +378,6 @@ get_face_metrics (PangoFcFont *fcfont, if (hb_ot_metrics_get_position (hb_font, HB_OT_METRICS_TAG_STRIKEOUT_OFFSET, &position)) metrics->strikethrough_position = position; -#endif } PangoFontMetrics * |