platform/upstream/libHarfBuzzSharp.git
5 years agoAdd 10.13.6 aat fonts tests and bot (#1409)
Ebrahim Byagowi [Sat, 24 Nov 2018 22:09:00 +0000 (01:39 +0330)]
Add 10.13.6 aat fonts tests and bot (#1409)

5 years ago[aat] Add test for recent regression
Behdad Esfahbod [Sat, 24 Nov 2018 20:56:17 +0000 (15:56 -0500)]
[aat] Add test for recent regression

5 years ago[tests] Redo test runner logging a bit
Behdad Esfahbod [Sat, 24 Nov 2018 20:49:33 +0000 (15:49 -0500)]
[tests] Redo test runner logging a  bit

5 years ago[tests] Minor
Behdad Esfahbod [Sat, 24 Nov 2018 20:42:11 +0000 (15:42 -0500)]
[tests] Minor

5 years ago[tests/shaping] Allow comments in test files
Behdad Esfahbod [Sat, 24 Nov 2018 20:37:01 +0000 (15:37 -0500)]
[tests/shaping] Allow comments in test files

Line should start with "# ".

5 years ago[tests] Rename
Behdad Esfahbod [Sat, 24 Nov 2018 20:22:09 +0000 (15:22 -0500)]
[tests] Rename

5 years ago[morx/kerx] Fix sanitize regression
Behdad Esfahbod [Sat, 24 Nov 2018 19:52:34 +0000 (14:52 -0500)]
[morx/kerx] Fix sanitize regression

Broke in 8dcc1913a1670ede7b124f7b5b775d7ab8791386

If sanitizer is left with another object, it wouldn't work.

Better fix coming soon.

5 years ago[test] Enable more of aots tests (#1408)
Ebrahim Byagowi [Sat, 24 Nov 2018 17:19:21 +0000 (20:49 +0330)]
[test] Enable more of aots tests (#1408)

The ones commented out in this change should've be passed :/
a closer look is needed.

5 years agoAdd Adobe AOTS tests (#1395)
Ebrahim Byagowi [Sat, 24 Nov 2018 16:37:24 +0000 (20:07 +0330)]
Add Adobe AOTS tests (#1395)

Annotated OpenType Specification or aots, https://github.com/adobe-type-tools/aots
provides a set of tests for OpenType specification, this change add those tests in addition
to modified version of their HarfBuzz test runner for generating harfbuzz project specific tests.

5 years ago[color] Use SortedUnsizedArrayOf<>
Behdad Esfahbod [Sat, 24 Nov 2018 15:25:10 +0000 (10:25 -0500)]
[color] Use SortedUnsizedArrayOf<>

5 years ago[trak] Coment
Behdad Esfahbod [Sat, 24 Nov 2018 15:17:59 +0000 (10:17 -0500)]
[trak] Coment

5 years ago[arrays] Add not_found to reference bsearch as well
Behdad Esfahbod [Sat, 24 Nov 2018 15:09:17 +0000 (10:09 -0500)]
[arrays] Add not_found to reference bsearch as well

5 years ago[arrays] Improve bfind() interface
Behdad Esfahbod [Sat, 24 Nov 2018 15:06:13 +0000 (10:06 -0500)]
[arrays] Improve bfind() interface

Much more useful now. :)

5 years ago[fuzzing] Add tests for previous commit
Behdad Esfahbod [Sat, 24 Nov 2018 14:49:21 +0000 (09:49 -0500)]
[fuzzing] Add tests for previous commit

Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11526
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11522

5 years ago[kerx/morx] Make sure object length is sanitized before accessing it
Behdad Esfahbod [Sat, 24 Nov 2018 14:47:45 +0000 (09:47 -0500)]
[kerx/morx] Make sure object length is sanitized before accessing it

5 years ago[arrays] Port ArrayOf.qsort() and hb_vector_t.qsort() to hb_array_t
Behdad Esfahbod [Sat, 24 Nov 2018 06:59:50 +0000 (01:59 -0500)]
[arrays] Port ArrayOf.qsort() and hb_vector_t.qsort() to hb_array_t

5 years ago[arrays] Port ArrayOf.qsort() to hb_array_t's
Behdad Esfahbod [Sat, 24 Nov 2018 06:48:48 +0000 (01:48 -0500)]
[arrays] Port ArrayOf.qsort() to hb_array_t's

5 years ago[arrays] Add copy-constructor to hb_array_t and hb_sorted_array_t
Behdad Esfahbod [Sat, 24 Nov 2018 06:47:49 +0000 (01:47 -0500)]
[arrays] Add copy-constructor to hb_array_t and hb_sorted_array_t

5 years ago[arrays] Port hb_vector_t.qsort() to hb_array_t's
Behdad Esfahbod [Sat, 24 Nov 2018 06:45:58 +0000 (01:45 -0500)]
[arrays] Port hb_vector_t.qsort() to hb_array_t's

5 years ago[arrays] Remove one flavor of hb_vector_t.qsort()
Behdad Esfahbod [Sat, 24 Nov 2018 06:42:17 +0000 (01:42 -0500)]
[arrays] Remove one flavor of hb_vector_t.qsort()

5 years ago[arrays] Add (unused) SortedUnsizedArrayOf<>
Behdad Esfahbod [Sat, 24 Nov 2018 06:37:11 +0000 (01:37 -0500)]
[arrays] Add (unused) SortedUnsizedArrayOf<>

5 years ago[arrays] Port SortedArrayOf.bsearch/bfind to hb_sorted_array_t's
Behdad Esfahbod [Sat, 24 Nov 2018 06:31:00 +0000 (01:31 -0500)]
[arrays] Port SortedArrayOf.bsearch/bfind to hb_sorted_array_t's

5 years ago[arrays] Port hb_vector_t.bsearch/bfind to (new) hb_sorted_array_t's
Behdad Esfahbod [Sat, 24 Nov 2018 06:24:48 +0000 (01:24 -0500)]
[arrays] Port hb_vector_t.bsearch/bfind to (new) hb_sorted_array_t's

5 years ago[arrays] Port (unused) ArrayOf.lsearch() to hb_array_t's
Behdad Esfahbod [Sat, 24 Nov 2018 06:11:12 +0000 (01:11 -0500)]
[arrays] Port (unused) ArrayOf.lsearch() to hb_array_t's

5 years ago[arrays] Port hb_vector_t.lsearch() to hb_array_t's
Behdad Esfahbod [Sat, 24 Nov 2018 06:09:28 +0000 (01:09 -0500)]
[arrays] Port hb_vector_t.lsearch() to hb_array_t's

5 years ago[arrays] More
Behdad Esfahbod [Sat, 24 Nov 2018 06:07:15 +0000 (01:07 -0500)]
[arrays] More

5 years ago[arrays] Update ArrayOf.lsearch()
Behdad Esfahbod [Sat, 24 Nov 2018 05:58:44 +0000 (00:58 -0500)]
[arrays] Update ArrayOf.lsearch()

Currently unused apparently

5 years ago[arrays] Change argument type of cmp called by hb_vector_t.bsearch()
Behdad Esfahbod [Sat, 24 Nov 2018 05:53:19 +0000 (00:53 -0500)]
[arrays] Change argument type of cmp called by hb_vector_t.bsearch()

Towards consolidating all array bsearch/...

5 years agoUsermanual: clusters chapter; add brief grapheme definition and clarify monotonous...
Nathan Willis [Thu, 15 Nov 2018 23:40:21 +0000 (17:40 -0600)]
Usermanual: clusters chapter; add brief grapheme definition and clarify monotonous cluster handling.

5 years agoUsermanual: clusters chapter, minor updates.
Nathan Willis [Thu, 15 Nov 2018 21:47:03 +0000 (15:47 -0600)]
Usermanual: clusters chapter, minor updates.

5 years agoUsermanual: expand clusters chapter.
Nathan Willis [Mon, 12 Nov 2018 18:17:06 +0000 (12:17 -0600)]
Usermanual: expand clusters chapter.

5 years agoChange ArrayOf.bsearch() return semantics
Behdad Esfahbod [Sat, 24 Nov 2018 05:35:31 +0000 (00:35 -0500)]
Change ArrayOf.bsearch() return semantics

Towards consolidating all array bsearch/...

5 years agoMinor
Behdad Esfahbod [Sat, 24 Nov 2018 05:38:36 +0000 (00:38 -0500)]
Minor

5 years agoWhitespace
Behdad Esfahbod [Sat, 24 Nov 2018 05:45:55 +0000 (00:45 -0500)]
Whitespace

5 years agoAssert that item-type of arrays have static size
Behdad Esfahbod [Sat, 24 Nov 2018 05:31:40 +0000 (00:31 -0500)]
Assert that item-type of arrays have static size

5 years ago[vector] Rename
Behdad Esfahbod [Sat, 24 Nov 2018 05:29:22 +0000 (00:29 -0500)]
[vector] Rename

5 years ago[aat] Minor
Behdad Esfahbod [Sat, 24 Nov 2018 05:27:57 +0000 (00:27 -0500)]
[aat] Minor

5 years agoAdd hb_static_size(T)
Behdad Esfahbod [Sat, 24 Nov 2018 05:25:40 +0000 (00:25 -0500)]
Add hb_static_size(T)

5 years agoAdd template-function convenience macros
Behdad Esfahbod [Sat, 24 Nov 2018 05:22:21 +0000 (00:22 -0500)]
Add template-function convenience macros

5 years agoAdd null bytes for CmapSubtableLongGroup
Behdad Esfahbod [Sat, 24 Nov 2018 00:58:49 +0000 (19:58 -0500)]
Add null bytes for CmapSubtableLongGroup

5 years agoRemove lsearch for small TableDirectorys
Behdad Esfahbod [Fri, 23 Nov 2018 21:24:28 +0000 (16:24 -0500)]
Remove lsearch for small TableDirectorys

5 years ago[arrays] Add as_array() to hb_vector_t<>
Behdad Esfahbod [Fri, 23 Nov 2018 21:07:43 +0000 (16:07 -0500)]
[arrays] Add as_array() to hb_vector_t<>

5 years ago[arrays] Add as_array() to ArrayOf<>
Behdad Esfahbod [Fri, 23 Nov 2018 21:04:56 +0000 (16:04 -0500)]
[arrays] Add as_array() to ArrayOf<>

5 years ago[kern] Don't enforce length of last subtable
Behdad Esfahbod [Fri, 23 Nov 2018 20:24:17 +0000 (15:24 -0500)]
[kern] Don't enforce length of last subtable

5 years agoMerge pull request #1407 from harfbuzz/at-sign
Behdad Esfahbod [Fri, 23 Nov 2018 18:49:34 +0000 (13:49 -0500)]
Merge pull request #1407 from harfbuzz/at-sign

Don't canonicalize '@' to '-' in language tags

5 years agoDon't canonicalize '@' to '-' in language tags
David Corbett [Fri, 23 Nov 2018 18:21:22 +0000 (13:21 -0500)]
Don't canonicalize '@' to '-' in language tags

Fixes #1406.

5 years ago[aat] Update expectation
Ebrahim Byagowi [Fri, 23 Nov 2018 16:28:56 +0000 (19:58 +0330)]
[aat] Update expectation

5 years ago[aat] Disable mark advance zeroing if kern table has state-machines
Behdad Esfahbod [Fri, 23 Nov 2018 16:10:17 +0000 (11:10 -0500)]
[aat] Disable mark advance zeroing if kern table has state-machines

Geeza Pro for example, relies on that for fancy mark positioning.

Fixes https://github.com/harfbuzz/harfbuzz/issues/1405

5 years agoMinor
Behdad Esfahbod [Fri, 23 Nov 2018 15:45:44 +0000 (10:45 -0500)]
Minor

5 years ago[aat] Add macOS specific tests (#1404)
Ebrahim Byagowi [Fri, 23 Nov 2018 12:10:05 +0000 (15:40 +0330)]
[aat] Add macOS specific tests (#1404)

5 years ago[use] Minor clarification
Behdad Esfahbod [Fri, 23 Nov 2018 03:47:51 +0000 (22:47 -0500)]
[use] Minor clarification

5 years agoMinor tweak to FLAG64
Behdad Esfahbod [Fri, 23 Nov 2018 03:40:57 +0000 (22:40 -0500)]
Minor tweak to FLAG64

5 years agoMerge pull request #1291 from harfbuzz/use-reordering
Behdad Esfahbod [Fri, 23 Nov 2018 03:39:12 +0000 (22:39 -0500)]
Merge pull request #1291 from harfbuzz/use-reordering

[use] Fix reordering

5 years ago[cmap] Move code around
Behdad Esfahbod [Fri, 23 Nov 2018 03:17:49 +0000 (22:17 -0500)]
[cmap] Move code around

5 years ago[morx/kerx] Limit range to subtable when sanitizing
Behdad Esfahbod [Fri, 23 Nov 2018 03:16:12 +0000 (22:16 -0500)]
[morx/kerx] Limit range to subtable when sanitizing

5 years ago[sanitizer] Add reset_object(), make set_object() do bounds-check
Behdad Esfahbod [Fri, 23 Nov 2018 03:12:36 +0000 (22:12 -0500)]
[sanitizer] Add reset_object(), make set_object() do bounds-check

Affects morx/kerx run-time only currently.  Will adjust their sanitize next.

5 years ago[kerx] Make sure subtables are non-zero-length
Behdad Esfahbod [Fri, 23 Nov 2018 03:02:19 +0000 (22:02 -0500)]
[kerx] Make sure subtables are non-zero-length

Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11400

5 years ago[GSUB] Don't flush glyphset during recursion in closure()
Behdad Esfahbod [Fri, 23 Nov 2018 02:30:04 +0000 (21:30 -0500)]
[GSUB] Don't flush glyphset during recursion in closure()

See comment.

Supercedes https://github.com/harfbuzz/harfbuzz/pull/1401
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11366

5 years ago[subset] add fuzzer testcase.
Garret Rieger [Mon, 19 Nov 2018 21:00:24 +0000 (13:00 -0800)]
[subset] add fuzzer testcase.

5 years ago[set] Rename
Behdad Esfahbod [Fri, 23 Nov 2018 02:20:39 +0000 (21:20 -0500)]
[set] Rename

5 years agoEnforce requiring null_size even if min_size is 0
Behdad Esfahbod [Thu, 22 Nov 2018 23:07:59 +0000 (18:07 -0500)]
Enforce requiring null_size even if min_size is 0

This concludes null-size enforcement changes

5 years agoAllow non-nullable OffsetTo<> to non-Null'able objects
Behdad Esfahbod [Thu, 22 Nov 2018 23:07:36 +0000 (18:07 -0500)]
Allow non-nullable OffsetTo<> to non-Null'able objects

5 years ago[glyf] Don't mark structs UNBOUNDED
Behdad Esfahbod [Thu, 22 Nov 2018 22:56:51 +0000 (17:56 -0500)]
[glyf] Don't mark structs UNBOUNDED

See comments.

5 years agoMark UnsizedArrayOf<> as UNBOUNDED
Behdad Esfahbod [Thu, 22 Nov 2018 22:53:29 +0000 (17:53 -0500)]
Mark UnsizedArrayOf<> as UNBOUNDED

Since min_size is 0, Null() still accepts this type.

5 years ago[ot-shape] Simplify logic
Behdad Esfahbod [Thu, 22 Nov 2018 22:31:07 +0000 (17:31 -0500)]
[ot-shape] Simplify logic

5 years agoMove
Behdad Esfahbod [Thu, 22 Nov 2018 21:21:49 +0000 (16:21 -0500)]
Move

5 years ago[aat] Zero mark advances if decided so even if there's cross-kerning
Behdad Esfahbod [Thu, 22 Nov 2018 21:20:29 +0000 (16:20 -0500)]
[aat] Zero mark advances if decided so even if there's cross-kerning

Cross-kerning can only take care of positioning vertically.  It doesn't
adjust mark advance...

5 years ago[aat] Tweak fallback positioning logic when applying morx
Behdad Esfahbod [Thu, 22 Nov 2018 20:52:29 +0000 (15:52 -0500)]
[aat] Tweak fallback positioning logic when applying morx

Such that for Indic-like scripts (eg. Khmer), we don't do any fallback mark
advance-zeroing / positioning, but we do for Latin, etc.  Reuses preferences
of our script-specific OpenType shapers for those.

Fixes regression: https://github.com/harfbuzz/harfbuzz/issues/1393
Which means, fixes again: https://github.com/harfbuzz/harfbuzz/issues/1264
While not regressing: https://github.com/harfbuzz/harfbuzz/issues/1357

5 years ago[myanmar] Minor move
Behdad Esfahbod [Thu, 22 Nov 2018 19:46:39 +0000 (14:46 -0500)]
[myanmar] Minor move

5 years ago[myanmar] If there's no GSUB table, pick myanmar shaper
Behdad Esfahbod [Thu, 22 Nov 2018 19:45:46 +0000 (14:45 -0500)]
[myanmar] If there's no GSUB table, pick myanmar shaper

Needed for morx+kern mark-zeroing interaction.  All other scripts
work this way.

5 years ago[myanmar] Remove myanmar_old shaper
Behdad Esfahbod [Thu, 22 Nov 2018 19:41:01 +0000 (14:41 -0500)]
[myanmar] Remove myanmar_old shaper

Over time it has become the same as default shaper.  So, remove.

5 years agoFix spurious gcc warnings
Behdad Esfahbod [Thu, 22 Nov 2018 06:53:36 +0000 (01:53 -0500)]
Fix spurious gcc warnings

../../src/hb-null.hh:53:39: warning: enum constant in boolean context [-Wint-in-bool-context]

5 years agoMore
Behdad Esfahbod [Thu, 22 Nov 2018 06:49:12 +0000 (01:49 -0500)]
More

This makes more of the gcc spurious warning:

../../src/hb-null.hh:53:39: warning: enum constant in boolean context [-Wint-in-bool-context]

But not going to let that defeat correct code.  Type to switch to clang
as my main compiler...

5 years agoFix up recent change
Behdad Esfahbod [Thu, 22 Nov 2018 06:44:27 +0000 (01:44 -0500)]
Fix up recent change

Fixes https://github.com/harfbuzz/harfbuzz/issues/1300

5 years agoMinor
Behdad Esfahbod [Thu, 22 Nov 2018 06:25:34 +0000 (01:25 -0500)]
Minor

5 years agoMinor
Behdad Esfahbod [Thu, 22 Nov 2018 06:22:33 +0000 (01:22 -0500)]
Minor

5 years agoDisallow taking Null() of unbounded structs
Behdad Esfahbod [Thu, 22 Nov 2018 06:18:55 +0000 (01:18 -0500)]
Disallow taking Null() of unbounded structs

Not sure I've marked all such structs.  To be done as we discover.

Fixes https://github.com/harfbuzz/harfbuzz/issues/1300

5 years agoUse Type::null_size for our structs in Null(), sizeof() for other types
Behdad Esfahbod [Thu, 22 Nov 2018 06:10:22 +0000 (01:10 -0500)]
Use Type::null_size for our structs in Null(), sizeof() for other types

5 years agoOne more time..
Behdad Esfahbod [Thu, 22 Nov 2018 06:05:02 +0000 (01:05 -0500)]
One more time..

5 years agoFix bots happy again, hopefully
Behdad Esfahbod [Thu, 22 Nov 2018 05:39:14 +0000 (00:39 -0500)]
Fix bots happy again, hopefully

So, our fallback static_assert cannot be had more than once per line
of source.

5 years agoRevert alignof() == 1 check
Behdad Esfahbod [Thu, 22 Nov 2018 05:21:49 +0000 (00:21 -0500)]
Revert alignof() == 1 check

Bots not happy with using "this" inside assertion...

This reverts 2656644887e77a9d814bb12374af3c26b42fd935

5 years ago..
Behdad Esfahbod [Thu, 22 Nov 2018 04:46:09 +0000 (23:46 -0500)]
..

5 years agoMinor
Behdad Esfahbod [Thu, 22 Nov 2018 04:42:31 +0000 (23:42 -0500)]
Minor

5 years agoMinor
Behdad Esfahbod [Thu, 22 Nov 2018 04:30:50 +0000 (23:30 -0500)]
Minor

5 years agoMinor
Behdad Esfahbod [Thu, 22 Nov 2018 04:25:06 +0000 (23:25 -0500)]
Minor

5 years agoRemove DEFINE_SIZE_ARRAY2
Behdad Esfahbod [Thu, 22 Nov 2018 04:23:49 +0000 (23:23 -0500)]
Remove DEFINE_SIZE_ARRAY2

5 years agoCheck alignof() structs are 1
Behdad Esfahbod [Thu, 22 Nov 2018 04:23:21 +0000 (23:23 -0500)]
Check alignof() structs are 1

5 years agoWhitespace
Behdad Esfahbod [Thu, 22 Nov 2018 04:19:00 +0000 (23:19 -0500)]
Whitespace

5 years agoMerge pull request #1400 from harfbuzz/sharada-sandhi-mark
Behdad Esfahbod [Wed, 21 Nov 2018 22:27:27 +0000 (17:27 -0500)]
Merge pull request #1400 from harfbuzz/sharada-sandhi-mark

Test U+111C9 SHARADA SANDHI MARK

5 years agoTest U+111C9 SHARADA SANDHI MARK
David Corbett [Wed, 21 Nov 2018 21:33:45 +0000 (16:33 -0500)]
Test U+111C9 SHARADA SANDHI MARK

5 years agoMerge pull request #1399 from harfbuzz/sharada-sandhi-mark
Behdad Esfahbod [Wed, 21 Nov 2018 21:12:32 +0000 (16:12 -0500)]
Merge pull request #1399 from harfbuzz/sharada-sandhi-mark

Fix USE categories for U+111C9 SHARADA SANDHI MARK

5 years agoAllow defining HB_USE_ATEXIT to 0
Behdad Esfahbod [Wed, 21 Nov 2018 17:32:48 +0000 (12:32 -0500)]
Allow defining HB_USE_ATEXIT to 0

That's better use of that value than requiring extra macro HB_NO_ATEXIT

5 years agoFix USE categories for U+111C9 SHARADA SANDHI MARK
David Corbett [Wed, 21 Nov 2018 16:35:44 +0000 (11:35 -0500)]
Fix USE categories for U+111C9 SHARADA SANDHI MARK

5 years ago[var] Deprecated axis enumeration API and add new version
Behdad Esfahbod [Wed, 21 Nov 2018 01:40:55 +0000 (20:40 -0500)]
[var] Deprecated axis enumeration API and add new version

New version has axis flags.

New API:
+hb_ot_var_axis_info_t
+hb_ot_var_find_axis_info()
+hb_ot_var_get_axis_infos()

Deprecated API:
-HB_OT_VAR_NO_AXIS_INDEX
-hb_ot_var_axis_t
-hb_ot_var_find_axis()
-hb_ot_var_get_axes()

5 years agoRemove newly-added -hb_ot_var_axis_get_flags()
Behdad Esfahbod [Tue, 20 Nov 2018 16:42:25 +0000 (11:42 -0500)]
Remove newly-added -hb_ot_var_axis_get_flags()

5 years ago[var] Make sure hb_ot_var_axis_flags_t is int-sized
Behdad Esfahbod [Tue, 20 Nov 2018 16:40:43 +0000 (11:40 -0500)]
[var] Make sure hb_ot_var_axis_flags_t is int-sized

5 years ago[var] Move code
Behdad Esfahbod [Tue, 20 Nov 2018 16:33:33 +0000 (11:33 -0500)]
[var] Move code

5 years agoMerge pull request #1397 from harfbuzz/small-emoji-table
Behdad Esfahbod [Tue, 20 Nov 2018 21:29:30 +0000 (16:29 -0500)]
Merge pull request #1397 from harfbuzz/small-emoji-table

Shrink the emoji table by merging adjacent ranges

5 years agoShrink the emoji table by merging adjacent ranges
David Corbett [Tue, 20 Nov 2018 20:41:45 +0000 (15:41 -0500)]
Shrink the emoji table by merging adjacent ranges

5 years ago[var] Fix type of coords returned
Behdad Esfahbod [Tue, 20 Nov 2018 16:16:23 +0000 (11:16 -0500)]
[var] Fix type of coords returned

Ouch.  Wonder how none of the bots caught the float->int truncation.