[HarfBuzz] font functions overrides and user_data

thomas bonfort thomas.bonfort at gmail.com
Mon Jul 8 06:27:26 PDT 2013


Hi,

This is my first post to this list, so please excuse me in advance if
this a stupid question (but please do point me to a url in that case
as I haven't found anything online yet).

* I'm looking at how to override a *single* font function callback
while leaving the others at their default. Is this possible at all?
(http://lists.freedesktop.org/archives/harfbuzz/2011-April/001158.html
is the closest I can get to)
* I would like to add my own structure to user_data when going in the
callbacks. I  'm not understanding how I should be using the
hb_font_funcs_set_user_data() function (namely the hb_user_data_key_t
part). I know I can recreate a hb_font_funcs_t to pass that user_data,
however I would like to reuse an existing  hb_font_funcs_t that I've
cached)
* which brings me to my last question: I can't seem to find a method
to get the hb_font_funcs_t from an existing hb_font_t . Is that at all
possible or should I be caching them?

The answer to the two last questions might just be to recreate a
hb_font_funcs_t from scratch each time I need to change the user_data.
I can live with that but was wondering if there was anything more
efficient.

Thanks and best regards,
Thomas



More information about the HarfBuzz mailing list