1
1
mirror of https://gitlab.gnome.org/GNOME/gimp.git synced 2025-10-06 01:12:40 +02:00

app: use more recent harfbuzz API.

hb_ft_font_lock_face() (and unlock) exists since harfbuzz 2.6.5 and our
current requirement for this dependency is 2.8.2.

Fixes this compilation warning:

> app/text/gimpfont.c:1196:3: warning: ‘hb_ft_font_get_face’ is deprecated: Use 'hb_ft_font_get_ft_face' instead [-Wdeprecated-declarations]
>  1196 |   face = hb_ft_font_get_face (hb_font);
This commit is contained in:
Jehan
2025-09-22 00:43:11 +02:00
parent 56f72c24ba
commit dbf0c39bb3

View File

@@ -1190,10 +1190,7 @@ gimp_font_get_sample_string (PangoContext *context,
*/
hb_font = hb_font_create_sub_font (hb_font);
hb_ft_font_set_funcs (hb_font);
/* TODO: use hb_ft_font_lock_face/hb_ft_font_unlock_face() when we
* bump to harfbuzz >= 2.6.5.
*/
face = hb_ft_font_get_face (hb_font);
face = hb_ft_font_lock_face (hb_font);
/* Are there actual cases where this function could return NULL while
* it's not a bug in the code?
@@ -1281,6 +1278,7 @@ gimp_font_get_sample_string (PangoContext *context,
}
}
hb_ft_font_unlock_face (hb_font);
hb_font_destroy (hb_font);
g_object_unref (font);