Commit Graph

53 Commits

Author SHA1 Message Date
Ebrahim Byagowi ec17b62457
[var] Apply variations on empty glyphs
It was ignoring empty glyphs for no good reason, this fixes it.

Fixes #2618
2020-08-06 20:16:11 +04:30
Ebrahim Byagowi cb7fb3cf4a
Add test for a783840789 2020-06-28 13:41:33 +04:30
Khaled Hosny 2598855454 [tests] Add test for ReverseChainSingleSubstFormat1 missing substitute
https://github.com/harfbuzz/harfbuzz/issues/2467
2020-06-18 02:16:57 +02:00
Behdad Esfahbod b1167d19e9 Fix! 2019-12-05 15:46:58 +00:00
Behdad Esfahbod 5ff410b493 Add files, oops 2019-12-05 15:37:56 +00:00
Khaled Hosny da5118da77 [ot-shape] Enable abvm/blwm features by default
Core Text seems to apply them to Latin text, but Uniscribe doesn’t.

See https://github.com/harfbuzz/harfbuzz/pull/1908#issuecomment-521819343
2019-08-16 02:17:32 +02:00
Khaled Hosny 2164bd6f29
[ot-shape] Enable dist feature by default (#1908)
Fixes https://github.com/harfbuzz/harfbuzz/issues/1907
2019-08-16 00:28:41 +02:00
Khaled Hosny c9796d15e1 Fix sbix glyph extents
* The ‘height’ needs to be negated since the API returns “distance from
  top to bottom side”.
* Similarly, the ‘y_offset‘ needs to be added to the height to get the
  ‘y_bearing’, since sbix’s offset is “the point in the glyph relative
  to its lower-left corner which corresponds to the origin” while
  ‘y_bearing’ is the “top side of glyph from origin”.

With these changes the sbix glyph metrics return values similar to other
tables, as they were otherwise unusable.
2019-07-22 05:42:34 +02:00
David Corbett d64fb9db52 [use] Allow U+1A60 TAI THAM SIGN SAKOT after vowel 2019-05-27 13:14:03 -04:00
David Corbett 125c45ed36 Convert Consonant_Initial_Postfixed to CONS_MED 2019-05-15 14:34:25 -07:00
Behdad Esfahbod 21bb80ebf2 [indic] Add back medial-consonant to grammar
Fixes https://github.com/harfbuzz/harfbuzz/issues/1592
2019-03-28 20:50:04 -07:00
Behdad Esfahbod 5ab6de7a6f [khmer] Add trailing Coeng to syllable grammar
Fixes https://github.com/harfbuzz/harfbuzz/issues/1541
2019-03-28 20:23:12 -07:00
Behdad Esfahbod 9f31417733 Form cluster for Emoji sub-region tag sequences
Fixes https://github.com/harfbuzz/harfbuzz/issues/1556
2019-01-24 16:08:33 +01:00
Ebrahim Byagowi 5155067e10
[test] Add test for format2 kern (#1423) 2018-11-29 00:07:00 +03:30
Behdad Esfahbod 8280459e74
Merge pull request #1291 from harfbuzz/use-reordering
[use] Fix reordering
2018-11-22 22:39:12 -05:00
David Corbett 264439c6c3 Test U+111C9 SHARADA SANDHI MARK 2018-11-21 16:33:45 -05:00
David Corbett 3c7792ca32 [use] Fix reordering
Fixes #1235.
2018-11-19 16:49:40 -05:00
punchcutter e543e1a085 Add Grantha test 2018-11-13 20:44:27 -08:00
Behdad Esfahbod e3ceb2dde3 Fix again 2018-10-25 14:30:36 -07:00
Behdad Esfahbod 1cfe702872 Fixup 2018-10-25 13:37:08 -07:00
Behdad Esfahbod 5739c876d0 [test] Rename some fonts
If we have duplicae font files in different directories, that would
break the oss-fuzz build currently.  So, rename some to avoid
name class with text-rendering-test.  Would be better to find
another solution.
2018-10-25 13:23:33 -07:00
Behdad Esfahbod ba502dea1e [morx] Fix cluster-merging when ligating
Only merge when actual ligature happened.

Fixes https://github.com/harfbuzz/harfbuzz/issues/1305
2018-10-23 16:50:31 -07:00
David Corbett 205737acdc [use] Prohibit visually ambiguous vowel sequences 2018-10-23 02:25:08 -07:00
Behdad Esfahbod 48ed598a35 [VORG] Hook up to hb-ot-font's v_origin
Fixes https://github.com/harfbuzz/harfbuzz/issues/544

Test added with NotoSansCJK, eg. with U+FF38.
2018-10-23 02:21:27 -07:00
Khaled Hosny d4e928b142 [color] Minimal API for COLR/CPAL 2018-10-22 10:17:31 +02:00
Behdad Esfahbod 3676c685d4 [fuzzing] Move rest of fuzzing tests here 2018-10-16 16:32:26 -07:00
Behdad Esfahbod 1487173dcf [fuzzing] Delete duplicate fonts 2018-10-16 16:30:38 -07:00
Behdad Esfahbod bf8469be9a Attach CursivePositioning backwards, not forward
This is how Uniscribe does it.  So, adjust.  This is only relevant
to fonts that apply cursive positioning from a contextual lookup.

Fixes https://github.com/harfbuzz/harfbuzz/issues/1181
2018-10-11 20:45:40 -04:00
Behdad Esfahbod bdb53ca24a [myanmar] Implement Zawgyi shaper
Enabled if script tag 'Qaag' is passed to HarfBuzz.  Disables mark
advance-zeroing and fallback mark-positioning.

Fixes https://github.com/harfbuzz/harfbuzz/issues/1162
2018-10-11 20:20:29 -04:00
Behdad Esfahbod 788e147855 [test] Add test for USE indic3 2018-10-11 19:24:52 -04:00
David Corbett 65d01f7755 Test deprecated tag fallback in a font
The font supports the deprecated tag 'DHV ' instead of 'DIV '. dv is
mapped to 'DIV ' and 'DHV ', in that order. The test specifies
`--language=dv`, demonstrating that if a font does not support the first
OpenType tag mapped to a BCP 47 tag, it will fall back to the next tag.
2018-10-11 13:54:28 -04:00
Behdad Esfahbod 100e95f48e [trak] Add tests 2018-10-11 11:30:45 -04:00
Behdad Esfahbod 81f5eb09ec Add emoji test for recent work 2018-10-03 21:32:52 +02:00
Behdad Esfahbod 3f1c741b7a [test] Split a test 2018-10-03 21:11:40 +02:00
Behdad Esfahbod df32eaae42 [indic] Disallow vowel mark combinations that spoof other vowel marks
Fixes https://github.com/harfbuzz/harfbuzz/issues/1019

New numbers:

BENGALI: 353725 out of 354188 tests passed. 463 failed (0.130722%)
DEVANAGARI: 707261 out of 707394 tests passed. 133 failed (0.0188014%)
GUJARATI: 366353 out of 366457 tests passed. 104 failed (0.0283799%)
GURMUKHI: 60729 out of 60747 tests passed. 18 failed (0.0296311%)
KANNADA: 951300 out of 951913 tests passed. 613 failed (0.0643966%)
MALAYALAM: 1048136 out of 1048334 tests passed. 198 failed (0.0188871%)
ORIYA: 42327 out of 42329 tests passed. 2 failed (0.00472489%)
SINHALA: 271596 out of 271847 tests passed. 251 failed (0.0923313%)
TAMIL: 1091754 out of 1091754 tests passed. 0 failed (0%)
TELUGU: 970555 out of 970573 tests passed. 18 failed (0.00185457%)

Devanagari regressed because Uniscribe doesn't enforce the full set.

Tests added with the *-vowel-letters.txt files in tree and Noto fonts.
2018-10-03 15:53:28 +02:00
Behdad Esfahbod 75114e01d2 [use] Add Halant_Or_Vowel_Modifier category
Fixes https://github.com/harfbuzz/harfbuzz/issues/1102
2018-10-03 12:30:23 +02:00
Behdad Esfahbod 729f634728 Disable joiner-skipping when looking back for base to attach mark to
Fixes https://github.com/harfbuzz/harfbuzz/issues/1189
2018-10-02 14:41:31 +02:00
Behdad Esfahbod ab4c37f73a [khmer] Add mark-ordering tests
Fixes https://github.com/harfbuzz/harfbuzz/issues/667
2018-10-01 19:35:48 +02:00
Ebrahim Byagowi 2b2ed1e536 [dfont] Add test 2018-09-11 16:47:21 +02:00
David Corbett 2de96e8468 Test 'rand' 2018-09-11 10:47:59 +02:00
Behdad Esfahbod 92ba9905ca [indic] Allow double-halant in old-spec Devanagari
Fixes https://github.com/harfbuzz/harfbuzz/issues/1071
2018-07-31 15:19:32 -07:00
Behdad Esfahbod fe099a844b [test] Add Khmer tests, with NotoSansKhmer-Regular.ttf
Note that there's minor positioning differences, and ONE reordering
difference between what we get for these and what Uniscribe gets.
Probably same as what's described in commit message for
1a96cc825d
2018-07-31 14:20:31 -07:00
David Corbett 62fa7cd1cc Order Chakma split vowels in accordance with NFC
Fixes #1105.
2018-07-22 19:47:21 -07:00
Behdad Esfahbod 9940504e93 [indic] Adjust left-matra repositioning and Halant,ZWJ sequence
From the new code (first paragraph is from the OT Devanagari spec.):

  /*   o Reorder matras:
   *
   *     If a pre-base matra character had been reordered before applying basic
   *     features, the glyph can be moved closer to the main consonant based on
   *     whether half-forms had been formed. Actual position for the matra is
   *     defined as “after last standalone halant glyph, after initial matra
   *     position and before the main consonant”. If ZWJ or ZWNJ follow this
   *     halant, position is moved after it.
   *
   * IMPLEMENTATION NOTES:
   *
   * It looks like the last sentence is wrong.  Testing, with Windows 7 Uniscribe
   * and Devanagari shows that the behavior is best described as:
   *
   * "If ZWJ follows this halant, matra is NOT repositioned after this halant.
   *  If ZWNJ follows this halant, position is moved after it."
   *
   * Test case, with Adobe Devanagari or Nirmala UI:
   *
   *   U+091F,U+094D,U+200C,U+092F,U+093F
   *   (Matra moves to the middle, after ZWNJ.)
   *
   *   U+091F,U+094D,U+200D,U+092F,U+093F
   *   (Matra does NOT move, stays to the left.)

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

Test case added with Adobe Devanagari.
2018-07-03 14:34:38 +04:30
Behdad Esfahbod 4a115fe7fe [sinhala] Move reph to after post-consonants
Apparently this changed between Win 7 and Win 10.

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

To be continued in https://github.com/harfbuzz/harfbuzz/issues/1044
2018-06-04 15:40:43 -07:00
Behdad Esfahbod f673cfbd64 Support scripts that are written both LTR and RTL
Right now only Old Italic is marked as such.

Fixes https://github.com/harfbuzz/harfbuzz/issues/1000
2018-05-07 14:12:17 -07:00
Ebrahim Byagowi 9925030f19 Don't decompose Bengali Rra and Rha
Fixes #779 and follow up to b01d9b3d90
2018-04-26 13:54:09 -07:00
Behdad Esfahbod bcf578fefe [test] Add test suite for Brahmi Number Joiners
https://github.com/harfbuzz/harfbuzz/pull/660
2018-02-28 16:31:46 -08:00
Ebrahim Byagowi 5b9c234043 [CPAL] Refactor and address the reviews 2018-02-28 11:25:29 +03:30
Behdad Esfahbod e2d2d81984 Limit how much work sanitize() can do
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=6022
2018-02-18 17:28:53 -08:00