test/api


Log

Author Commit Date CI Message
Behdad Esfahbod 47089fe7 2025-05-28T17:10:22 Big misc changes - Make geometry types into templates taking float or double. - Changes to paint() transform elimination. - Add font->has_nonzero_coords and use it across. - Extensions to avar processing for otherwise invalid mappings.
Behdad Esfahbod 7e353d37 2025-05-23T14:31:35 [test] Remove u8 prefix from strings No idea how/why this got in there to begin with.
Behdad Esfahbod fcedcf81 2025-04-25T19:04:37 [coretext] Another old-system build fix Fixes https://github.com/harfbuzz/harfbuzz/issues/5300#issuecomment-2831684725
Behdad Esfahbod 38db1fac 2025-04-23T18:02:06 [paint] Change back return type of paint_glyph() to void Add new "_or_fail" variants of draw_glyph and paint_glyph New API: +hb_font_draw_glyph_or_fail_func_t +hb_font_paint_glyph_or_fail_func_t +hb_font_funcs_set_draw_glyph_or_fail_func() +hb_font_funcs_set_paint_glyph_or_fail_func() +hb_font_draw_glyph_or_fail() +hb_font_paint_glyph_or_fail() Deprecated API: -hb_font_draw_glyph_func_t -hb_font_paint_glyph_func_t -hb_font_funcs_set_draw_glyph_func() -hb_font_funcs_set_paint_glyph_func()
Behdad Esfahbod e78310bf 2025-04-23T00:58:08 [paint] Change return type to bool, and return false for outline glyphs It was impossible to get synthetic bold/slant correctly with the previous API. This is a minor API break, but one I'm willing to take.
Behdad Esfahbod 9445778e 2025-04-22T21:33:15 [test-paint] Update expectations for recent slant changes
Behdad Esfahbod 8aa88aa4 2025-04-20T04:08:41 [COLRv1:ot/ft] Use paint-bounded instead of paint-extents Faster. Note that this also means that if there is no clip-box, we don't compute the bounds and emit an initial clip anymore. That was totally unnecessary and against the COLRv1 rendering algorithm. This makes painting of COLRv1 fonts without clipboxes *much* faster, as previously we were computing bounds using all subglyph outlines. Not anymore. Before: BM_Font/paint_glyph/Nupuram-Color.colrv1.ttf/ot 1.78 ms After: BM_Font/paint_glyph/Nupuram-Color.colrv1.ttf/ot 0.155 ms
Behdad Esfahbod a3d626b4 2025-04-06T19:16:43 [test-object] Hopefully last ubsan fix API change: - hb_face_is_immutable() now takes `hb_face_t *` instead of previous `const hb_face_t *`. This should not pose any problem for any clients in our belief.
Behdad Esfahbod b99382e2 2025-04-06T18:53:53 [test-unicode] Try disabling one test under ubsan
Behdad Esfahbod ba4a92c5 2025-04-06T18:48:39 [test-object] Fix ubsan issues
Behdad Esfahbod 8a1ba4d1 2025-04-06T18:12:22 [test-object] See if this helps make ubsan happy
Behdad Esfahbod fb04a306 2025-04-06T17:41:18 [test/api] Fix a few ubsan issues
Behdad Esfahbod b4390115 2025-04-06T17:28:03 [test-draw] Make ubsan happy
Behdad Esfahbod 155e1e63 2025-04-06T03:49:15 [test/api] Use g_assert_true instead of g_assert The latter terminates the program. The former marks the test as failing.
Behdad Esfahbod e4e4d665 2025-04-06T00:12:22 [test/api] Test remaining tests to TAP
Behdad Esfahbod f69ecc94 2025-04-05T22:37:34 [test/api] Set protocol:tap
Behdad Esfahbod bee08cf2 2025-04-05T23:07:25 [hb-test] Don't convert _ in test names to / Slash is used for grouping...
Behdad Esfahbod 3cf48234 2025-04-05T23:04:14 [hb-test.h] Remove unsed functions
Behdad Esfahbod 112b5998 2025-04-05T22:37:10 [test] Minor use hb_test_init
Behdad Esfahbod 6c98519c 2025-04-05T21:26:00 [test/api] Simplify deps
Khaled Hosny a24c40df 2025-04-06T03:03:43 [test/ot-math] Do away with global variables
Khaled Hosny d74606bb 2025-04-06T02:40:39 [test/ot-math] Port to use hb_test_open_font_file() Avoids the unnecessary dependency on FreeType.
Khaled Hosny 2d8e5255 2025-04-06T02:22:43 [test/ot-math] Add a test for the Cambria Math workaround
Garret Rieger a1e587b7 2025-03-31T22:02:11 [subset] Add hb_subset_cff_get_charstrings_index and hb_subset_cff2_get_charstrings_index. These methods allow retrieving the entire charstrings index structure from a CFF or CFF2 table.
Garret Rieger ae8b288d 2025-03-27T22:07:01 [subset] Correctly handle lifetime of charstrings data blob returned by hb_subset_cff_get_charstring_data.
Garret Rieger 0d4053b1 2025-03-27T18:45:12 [subset] Add hb-subset.h API for retrieving the raw per glyph outline data from CFF and CFF2.
Khaled Hosny 8d62ad3b 2025-03-23T15:27:36 [directwrite] Don’t release IDWriteFace pass to hb_directwrite_font_create That was a leftover from previous code and is incorrect now as we would be double releasing it.
Khaled Hosny c226da8c 2025-03-23T15:22:47 [test/directwrite] Make the variations test actually test variations
Behdad Esfahbod 018858b2 2025-03-22T20:24:44 Merge branch 'main' into ci-exe-wrapper
Behdad Esfahbod 3259f9f8 2025-03-22T19:57:51 [test-directwrite] Fix test
Behdad Esfahbod 9afdc7e1 2025-03-22T19:39:48 [test-directwrite] Simplify
Khaled Hosny 1c7a1c7b 2025-03-23T02:10:06 [test-directwrite] Don’t fail if Bahnschrift can’t be loaded under Wine It is unlikely to be present if one is not running on Windows.
Khaled Hosny ed558e5d 2025-03-23T01:28:41 [test] Add name table to test/api/fonts/glyphs.ttf Some version of Wine fails to load the font otherwise.
Behdad Esfahbod f53befb6 2025-03-22T16:54:56 [test/directwrite] Fix a leak
Behdad Esfahbod c274ee7b 2025-03-22T16:02:39 [directwrite] Add hb_font_t setter/getter from IDWriteFontFace Changed API: +hb_directwrite_font_create() New API: +hb_directwrite_font_get_dw_font_face()
Behdad Esfahbod 379688c5 2025-03-13T14:47:34 [test-face] Relax on face load failure
Behdad Esfahbod 469502c9 2025-03-12T11:02:43 [test-paint] Test fontations too Luckily it passes!
Behdad Esfahbod d014efd0 2025-03-11T13:37:48 Merge pull request #5131 from harfbuzz/using2 Add hb_ft_face_create_from_blob_or_fail() et al
Behdad Esfahbod 759e1881 2025-03-11T12:12:08 [coretext] Fix loading TTC files
Behdad Esfahbod 15fcfcb6 2025-03-11T12:01:20 Merge pull request #5129 from harfbuzz/buffer-deserialize Fix buffer deserialize
Behdad Esfahbod 5e6da541 2025-03-11T12:00:18 [test] Minor, accept absolute font paths
Behdad Esfahbod 8687f5c3 2025-03-10T23:11:27 [face] Add tests for new constructors
Behdad Esfahbod 756668d3 2025-03-11T11:27:02 [directwrite] Drop dependency again as per review https://github.com/harfbuzz/harfbuzz/pull/5132#issuecomment-2714186460
Behdad Esfahbod 6b2f8592 2025-03-11T00:27:32 [test-c] Disable gobject include It can't find its dependent headers since not installed.
Behdad Esfahbod 8ca892b0 2025-03-11T00:19:34 [directwrite] Simplify headers
Behdad Esfahbod d247c116 2025-03-11T00:11:41 [test-draw] Test all font funcs
Behdad Esfahbod d2ccf595 2025-03-11T00:15:19 Directwrite is a C++ header?
Behdad Esfahbod 41dcc493 2025-03-10T23:40:39 [test-cplusplus] Simplify
Behdad Esfahbod dbad6cdf 2025-03-10T23:20:54 [test-c(plusplus)] Add more headers
Behdad Esfahbod 3c02fcd0 2025-03-10T23:16:30 [test-multithread] Simplify
Behdad Esfahbod 7a912c47 2025-03-10T16:20:16 [buffer-deserialize] Fix return value and parsing I think I got it right. Alternative to https://github.com/harfbuzz/harfbuzz/pull/5028
Behdad Esfahbod 712a403b 2025-03-08T12:23:41 [font-funcs-using] Apply review feedback
Behdad Esfahbod c3eac5c0 2025-03-08T11:54:15 [test-threads] Test all font-funcs Fontations & Coretext are new and seems to pass.
Behdad Esfahbod 2a878b1b 2025-03-07T17:23:17 [font-funcs] Add two new API + hb_font_set_funcs_using() + hb_font_list_funcs() Part of https://github.com/harfbuzz/harfbuzz/issues/5117
Matthias Clasen 41e14f70 2025-03-07T08:00:34 [test-paint] Use latest test fonts Update the color test fonts from https://github.com/googlefonts/color-fonts/ repository and update the test results.
Behdad Esfahbod 6506bd7e 2025-03-06T20:00:54 Merge pull request #4498 from harfbuzz/PaintColrLayers [COLRv1] Optimize PaintColrLayers instead of PaintComposite
Matthias Clasen 9fbc2d23 2025-03-06T20:11:23 [test-paint] Regenerate the test output This commit updates the expected output of the paint tests to what the current code produces.
Matthias Clasen 0ce90f60 2025-03-06T20:10:13 [test-paint] Make it easier to regenerate test output This command will regenerate the expected output for all the paint tests: GENERATE_DATA=1 G_TEST_SRCDIR=./test/api ./build/test/api/test-paint
Khaled Hosny aecc9110 2025-03-06T03:51:57 [fontations/test] Add to test-draw
Khaled Hosny 69e1c3c3 2025-02-28T00:25:17 [ft] Add hb_ft_font_get_ft_face() A new name for hb_ft_font_get_face(), which is now deprecated. Fixes https://github.com/harfbuzz/harfbuzz/issues/5084
Behdad Esfahbod 9d149c52 2025-02-26T15:07:46 [test-paint] Redirect generated output to stderr
Behdad Esfahbod 753093d6 2025-02-26T14:41:04 [test-colrv1] Add test files from https://roettsch.es/var_colrv1.html These are not currently used for any testing. To be used later.
Behdad Esfahbod 6fe14417 2023-11-17T12:25:42 [test-paint] Update comment
Behdad Esfahbod 74bb7c52 2025-02-24T20:21:38 Fix a compiler warning
Khaled Hosny 03cf1565 2025-02-20T21:56:56 [directwrite] Rename font_get_font to font_get_dw_font https://github.com/harfbuzz/harfbuzz/pull/5079#pullrequestreview-2627407692
Khaled Hosny a8fd2971 2025-02-13T17:16:20 [directwrite] Add hb_directwrite_font_create()/font_get_font() Uses hb_directwrite_face_create() under the hood, but copies variations from directwrite to hb-font.
Khaled Hosny ff3aaece 2025-02-10T14:25:58 [test/shape-plan] Add another test and some comments
Khaled Hosny cf336f17 2025-02-10T14:15:25 [shape-plan] Rename hb_ot_shape_plan_get_features to get_feature_tags Simplify the API by returning only feature tags. The users of this API would be interested only in feature enabled by default and whether the feature is globally or partially enabled wouldn’t be of much interest in that case. For user features, the user of the API already have full access to them.
Khaled Hosny a7d7715f 2025-02-02T23:06:11 [shape-plan] Add hb_ot_shape_plan_get_features This should get the features on a shape plan after executing it. Initially I wanted to return an array of tags, but then there can be user features that are not enabled globally, so I thought returning hb_feature_t with value and range would be better. There is a TODO since I couldn’t figure out how to get the value and range from the feature mask. But also it may be overkill and a simple boolean indicating wither it is a global feature or not would be enough. I wounder also what should happen to non-user features that are applied selectively, like init or medi, does ot make sense to indicate whether they are global or not? This is inspired by the discussion in: https://github.com/fontforge/fontforge/pull/5522#pullrequestreview-2574321449, but it might be useful to other HarfBuzz users.
Khaled Hosny 8c561733 2025-02-12T12:37:10 [test/coretext] Add a test for copying variations
Behdad Esfahbod c55738fa 2025-02-09T08:08:52 [test] Set MALLOC_CHECK_ to 1 instead of 2; kill G_SLICE=always-malloc MALLOC_CHECK_=2 makes running tests twice slower on macOS. Value 1 is as fast as not checking at all. It's not like this ever caught a bug for us or anything. We have so many sanitizers and fuzzers funning on CI, which catch all kinds of memory problems. G_SLICE is long gone in glib. The slowest part of running the test suite now is the google-benchmark tests, that get run by us... I'll see if I can disable. I had reported it before at https://github.com/harfbuzz/harfbuzz/issues/4153
Behdad Esfahbod 7f5fac7c 2025-02-04T23:35:34 [test-buffer] Fix unintionally merged change
Behdad Esfahbod f0ead852 2025-02-04T23:27:03 [aat] Implement set filtering for Noncontextual chains as well
Khaled Hosny 4825e5e2 2025-02-04T00:54:58 [face] Add fallback implementation to hb_face_reference_blob If referencing the face blob is not possible (e.g. not implemented by the font functions), use face builder to create a blob out of individual table blobs. Fixes https://github.com/harfbuzz/harfbuzz/issues/5036
Behdad Esfahbod b394ab39 2025-01-31T10:21:31 [test-buffer] Add code for testing end_ptr
Garret Rieger bdb50f1c 2025-01-07T20:32:05 [repacker] Also rename api method from hb_subset_repack_or_fail -> hb_subset_serialize_or_fail.
Garret Rieger 05650416 2025-01-07T19:56:25 [repacker] rename hb-subset-repacker -> hb-subset-serialize. Also hb_link_t and hb_object_t to hb_subset_serialize_link_t and hb_subset_serialize_object_t.
Garret Rieger b0d52abe 2024-10-23T20:49:44 [subset] consider variation selectors subsetting cmap14 cmap14 subsetting code was not considering variation selectors in the input unicode set when deciding which variant glyphs to keep. This updates subsetting to only keeps variant glyphs if their variation selector code point is in the input unicodes set. For https://github.com/harfbuzz/harfbuzz/issues/4911
Behdad Esfahbod 755929c4 2024-10-12T20:08:32 Fix more compiler warnings In case FreeType is not available.
Khaled Hosny 4d1f6e04 2024-10-06T18:25:24 [COLR] Enable COLRv0 support in get_extents() paint_glyph() supports COLRv0 but this code is never reached because of the early return if version is not 1. This early return seems to be from before COLRv0 extents were supported.
Julien Nabet 8de0d911 2024-10-06T18:44:21 missing-field-initializers in test/api/test-ot-face.c FAILED: test/fuzzing/hb-shape-fuzzer.p/hb-shape-fuzzer.cc.o clang++ -Itest/fuzzing/hb-shape-fuzzer.p -Itest/fuzzing -I../test/fuzzing -I. -I.. -Isrc -I../src -fdiagnostics-color=always -D_GLIBCXX_ASSERTIONS=1 -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -std=c++11 -fno-exceptions -O3 -fno-exceptions -fno-rtti -fno-threadsafe-statics -fvisibility-inlines-hidden -DHAVE_CONFIG_H -Wall -Wextra -Werror -MD -MQ test/fuzzing/hb-shape-fuzzer.p/hb-shape-fuzzer.cc.o -MF test/fuzzing/hb-shape-fuzzer.p/hb-shape-fuzzer.cc.o.d -o test/fuzzing/hb-shape-fuzzer.p/hb-shape-fuzzer.cc.o -c ../test/fuzzing/hb-shape-fuzzer.cc In file included from ../test/fuzzing/hb-shape-fuzzer.cc:9: ../test/fuzzing/../api/test-ot-face.c:47:34: error: missing field 'y_bearing' initializer [-Werror,-Wmissing-field-initializers] hb_glyph_extents_t extents = {0}; ^ ../test/fuzzing/../api/test-ot-face.c:85:55: error: missing field 'enable' initializer [-Werror,-Wmissing-field-initializers] hb_aat_layout_feature_selector_info_t setting = {0}; ^ 2 errors generated.
David Corbett e30dedbb 2024-09-14T12:06:08 [Unicode 16] Add tests
Behdad Esfahbod 59a97ac0 2024-08-06T14:53:36 [test] More get_table_tags test
Behdad Esfahbod a55b0071 2024-08-06T14:39:10 [test] Add get_table_tags test for hb-coretext
Behdad Esfahbod bd79bfb6 2024-08-06T13:40:06 [test] Add get_table_tags test for hb-ft
Behdad Esfahbod a459753e 2024-08-06T13:31:24 [test] Test get_table_tags of face_builder
Behdad Esfahbod 8896b1d5 2024-08-06T12:34:15 [test] Add test for get_table_tags So far just tests the default implementation.
Behdad Esfahbod 84f16564 2024-08-06T12:15:39 [test] Move code around
Behdad Esfahbod 22e1a5a7 2024-08-06T12:20:34 [test-paint] Fix warnings
Behdad Esfahbod 191c6eed 2024-08-06T06:59:32 Fix Linux bot
Behdad Esfahbod e0c3cbf1 2024-08-06T06:46:44 [subset] Fail if source face has no glyphs Also return nullptr if any of the input pointers are nullptr. Before we were returning the empty face. Fixes https://github.com/harfbuzz/harfbuzz/issues/4824
Khaled Hosny cf1fdf16 2024-06-27T06:54:02 Drop autotools build Fixes https://github.com/harfbuzz/harfbuzz/issues/4720
Behdad Esfahbod 49c8493f 2024-06-20T11:16:40 [test] Build with HB_MINI Also add CONFIG.md instructions for building configs with meson. Fixes https://github.com/harfbuzz/harfbuzz/issues/4760
ssmid 106e4068 2024-06-20T09:50:46 HB_SCRIPT_CANADIAN_ABORIGINAL removed, as deprecated
ssmid 8de7e9fd 2024-06-20T08:54:23 deprecation cleanup: HB_BUFFER_FLAGS_DEFAULT removed
Behdad Esfahbod 9456f6bd 2024-06-02T10:32:07 [test] Fix a few compiler warnings
David Corbett c2b5b7b9 2024-06-01T12:48:17 [ot-tags] Update IANA and OT language registries
Khaled Hosny 135d6537 2024-05-31T01:25:05 test-draw-varc.c: Fix “warning: unused function”
Behdad Esfahbod 0037ee28 2024-05-24T08:10:15 Merge pull request #4578 from harfbuzz/varc-table `VARC` table
David Corbett 0db136b1 2024-05-09T11:49:48 [subset-cff] Shorten output of `encode_num_tp`