Commit Graph

339 Commits

Author SHA1 Message Date
Khaled Hosny 35c4a15a67 [docs] Update hb-font documentation 2020-12-24 22:34:26 +02:00
Khaled Hosny f88e845fc7 [docs] Minor fixes 2020-12-24 21:34:14 +02:00
Nathan Willis 82092d4005 [docs] Update gtk-doc comments in hb-font 2020-12-24 21:34:14 +02:00
Nathan Willis ec98730ff6 [docs] regularize whitespace in function params 2020-12-24 21:29:47 +02:00
Ebrahim Byagowi 2dda6dd744 minor, tweak spacing
turn 8 spaces to tab, add space before Null/Crap
2020-04-20 16:18:29 +04:30
Ebrahim Byagowi 9b7fb5c23f Move hb_font_get_var_coords_design behind HB_EXPERIMENTAL_API 2020-04-17 20:29:04 +04:30
Ebrahim Byagowi 352ac63ef9 Fix an unlikely UAF on the deprecated _set_glyph_func API
Fixes https://github.com/harfbuzz/harfbuzz/issues/2168
2020-02-11 03:05:04 +03:30
Ebrahim Byagowi 40166eb0e5 [var] Fix the just introduced hb_font_set_var_coords_design storing bug
The memcpy call was using the current coords count which is zero initially so no copy at all.

Sad that no test has caught it, should see why, will however with the upcoming style API tests.
2020-02-08 13:22:01 +03:30
Ebrahim Byagowi 0b76e8130e Don't use _normalize_variations to avoid twice axis fetch 2020-02-08 11:04:34 +03:30
Ebrahim Byagowi ab2d3ec542 [var] Implement hb_font_get_var_coords_design
Hold design coords and simulate when normalized coords are set directly.
2020-02-08 11:04:34 +03:30
Behdad Esfahbod ce11df1b5b 2.6.3 2019-10-28 14:46:59 -07:00
Behdad Esfahbod 5a59de2b98 Actually add +hb_font_get_nominal_glyphs()
New API:
+hb_font_get_nominal_glyphs()
2019-10-28 14:46:59 -07:00
Ebrahim Byagowi a0b4ac4dce Turn 8 spaces to tab across the project
According to the current code style of the project
2019-08-27 02:40:41 +04:30
Behdad Esfahbod aaa85931f3 [font] Update multipliers when creating sub_font
Fixes https://github.com/harfbuzz/harfbuzz/issues/1910
2019-08-20 13:06:10 -07:00
Behdad Esfahbod dcb4cd400f Minor 2019-08-19 11:35:37 -07:00
Ebrahim Byagowi bc27f86ffe
Move HB_NO_VAR to a better place in hb-font.cc
Needed for other works
2019-08-14 22:37:00 +04:30
Ebrahim Byagowi 6a194b6876
Minor, remove trailing spaces in hb-font.{cc,h} as .editorconfig 2019-08-14 18:49:57 +04:30
Behdad Esfahbod 6461143b44 2.6.0 2019-08-13 22:20:54 -07:00
Ebrahim Byagowi 40a4b6ddbd [var] Add a new API, hb_font_set_var_named_instance 2019-07-29 16:23:47 -07:00
Behdad Esfahbod b847769292 [font] Keep font-space to user-space multiplier
Part of https://github.com/harfbuzz/harfbuzz/issues/1801
2019-07-05 13:52:09 -07:00
Behdad Esfahbod df6edcd44c Make face immutable in hb_font_set_face() 2019-07-05 13:45:15 -07:00
Behdad Esfahbod a849873124 [config] Add HB_NO_VAR to disable variations support, enabled by HB_TINY
Part of https://github.com/harfbuzz/harfbuzz/issues/1652
2019-06-19 19:26:22 -07:00
Behdad Esfahbod 0819f3ca86 Deprecate v_kerning callback again
Part of https://github.com/harfbuzz/harfbuzz/issues/1682
2019-06-17 14:02:47 -07:00
Behdad Esfahbod 2682efb02d Revert "Deprecate font kern API"
This reverts commit d219f899f4.

API change: Un-deprecate font kern API.

Part of https://github.com/harfbuzz/harfbuzz/issues/1682

We should document that this API is only necessary to hook up
non-OpenType kerning.  hb-ot-font will continue to NOT implement them.
2019-06-17 13:38:49 -07:00
Behdad Esfahbod fca2786041 [config] Make HB_DISABLE_DEPRECATED actually compile
Part of https://github.com/harfbuzz/harfbuzz/issues/1652
2019-05-11 00:37:01 -07:00
Behdad Esfahbod 227d85e138 Minor 2019-05-10 23:16:14 -07:00
Behdad Esfahbod 4d31662b5d Don't install ot-font funcs on new fonts if HB_NO_OT_FONT defined
Currently linker cannot GC hb-ot-font completely because we install
it on fonts by default.  Don't do that if HB_NO_OT_FONT defined.

Part of https://github.com/harfbuzz/harfbuzz/issues/1652
2019-04-10 15:40:55 -04:00
Behdad Esfahbod 447323b85a Better fix for -Wcast-align errors 2019-01-22 12:50:12 +01:00
Behdad Esfahbod 81ec543d80 More -Wcast-error fixes 2019-01-22 12:43:12 +01:00
Behdad Esfahbod 8d05bf7dc0 Fix cast-align error
If compiler doesn't inline StructAtOffset, this was an error since we
only disable cast-align at call-site.  So, move the cast out.

../src/hb-machinery.hh: In instantiation of 'const Type& StructAtOffset(const void*, unsigned int) [with Type = unsigned int]':
../src/hb-font.cc:146:85:   required from here
../src/hb-machinery.hh:63:12: error: cast from 'const char*' to 'const unsigned int*' increases required alignment of target type [-Werror=cast-align]
 { return * reinterpret_cast<const Type*> ((const char *) P + offset); }
            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../src/hb-machinery.hh: In instantiation of 'Type& StructAtOffset(void*, unsigned int) [with Type = unsigned int]':
../src/hb-font.cc:147:79:   required from here
../src/hb-machinery.hh:66:12: error: cast from 'char*' to 'unsigned int*' increases required alignment of target type [-Werror=cast-align]
 { return * reinterpret_cast<Type*> ((char *) P + offset); }
            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2019-01-22 12:34:05 +01:00
Behdad Esfahbod b900f78088 [pragma] More cast-align whitelist 2019-01-18 10:08:23 -05:00
Behdad Esfahbod 0d8b931bbe [pragma] Allow cast-align in hb-font.cc
../src/hb-machinery.hh: In instantiation of 'const Type& StructAtOffset(const void*, unsigned int) [with Type = unsigned int]':
../src/hb-font.cc:144:85:   required from here
../src/hb-machinery.hh:63:12: error: cast from 'const char*' to 'const unsigned int*' increases required alignment of target type [-Werror=cast-align]
 { return * reinterpret_cast<const Type*> ((const char *) P + offset); }
            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../src/hb-machinery.hh: In instantiation of 'Type& StructAtOffset(void*, unsigned int) [with Type = unsigned int]':
../src/hb-font.cc:145:79:   required from here
../src/hb-machinery.hh:66:12: error: cast from 'char*' to 'unsigned int*' increases required alignment of target type [-Werror=cast-align]
 { return * reinterpret_cast<Type*> ((char *) P + offset); }
            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../src/hb-machinery.hh: In instantiation of 'Type& StructAtOffset(void*, unsigned int) [with Type = int]':
2019-01-18 10:03:43 -05:00
Ebrahim Byagowi e412008599 Remove redundant void from C++ sources (#1486) 2018-12-17 13:01:01 -05:00
Behdad Esfahbod ce5da0f36a [shaper] Rewrite shaper data code to be more template-driven than macro-driven 2018-11-16 02:52:20 -05:00
Behdad Esfahbod 925b7a214f Comment 2018-11-11 00:17:30 -05:00
Behdad Esfahbod 93ef20a83b Replace most uses of is_inert with is_immutable 2018-11-03 15:03:06 -04:00
Behdad Esfahbod 5570c87f21 Port objects to use header.writable instead of immutable
Saves 4 or 8 bytes per object on 64bit archs.
2018-11-03 14:59:40 -04:00
Behdad Esfahbod b9db610add Minor 2018-10-31 14:22:31 -07:00
Behdad Esfahbod cf5fa57f00 [docs] Change section titles again
I think I like the uniform "hb-*" more.
2018-10-27 04:51:42 -07:00
Behdad Esfahbod 5dd86aa33b [docs] Rename section titles to object names
More useful.
2018-10-27 04:47:41 -07:00
Behdad Esfahbod 00cf4e5eb6 [docs] Fill in some sections 2018-10-27 04:47:41 -07:00
Behdad Esfahbod 39bd07aed5 Fix bunch of unused parameter warnings
Show up with gcc -O0.

There's a few more but those are functions that need to be filled in.

Maybe this is a lost battle...
2018-10-26 21:22:26 -07:00
Behdad Esfahbod 08b7172969 [font] Fix parallel funcs passing to eachover in infinite-loop
Fixes test just added.
2018-10-19 19:12:33 -07:00
Behdad Esfahbod 3d9a0306eb 2.0.0 2018-10-18 05:58:17 -07:00
Behdad Esfahbod 68c86af187 Always compile deprecated symbols
We haven't been keeping this updated.  So, while we don't expose the
symbols in the headers if HB_DISABLE_DEPRECATED is defined, we still
always build them.
2018-10-12 16:06:39 -04:00
Behdad Esfahbod 07899435b8 Install ot-funcs on newly created funcs
**Finally**!  Casual users can stop caring about font-funcs completely now,
like they haven't been needing to care re unicode-funcs for a few years.
2018-10-09 15:39:51 -04:00
Behdad Esfahbod b314c4e9ab [font] Add get_nominal_glyphs() callback (note the plural)
Unused as of now.  To be wired up to normalizer, which would remove
overhead and allow hb-ot-font initialization to become a no-op, so
we can enable it by default.
2018-10-09 09:43:44 -04:00
Behdad Esfahbod ca6a317012 Minor 2018-10-09 09:43:44 -04:00
Behdad Esfahbod bee93e2697 Add const to get_*_advances API
Ouch!
2018-10-09 08:02:25 -04:00
Behdad Esfahbod d219f899f4 Deprecate font kern API 2018-10-09 00:01:09 -04:00
HinTak f9ea3dc4c6 Missing "out" indicator (#1209)
Missing "out" indicator. Affect gobject introspection.
2018-10-02 09:13:06 +03:30
Behdad Esfahbod 8a31e40629 [font] Make *_advance() fallback to *_advances
And remove redundant implementations.
2018-09-30 06:08:11 -04:00
Behdad Esfahbod 90a0f9fa0c Make TSan happy with make_immutable() 2018-09-26 15:03:07 -04:00
Behdad Esfahbod 55bae6825e [docs] A few improvements
If we wrote just this much every day...
2018-09-24 10:43:06 -04:00
Behdad Esfahbod c77ae40852 Rename hb-*private.hh to hb-*.hh
Sorry for the noise, downstream custom builders.  Please adjust.
2018-08-25 22:36:36 -07:00
Behdad Esfahbod 1f7380944d [atomic] Add hb_atomic_ptr_t<> and port all uses
Found and fixed a couple bugs.

Found a couple multithreading issues.  Marked them with "XXX-MT-bug".
2018-08-09 00:27:01 -07:00
Behdad Esfahbod e49a38b20e 1.8.6 2018-08-07 09:55:42 -07:00
Behdad Esfahbod b0ff79acd8 Add +hb_font_get_glyph_advances_for_direction
New API:
+hb_font_get_glyph_advances_for_direction
2018-08-07 09:52:06 -07:00
Behdad Esfahbod 28e2f467e1 Actually add hb_font_get_glyph_[hv]_advances
New API:
+hb_font_get_glyph_h_advances
+hb_font_get_glyph_v_advances
2018-08-07 09:47:00 -07:00
Behdad Esfahbod 3d7c555a19 Remove get_advances_nil and alias it to get_advances_default 2018-08-07 09:37:52 -07:00
Behdad Esfahbod 79e21984b1 Add batch advance width callback function
New API:
+hb_font_funcs_set_glyph_h_advances_func
+hb_font_funcs_set_glyph_v_advances_func
+hb_font_get_glyph_h_advances
+hb_font_get_glyph_h_advances_func_t
+hb_font_get_glyph_v_advances
+hb_font_get_glyph_v_advances_func_t
2018-08-06 09:45:17 -07:00
Koji Ishii 9533364cc3 batchwidth 2018-08-06 09:44:46 -07:00
Behdad Esfahbod 3506672ce9 Port _nil objects to Null() machinery
Finally, unified!
2018-08-06 06:17:48 -07:00
Ebrahim Byagowi 24b8b9b227 Resolve clang's used-but-marked-unused warnings 2018-04-23 11:38:45 -07:00
Behdad Esfahbod 7e3015a315 Fix warnings 2017-10-15 12:13:19 +02:00
Behdad Esfahbod dbdbfe3d7b Use nullptr instead of NULL 2017-10-15 12:11:08 +02:00
Behdad Esfahbod 374bb48d90 Change ptem API to make 0 mean unset 2017-10-11 15:37:50 +02:00
Behdad Esfahbod 269cf1ca82 Correctly initialize ptem 2017-10-11 15:24:22 +02:00
Behdad Esfahbod c0c2dbc871 Remove dirty tracking
Turns out I don't need this to resolve CoreText optical sizing
issue after all.

https://github.com/behdad/harfbuzz/issues/360
2017-10-11 12:23:35 +02:00
Behdad Esfahbod b57f18da70 Add hb_font_[sg]et_ptem() to set/get point size on font
New API:
hb_font_set_ptem()
hb_font_get_ptem()

Needed for hb-coretext optical sizing:
https://github.com/behdad/harfbuzz/issues/360
2017-10-11 11:47:47 +02:00
Behdad Esfahbod 3f9370d9e5 Fix TODO item 2017-10-11 11:34:53 +02:00
Behdad Esfahbod 587f15ece3 Minor 2017-08-14 15:23:10 -07:00
Philip Withnall ffde3c9f9e hb-font: Fix a potentially undefined use of memcmp() (#413)
While it’s fine to call memcmp(x, 0, 0) in practice, the C99 standard
explicitly says that this is not allowed: even if the length is zero,
the pointer arguments must be valid.

http://stackoverflow.com/a/16363034

Coverity ID: 141178

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2017-02-08 13:56:57 -08:00
Behdad Esfahbod d3d3691806 Add dirty-state tracking to hb_face_t 2017-02-03 15:42:03 -08:00
Behdad Esfahbod 2171f48b4b Add dirty-state tracking to hb_font_t 2017-02-03 10:58:09 -08:00
Behdad Esfahbod 95808bad2c Add new API hb_font_set_face()
For completeness.
2017-02-03 10:39:40 -08:00
Behdad Esfahbod 22af28a3f1 [var] Implement MVAR table
Unhooked. Untested.
2017-01-23 23:42:53 -08:00
Behdad Esfahbod 5ec96d30ca [var] Adjust API in prep for 'avar' implementation
The 'avar' table does not allow random access to axis maps,
so change API to avoid quadratic-time implementation.

Removed -hb_ot_var_normalize_axis_value(), added
+hb_ot_var_normalize_variations() and
+hb_ot_var_normalize_coords() instead.
2017-01-22 18:52:00 -08:00
Behdad Esfahbod 7647a05a0b Minor 2017-01-22 17:47:49 -08:00
Behdad Esfahbod d2f249e745 Stub out doc comments for new symbols 2017-01-22 17:42:33 -08:00
Behdad Esfahbod bb1e19268f [var] Rename var_coord to variation
Looks much better.
2017-01-21 17:42:50 -08:00
Behdad Esfahbod 64fe92bf2d [var] Remove use of variable-length arrays 2017-01-21 15:36:35 -08:00
Behdad Esfahbod 2491134b38 [var] Add hb_font_set_var_coords() 2017-01-21 15:21:50 -08:00
Behdad Esfahbod 113393efec Remove a few unused includes 2017-01-21 15:12:03 -08:00
Behdad Esfahbod 8b2a580470 [var] Add hb_font_set_var_coords_design() 2017-01-21 15:05:00 -08:00
Behdad Esfahbod 0dcc7b49a8 [var] Minor lifecycle adjustment 2017-01-21 14:50:22 -08:00
Behdad Esfahbod bf0d3a665b [var] Add hb_font_get_var_coords_normalized() 2017-01-21 14:48:46 -08:00
Behdad Esfahbod f2e73d37e7 [var] Remove over-optimization 2017-01-20 17:42:18 -08:00
Behdad Esfahbod 72ada4f0c6 [GX] Hook up feature variations
Shape-plan caching is not implemented.
2016-12-16 19:06:26 -06:00
Behdad Esfahbod 26648cebcd [GX] Remove (partial) support for anisotropic variations
It doesn't always work, not part of FreeType, and we were not going
to expose it in the API anyway.  Can always be added later.
2016-12-16 19:06:26 -06:00
Behdad Esfahbod c22176d4ba [GX] Handle setting var coords to NULL 2016-12-16 19:06:26 -06:00
Behdad Esfahbod 250bcd6fb6 [GX] Skip tail zero entries when setting variation coordinates 2016-12-16 19:06:26 -06:00
Behdad Esfahbod ad69e8f07c [GX] Add new API hb_font_set_var_coords_normalized()
Will probably change.
2016-12-16 19:06:26 -06:00
Behdad Esfahbod bb4d2e6ed5 [GX] Free GX coordinates 2016-12-16 19:06:26 -06:00
Behdad Esfahbod ca28670316 [GX] Towards anisotropic interpolation
Also hookup to ValueRecord and Anchors.
2016-12-16 19:06:26 -06:00
Behdad Esfahbod 6d9d3c55bb [GX] Add data types for encoding numerical variations 2016-12-16 19:06:26 -06:00
Behdad Esfahbod 333173103b Fix sign of shift operators
This one:

  map->mask = (1 << (next_bit + bits_needed)) - (1 << next_bit);

before the fix, the shift was done as an int, causing overflow
if it ever got to 1 << 31.  Sprinkle 'u's around.

Fixes https://bugs.chromium.org/p/chromium/issues/detail?id=634805
2016-08-08 17:28:14 -07:00
Behdad Esfahbod aba4b0ca52 Add TODO 2016-06-01 16:57:29 -07:00
Konstantin Ritt 71248a843f Fix build with HB_DISABLE_DEPRECATED
When HB_DISABLE_DEPRECATED is defined, no code from hb-deprecated.h
should be used, even from within HB itself.
2016-02-25 18:55:28 +04:00
Behdad Esfahbod c335fd7986 In trampoline implementation of get_glyph(), don't destroy user data twice! 2016-02-25 09:16:05 +09:00
Behdad Esfahbod 8b5bc141cd Add get_nominal_glyph() and get_variation_glyph() instead of get_glyph()
New API:
- hb_font_get_nominal_glyph_func_t
- hb_font_get_variation_glyph_func_t
- hb_font_funcs_set_nominal_glyph_func()
- hb_font_funcs_set_variation_glyph_func()
- hb_font_get_nominal_glyph()
- hb_font_get_variation_glyph()

Deprecated API:
- hb_font_get_glyph_func_t
- hb_font_funcs_set_glyph_func()

Clients that implement their own font-funcs are encouraged to replace
their get_glyph() implementation with a get_nominal_glyph() and
get_variation_glyph() pair.  The variation version can assume that
variation_selector argument is not zero.
2016-02-24 19:05:23 +09:00
Behdad Esfahbod f11c11a1f1 Fix Since: tags for new API
e1d4d0f1db (commitcomment-15006653)
2015-12-16 17:08:36 +01:00
Simon Cozens 6f2e6de1fa Get font ascender and descender metrics from OS/2 table. 2015-11-27 16:03:54 -05:00
Behdad Esfahbod c41c145c73 Make nil glyph_h_origin() function return true
Fixes https://github.com/behdad/harfbuzz/issues/187

Funcs implementations that have a non-zero horizontal origin must
implement the glyph_h_origin() callback, nothing new here.

Other implementations (all I know of!) can simply not set
glyph_h_origin() now.  I did that for hb-ot and hb-ft in
44f8275080, though that broke the
fallback shaper because the default was returning false...
2015-11-26 18:43:15 -05:00
jfkthame f19c6db18e Add braces for subobject initializer in _hb_font_funcs_nil
To avoid triggering -Wmissing-braces; see https://bugzilla.mozilla.org/show_bug.cgi?id=1226175#c8
2015-11-20 08:43:49 +00:00
Behdad Esfahbod 28de104f15 Move variable-sized struct member to end
Hopefully makes clang build happy
2015-11-04 22:03:09 -08:00
Behdad Esfahbod 762770c964 Add font->has_...() to check for individual nil font funcs
Hopefully this wouldn't break any compiler.  There was some magic
moments to getting this to compile...
2015-11-04 21:49:19 -08:00
Behdad Esfahbod 88e9a9bcae Minor reshaping of hb_font_funcs_t implementation
In anticipation of further changes.  No functional changes.
2015-11-04 21:16:26 -08:00
Behdad Esfahbod da29b43794 Separate nil font-funcs from parent-peeking font-funcs
API change: all fonts created with hb_font_create() now inherit from
(ie have parent) hb_font_get_empty().
2015-11-04 20:22:44 -08:00
Behdad Esfahbod 3e905e396b Add hb_font_set_parent()
No reason to not have it.  Makes life easier later.
We (hb-ft, hb-ot-font, etc) can use this API to inject new
parent into a font...
2015-10-08 12:51:02 -04:00
Behdad Esfahbod 88da7bba9f Default font scale to face upem
Makes for a better default and avoids nasty inheritance issues.
See mailing list thread "Default hb_font_t scale".
2015-10-02 14:38:20 +01:00
Behdad Esfahbod 1866e17114 Make hb_font_create_sub_font() NOT make parent immutable
We don't rely on that.  However, whenever hb_font_make_immutable()
is called, it makes its parenting chain immutable.
2015-10-02 14:21:29 +01:00
Behdad Esfahbod 5d74ff02ab Fix Since: version tags on font and face APIs
A while back we marked every API as version:1.0.  We should fix them all
to reflect real version they were introduced.  This is a start.

Patch from Nikolay Sivov.
2015-09-03 14:55:59 +04:30
Sascha Brawer 01c3a88543 Fix "Since:" tags
Based on data from http://upstream-tracker.org/versions/harfbuzz.html
Resolves #103
2015-06-01 13:25:27 +02:00
Behdad Esfahbod eb0bf3ae66 Relax inert checks
Previously, when creating an object from inert inputs (eg:
"hb_font_create(hb_face_get_empty())") we returned the inert
empty object.  This is not helpful as there are legitimate
usecases to do that.

We now never return the inert object unless allocation failed.

Tests are revised to reflect.
2015-04-09 19:16:57 -07:00
Khaled Hosny a394bb6670 [bindings] Fix *_from_string functions
Without the element-type they will be getting garbage, at least with
Python.
2015-03-22 20:29:10 +02:00
Behdad Esfahbod 3f310dc0ca Disallow changing settings on immutable face
Ouch!
2014-07-22 16:26:27 -04:00
Behdad Esfahbod 2a8c49ade0 Remove unnecessary includes 2013-12-11 20:24:20 -05:00
Behdad Esfahbod a8949df487 [introspection] Annotate Unicode / font callbacks
Should move these out of the public header...

We're "clean" of introspection warnings now.  Remaining ones are about
graphite2 / freetype types not being introspectable.
2013-09-13 20:31:07 -04:00
Behdad Esfahbod 085d4291a9 [introspection] Disable constructors for now
Since our types are not associated with their methods, marking
constructors makes them inaccessible from bindings.  Undo for now.
2013-09-12 17:14:33 -04:00
Behdad Esfahbod 70303cf23b [docs/introspection] Some more annotations 2013-09-06 17:38:25 -04:00
Behdad Esfahbod 288f289997 [docs/introspection] More annotations 2013-09-06 17:30:54 -04:00
Behdad Esfahbod 2e3a07abdf Separate face source code from font
Makes documentation / introspection easier.
2013-08-27 11:46:08 -04:00
Behdad Esfahbod e05a999495 Add hb_face_[sg]et_glyph_count() 2012-11-15 16:23:21 -08:00
Behdad Esfahbod 7c8e844d92 Use namespace for OpenType tables
Avoids USHORT, SHORT, ULONG, LONG clashes with Windows API.
2012-08-28 17:57:49 -04:00
Behdad Esfahbod 4c8ac4f47e Misc minor fixes 2012-08-08 17:44:19 -04:00
Behdad Esfahbod 6f3a300138 Add hb_font_glyph_from/to_string 2012-08-07 22:13:25 -04:00
Behdad Esfahbod 368b4e7649 Minor 2012-08-06 23:06:04 -04:00
Behdad Esfahbod 66591ececf Remove unnecessary lifecycle bits
We already set recount to INVALID when destroying.
This block was not necessary.
2012-08-06 17:07:19 -07:00
Behdad Esfahbod 8fbfda920e Inline font getters 2012-08-01 19:03:46 -04:00
Behdad Esfahbod 2f87cebe10 Implement shape_plan caching
Should give us some performance boost.
2012-07-27 04:20:39 -04:00
Behdad Esfahbod ea278d3895 Partially switch ot shaper to shape_plan 2012-07-27 02:12:28 -04:00
Behdad Esfahbod 027857d041 Start adding a unified shaper access infrastructure
Add global shape_plan.  Unused so far.
2012-07-26 21:14:02 -04:00
Behdad Esfahbod 1bc1cb3603 Make source more digestable for gobject-introspection 2012-06-16 15:21:55 -04:00
Behdad Esfahbod 0594a24484 Cleanup TRUE/FALSE vs true/false 2012-06-05 20:35:40 -04:00
Behdad Esfahbod f06ab8a426 Better hide nil objects and make them const 2012-06-05 14:49:14 -04:00
Behdad Esfahbod bce095524b Add hb_font_get_glyph_name() and hb_font_get_glyph_from_name() 2012-05-28 10:45:50 -04:00
Behdad Esfahbod 20fdb0f41d Add a lock-free cache type for int->int functions
To be used for cmap and advance caching if desired.
2012-05-17 22:04:45 -04:00
Behdad Esfahbod d993e72331 Fix hb_face_set_index() 2012-05-13 16:04:36 +02:00
Behdad Esfahbod 0cd33592ab Fix possible leaks 2011-09-21 16:49:33 -04:00
Behdad Esfahbod b9415e76d7 [API] Add hb_font_set_funcs_data() 2011-08-19 19:20:30 +02:00
Behdad Esfahbod 7a750ac33e Rename table files from eg maxp-private.hh to maxp-table.hh 2011-08-17 14:19:59 +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 3897335c76 [API] Sort out get_blob API
hb_face_get_blob() renamed to hb_face_reference_blob(), returns a
reference now.

hb_face_[sg]et_index() added.

hb_face_set_upem() added.
2011-08-08 23:37:41 +02:00
Behdad Esfahbod e715784be3 Rename get_table to reference_table in all API 2011-08-08 21:43:06 +02:00
Behdad Esfahbod c605bbbb6d Remove C++ guards from source files
Where causing issues for people with MSVC.
2011-08-04 20:00:53 -04:00
Behdad Esfahbod bf8c57ba74 [API] Add hb_face_get_blob()
Need to think more about it.
2011-08-03 17:38:04 -04:00
Behdad Esfahbod 4b6317c4f4 More code shuffling 2011-07-07 23:14:42 -04:00
Behdad Esfahbod 2d8ebcb9d0 [API] One last font-funcs API change
Now that vertical text works correctly, I'm doing a last round
modification of the font-funcs API to simplify.  Expect no more
changes around here.
2011-05-25 11:27:33 -04:00
Behdad Esfahbod 67d51ff961 [Vertical] Do fallback origin calculation 2011-05-19 19:08:57 -04:00