diff options
Diffstat (limited to 'src/3rdparty/harfbuzz-ng/src/hb-paint.h')
-rw-r--r-- | src/3rdparty/harfbuzz-ng/src/hb-paint.h | 44 |
1 files changed, 43 insertions, 1 deletions
diff --git a/src/3rdparty/harfbuzz-ng/src/hb-paint.h b/src/3rdparty/harfbuzz-ng/src/hb-paint.h index a734f112cc..b0cd384e28 100644 --- a/src/3rdparty/harfbuzz-ng/src/hb-paint.h +++ b/src/3rdparty/harfbuzz-ng/src/hb-paint.h @@ -137,6 +137,26 @@ typedef void (*hb_paint_pop_transform_func_t) (hb_paint_funcs_t *funcs, void *user_data); /** + * hb_paint_color_glyph_func_t: + * @funcs: paint functions object + * @paint_data: The data accompanying the paint functions in hb_font_paint_glyph() + * @glyph: the glyph ID + * @font: the font + * @user_data: User data pointer passed to hb_paint_funcs_set_color_glyph_func() + * + * A virtual method for the #hb_paint_funcs_t to render a color glyph by glyph index. + * + * Return value: %true if the glyph was painted, %false otherwise. + * + * Since: 8.2.0 + */ +typedef hb_bool_t (*hb_paint_color_glyph_func_t) (hb_paint_funcs_t *funcs, + void *paint_data, + hb_codepoint_t glyph, + hb_font_t *font, + void *user_data); + +/** * hb_paint_push_clip_glyph_func_t: * @funcs: paint functions object * @paint_data: The data accompanying the paint functions in hb_font_paint_glyph() @@ -616,7 +636,7 @@ typedef enum { HB_PAINT_COMPOSITE_MODE_HSL_HUE, HB_PAINT_COMPOSITE_MODE_HSL_SATURATION, HB_PAINT_COMPOSITE_MODE_HSL_COLOR, - HB_PAINT_COMPOSITE_MODE_HSL_LUMINOSITY, + HB_PAINT_COMPOSITE_MODE_HSL_LUMINOSITY } hb_paint_composite_mode_t; /** @@ -724,6 +744,23 @@ hb_paint_funcs_set_pop_transform_func (hb_paint_funcs_t *funcs, hb_destroy_func_t destroy); /** + * hb_paint_funcs_set_color_glyph_func: + * @funcs: A paint functions struct + * @func: (closure user_data) (destroy destroy) (scope notified): The color-glyph callback + * @user_data: Data to pass to @func + * @destroy: (nullable): Function to call when @user_data is no longer needed + * + * Sets the color-glyph callback on the paint functions struct. + * + * Since: 8.2.0 + */ +HB_EXTERN void +hb_paint_funcs_set_color_glyph_func (hb_paint_funcs_t *funcs, + hb_paint_color_glyph_func_t func, + void *user_data, + hb_destroy_func_t destroy); + +/** * hb_paint_funcs_set_push_clip_glyph_func: * @funcs: A paint functions struct * @func: (closure user_data) (destroy destroy) (scope notified): The push-clip-glyph callback @@ -922,6 +959,11 @@ hb_paint_push_transform (hb_paint_funcs_t *funcs, void *paint_data, HB_EXTERN void hb_paint_pop_transform (hb_paint_funcs_t *funcs, void *paint_data); +HB_EXTERN hb_bool_t +hb_paint_color_glyph (hb_paint_funcs_t *funcs, void *paint_data, + hb_codepoint_t glyph, + hb_font_t *font); + HB_EXTERN void hb_paint_push_clip_glyph (hb_paint_funcs_t *funcs, void *paint_data, hb_codepoint_t glyph, |