Commit Graph

13 Commits

Author SHA1 Message Date
Behdad Esfahbod e6c09cdf43 Remove the pre_allocate argument from hb_buffer_create()
For two reasons:

1. User can always call hb_buffer_pre_allocate() themselves, and

2. Now we do a pre_alloc in add_utfX anyway, so the total number of
reallocs is limited to a small number (~3) anyway.  This just makes the
API cleaner.
2011-08-19 19:20:26 +02:00
Behdad Esfahbod 38b2118724 [API] Add hb_ft_font_set_funcs(), remove hb_ft_get_font_funcs()
Remove hb_ft_get_font_funcs() as it cannot be used by the user anyway.

Add hb_ft_font_set_funcs().  Which will make the font internally use
FreeType.  That is, no need for the font to have created using the
hb-ft API.  Just create using hb_face_create()/hb_font_create() and
then call this on the font (after having set font scale).  This
internally creates an FT_Face and attached to the font.
2011-08-09 11:10:32 +02:00
Behdad Esfahbod 33ccc77902 [API] Make set_user_data() functions take a replace parameter
We need this to set data on objects safely without worrying that some
other thread unsets it by setting it at the same time.
2011-08-09 00:43:24 +02:00
Behdad Esfahbod 31f18abecb Minor compiler warning fixes 2011-06-15 09:49:58 -04:00
Behdad Esfahbod 7fc5a30cb4 [API] Add hb_face_make/is_immutable() 2011-05-12 17:48:20 -04:00
Behdad Esfahbod 9a14688e40 [API] Rename hb_face_create_for_data() to hb_face_create() 2011-05-11 22:49:29 -04:00
Behdad Esfahbod 80a6833b03 [API] Add hb_*_get_empty() for all objects 2011-05-11 18:21:58 -04:00
Behdad Esfahbod 74f1d896f2 Add hb_font_make/is_immutable() 2011-05-10 19:39:32 -04:00
Behdad Esfahbod 6a9093cc48 [test/object] Test user_data with destroy() callback that calls user_data
Exposes the non-atomicity of user_data opertaions at this time because
we call finish() while still locked and modifying the object.  In fact,
I'm surprised that it doesn't deadlock.  It should.
2011-05-10 19:00:07 -04:00
Behdad Esfahbod 1c9f8717eb [API] Simplify blob API, remove lock 2011-05-06 22:59:42 -04:00
Behdad Esfahbod 811482bd65 Replace hb_map_t with hb_set_t which is more intuitive and flexible 2011-05-05 13:21:04 -04:00
Behdad Esfahbod 72657e4ce7 [API] Make hb_font_create() take a face and reference it 2011-05-02 20:47:23 -04:00
Behdad Esfahbod db99589529 [test/object] Add test for object lifecycle stuff
Revealed many bugs in the (untested and known buggy) user_data
support.
2011-05-02 19:52:47 -04:00