Behdad Esfahbod
7cbcdaf68a
Whitespace
2021-07-30 11:26:46 -06:00
Behdad Esfahbod
5d283aa0bd
Merge pull request #3095 from harfbuzz/subset-tests-speed
...
[test] Speed-up subset tests by saving TTX dump
2021-07-30 10:15:09 -06:00
Garret Rieger
f9d8e4a976
[subset] switch ..._set_flags to not take a mask.
2021-07-29 18:30:27 -07:00
Garret Rieger
3d534b146c
[subset] convert subset input flags into bit flags.
...
Store the flags in a bit set. Updates the public api to work with the bit set directly.
2021-07-29 18:02:34 -07:00
Khaled Hosny
f6c67a5fcf
[test] Open file in UTF-8
...
It is 2021 and Python still does not default to UTF-8 on Windows!
2021-07-30 02:20:19 +02:00
Khaled Hosny
bafbade087
[test] Force FontTools to use \n on all platforms
...
On Windows in helfuly uses \r\n.
2021-07-30 01:42:45 +02:00
Khaled Hosny
278f44dcee
[test] Speed-up subset tests by saving TTX dump
...
Speed-up subset tests by saving TTX dump of expected output instead of
generating it each time the tests are run.
Cuts down meson test --suite=subset on my system from:
real 0m38.977s
user 1m12.024s
sys 0m10.547s
to:
real 0m22.291s
user 0m44.548s
sys 0m9.221s
Part of https://github.com/harfbuzz/harfbuzz/issues/3089
2021-07-30 00:00:35 +02:00
Khaled Hosny
72489f3e0e
[test] Free memory in hb-aots-tester
2021-07-29 10:42:23 -06:00
Khaled Hosny
895162d6f3
[test] Account for mark zeroing in AOTS tests
...
The AOTS are not written with the face that mark glyphs gets their
advances zeroed. Taking this into account makes 16 more tests to pass.
2021-07-29 10:42:23 -06:00
Khaled Hosny
e65bf60500
[test] make this test runner less verbose
...
Print the command being called once and in a way the can be manually
run.
2021-07-29 10:42:23 -06:00
Khaled Hosny
9a7ff54bb7
[test] Write one sequence per-line
...
https://github.com/harfbuzz/harfbuzz/pull/3087#issuecomment-888691436
2021-07-28 18:25:51 -06:00
Khaled Hosny
ddf87ffb22
[test] Add generated tests for emoji clusters
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/3017
Uses AdobeBlank2.ttf from:
https://github.com/adobe-fonts/adobe-blank-2
instead of a dummy empty font so that everything maps to GID 1 and
control code points are kept instead of being dropped because there is
not space glyph (otherwise we’d need to identify control code points
somehow when generating the expectations).
2021-07-28 18:25:51 -06:00
Behdad Esfahbod
6fe0d7d6e8
[GSUB] If MultipleSubst is applied to a ligature-component, preserve lig-id
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/3069
2021-07-28 12:06:49 -06:00
Garret Rieger
acbd8b27dc
[subset] temporarily disable COLRv1 subsetting.
...
Currently COLRv1 spec is being changed so the subsetting implementation is out of sync. Disable subsetting by failing sanitization for COLRv1 tables and disable all colrv1 tests.
2021-07-28 11:36:34 -06:00
Behdad Esfahbod
0ded6a70c8
[subset] Fix another fuzzer issue
...
Addition could overflow on 32bit arch.
Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=36636
Fixes https://oss-fuzz.com/testcase-detail/5072358514753536
2021-07-28 11:35:27 -06:00
Khaled Hosny
c65e1e0842
[test] Run AOTS cmap tests with ot font functions only
...
We are not interested in testing FreeType cmap support.
Fixes most format 4 tests. The remaining test seems to be peculiar, and
I can’t find any cmap implementation that produces the expected output.
2021-07-28 11:35:09 -06:00
Khaled Hosny
8396c523b6
[test] Add AOTS cmap tests
...
Uses https://github.com/adobe-type-tools/aots/pull/3
Related to https://github.com/unicode-org/text-rendering-tests/issues/70
We don’t support format 4 or 8, so these tests are disabled. We support
format 4 but most of the tests are failing, investigating.
2021-07-28 11:35:09 -06:00
Khaled Hosny
50379fbb15
[util] Don’t split text at new lines in batch mode
...
In batch mode (which is used for testing) we are probably not interested
in splitting text into lines as we could have split the string into
different tests. This fixes a bunch of AOTS tests that use newlines as
input.
2021-07-28 11:35:09 -06:00
Khaled Hosny
92b85749f2
[util] Strip quotes when parsing features
...
When running in batch mode, the quotes are not stripped by the shell and
end up in the feature string. This breaks one of the AOTS tests.
Alternatively, we can remove the quotes from the test files, not sure
which is less hacky, though!
2021-07-28 11:35:09 -06:00
Khaled Hosny
ad9559e3e2
[tests] Make AOTS update.py work on macOS
...
Use C++ compiler and make sure C++11 is used.
2021-07-28 14:35:23 +02:00
Khaled Hosny
d84efca312
[tests] Add missed test file to Makefile/meson
...
It was introduced in 205737acdc
but was
not actually used.
See https://github.com/harfbuzz/harfbuzz/issues/2098
2021-07-28 13:39:15 +02:00
Garret Rieger
09474d8d7b
[subset] Fix fuzzer timeout in add_gid_and_children.
...
The composite glyph graph isn't check for max operations by sanitize so track an operations count during the graph traversal.
2021-07-27 13:30:06 -06:00
Behdad Esfahbod
c68a00b92e
[subset] Fix possible overflows in VarRegionList serialize
...
Fixes https://oss-fuzz.com/testcase-detail/5362189182566400
2021-07-27 13:28:09 -06:00
Behdad Esfahbod
4762fcb415
Merge pull request #3067 from googlefonts/glyph_names
...
[subset] support option --glyph-names
2021-07-26 11:48:55 -07:00
Behdad Esfahbod
aeec278453
Merge pull request #3068 from harfbuzz/hoi
...
[variations] Support multiple axes with same tag, aka HOI
2021-07-26 11:31:54 -07:00
Qunxin Liu
71b5509c19
[subset] support option --glyph-names
2021-07-23 13:57:39 -07:00
Behdad Esfahbod
b235511ed8
Merge pull request #3021 from googlefonts/stable_api
...
[subset] update hb_subset api with final changes before going stable.
2021-07-23 12:15:15 -07:00
Behdad Esfahbod
a9a607d360
[variations] Support multiple axes with same tag, aka HOI
...
The axes in fvar are in arbitrary order, NOT sorted. Hence have to
lsearch all entries.
Fixes https://github.com/harfbuzz/harfbuzz/issues/1673
Fixes https://github.com/harfbuzz/harfbuzz/issues/2743
Test from https://github.com/ctrlcctrlv/FontForge-Higher-Order-Interpolation
2021-07-23 11:58:58 -07:00
Garret Rieger
9ab751ac9f
[subset] Remove hb_subset(). Leaving just hb_subset_or_fail().
2021-07-22 12:14:47 -07:00
Garret Rieger
aba2e13141
[subset] Remove hb_subset_input_get/set_overlaps_flag ().
2021-07-22 12:12:36 -07:00
Garret Rieger
7d82191f61
[subset] Remove hb_subset_input_get/set_name_legacy ().
2021-07-22 12:12:36 -07:00
Garret Rieger
942636ae13
[subset] Remove hb_subset_input_get/set_retain_gids.
2021-07-22 12:12:36 -07:00
Garret Rieger
77b4a1cd96
[subset] Remove hb_subset_input_get/set_desubroutinize.
2021-07-22 12:12:36 -07:00
Garret Rieger
8bf5d4d4f7
[subset] Remove hb_subset_input_get/set_drop_hints.
2021-07-22 12:12:36 -07:00
Behdad Esfahbod
79e8b30609
[ot-shape] Fix application of kern table if GPOS kern is missing
...
Was broken sometime after we implemented kerx and tweaking it.
Fixes https://github.com/harfbuzz/harfbuzz/issues/3043
2021-07-16 16:29:44 -06:00
Garret Rieger
deee24fbef
[subset] Add missing FontName op code in top dict parsing.
...
Fix for #3058
2021-07-14 16:01:18 -06:00
Qunxin Liu
7416faceeb
[subset] fuzzer fix: https://oss-fuzz.com/testcase-detail/5715464591376384
2021-07-08 09:09:30 -07:00
Garret Rieger
0da9158f62
[subset] Remove OffsetTo::serialize().
...
Convert remaining uses of it to serialize_serialize() which correctly uses the object packer.
2021-06-30 14:05:48 -07:00
Qunxin Liu
eee7b459ee
[subset] add option --no-prune-unicode-ranges
2021-06-24 11:44:20 -07:00
Khaled Hosny
c3be28ea26
[ot-shape] Numeric runs native direction is LTR
...
See inline comments. Slightly modified version of the code from Jonathan
Kew on the linked issue.
Fixes https://github.com/harfbuzz/harfbuzz/issues/501
2021-06-23 13:11:27 -07:00
Khaled Hosny
71a6296620
[tests] Make record-test.sh work with .otf files
...
It hard-codes the file extension, but fonttools sunset will use .otf for
CFF fonts, so hard-code the output file from subset as well.
2021-06-23 13:11:27 -07:00
Garret Rieger
bc06af977f
[subset] speed up feature collection when tags are specified.
...
Precompute a feature index filter to avoid needing to iterate the feature tag list for each encountered feature index. For this particular fuzzer case speeds up feature collection from 50s to 2s.
2021-06-20 17:45:19 -07:00
Garret Rieger
d2397d91f3
[subset] Add additional colrv1 subsetting tests that has a glyph with components.
2021-06-18 22:34:00 -07:00
Qunxin Liu
d07f789ae3
[subset] support option "--notdef-outline"
2021-06-18 15:35:02 -07:00
Garret Rieger
675ebbeb3a
[subset] don't alloc zero bytes.
...
It will be leaked later since hb_blob_create() won't set up the blob to cleanup since it has length zero.
2021-06-16 17:35:39 -06:00
Behdad Esfahbod
bdfed8f113
[blob] Add failing versions of create API
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/2567
New API:
+hb_blob_create_or_fail()
+hb_blob_create_from_file_or_fail()
Use these in util/ to distinguish empty file from not-found file.
Only err on the latter.
2021-06-15 13:56:30 -06:00
Behdad Esfahbod
5bc05ba155
Prefer GPOS over kerx, if GSUB was applied
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/3008
2021-06-13 05:28:20 -06:00
David Corbett
5585ea02eb
[syllabic] Set position of dotted circle for Indic
2021-06-06 10:35:59 -07:00
Qunxin Liu
35d6af6943
[subset] fix fuzzer testcase: https://oss-fuzz.com/testcase-detail/5965777994907648
2021-06-04 18:16:23 -06:00
Qunxin Liu
1b6008ca62
fix fuzzer testcase: https://oss-fuzz.com/testcase-detail/5417934246772736
2021-06-02 17:32:16 -06:00
Qunxin Liu
7ab0f4eda9
fuzzer fix
2021-05-31 12:44:33 -06:00
Qunxin Liu
cb5a6b5a27
[subset] support option --layout-features
2021-05-26 18:04:18 -06:00
Garret Rieger
0989b5553a
[subset] Add test for overlaps flag setting.
2021-05-26 16:04:56 -06:00
Qunxin Liu
f739e1dc6a
[subset] subset both CPAL and COLRv1
2021-05-26 15:39:42 -06:00
Kurt Kartaltepe
2000f47ae5
[set] Compute is_subset by comparing pages.
...
Test subsets one page at a time instead of by codepoints. On my machine
this is about 250x faster than the previous implementation.
2021-05-26 14:15:25 -06:00
Jonathan Kew
89df353996
[aat] Add testcase for Apple Color Emoji couple-with-skin-tones sequence.
2021-05-17 21:44:29 -06:00
Garret Rieger
a08900b721
[subset] fix failing colrv0 subsetting when font has composite glyphs.
...
Composite glyph collection was happening along side colrv0 glyph collection which meant it was possible to miss grabbing the component glyphs for a glyph added by colrv0.
2021-05-10 15:33:54 -06:00
Garret Rieger
b07b97d5d7
[subset] Add more Noto Nastaliq test cases.
2021-05-06 14:24:45 -06:00
Garret Rieger
2b7647649a
[subset] update test-subset-gpos expected files.
2021-04-30 14:46:57 -06:00
Garret Rieger
92757f6809
[subset] Don't drop anchor device tables when dropping hints. These may contain variation data.
...
Update subseting expected files to match latest version of fontTools.
2021-04-23 18:50:33 -07:00
Garret Rieger
6fddc2bbf9
[subset] subset layout tables (G*) by default.
2021-04-22 15:08:49 -07:00
Garret Rieger
425ba1f4ab
[subset] fixes infinite loop in hb_set_get_max().
...
Fixes https://oss-fuzz.com/testcase-detail/5363902507515904
2021-04-20 13:18:07 -06:00
Garret Rieger
ec4321068b
[subset] fix infinite loop caused by alloc failure in repacker.
...
Fixes: https://oss-fuzz.com/testcase-detail/5609112151916544 .
2021-04-20 13:18:07 -06:00
Garret Rieger
0e845d973e
[subset] fix memory leak in repacker caused by failed alloc.
...
Fixes: https://oss-fuzz.com/testcase-detail/5616763250278400 .
2021-04-20 13:18:07 -06:00
Garret Rieger
3fb62cdc14
[subset] fail on offset overflow in tables that we don't repack.
...
Fixes: https://oss-fuzz.com/testcase-detail/5229304507138048
2021-04-19 17:01:05 -06:00
Behdad Esfahbod
47cbf8f2c4
[test] Silence more compiler warnings
2021-04-16 13:32:02 -06:00
Qunxin Liu
9dc9f0385d
[subset] fix for fuzzer testcase: https://oss-fuzz.com/testcase-detail/5858518134554624
2021-04-09 11:07:28 -06:00
Qunxin Liu
4af5dacedc
[subset] add fuzzer testcase
2021-04-07 13:02:04 -06:00
Garret Rieger
64122b5a44
[subset] don't visit lookup if covered glyph set has failed.
...
If covered glyph set is in error then the same lookup can be recursed into repeatedly potentially causing a fuzzer timeout. Fixes: https://oss-fuzz.com/testcase-detail/5416421032067072 .
2021-04-06 12:34:44 -06:00
Garret Rieger
4ec18c85e6
[subset] add subsetting tests with drop hints and layout subsetting enabled.
2021-04-06 11:50:44 -06:00
Garret Rieger
71d6d15600
[subset] clamp distance to prevent shifting outside of the limits of int64.
...
Fixes https://oss-fuzz.com/testcase-detail/4961171477233664 .
2021-04-06 11:48:39 -06:00
Garret Rieger
596f4258d0
[subset] copy Lookup::markFilteringSet when subseting.
2021-04-02 15:33:52 -06:00
Garret Rieger
c35d786397
[subset] never drop the 'pref' feature.
...
Never ever drop feature 'pref', even if it's empty. Harfbuzz uses it to choose the shaper for Khmer.
2021-04-01 16:27:35 -06:00
Garret Rieger
85b0728783
Add full variable font subsetting test.
2021-04-01 15:26:02 -06:00
Garret Rieger
b10741ca7f
[subset] when closing glyphs in context lookups don't use a current glyph set if a lookup is already applied.
2021-03-31 21:03:33 -06:00
Garret Rieger
2773d05740
[subset] Add a test case using NotoNastaliqUrdu.
2021-03-31 21:03:33 -06:00
Garret Rieger
c5c13006a1
[subset] fix memory leaks found in https://oss-fuzz.com/testcase-detail/5179935334465536
2021-03-31 12:37:45 -06:00
Garret Rieger
adca4ce071
[subset] fixes https://oss-fuzz.com/testcase-detail/6173520787800064 .
...
Caused by incorrect bounds check in glyph closure for context lookups.
2021-03-30 15:44:41 -06:00
Garret Rieger
752e393ad2
[subset] avoid calling clear on null pool set.
2021-03-30 15:12:52 -06:00
Garret Rieger
8741914a80
[subset] fix memory leak when map insert fails.
2021-03-29 18:02:32 -06:00
Garret Rieger
5b6da6d2f0
[subset] add fuzzer test case.
2021-03-29 17:41:07 -06:00
Garret Rieger
a804a0c903
[subset] add fuzzer test case.
2021-03-29 17:15:22 -06:00
Qunxin Liu
95230e291d
[subset] support subsetting GSUB8
2021-03-29 15:54:11 -06:00
Garret Rieger
0104409959
Fix repack_tests for distcheck.
2021-03-17 15:53:58 -07:00
Garret Rieger
b8b8c58b9f
[subset] add tests that check for successful repacking of a real font file.
2021-03-17 15:53:58 -07:00
Qunxin Liu
56ca435787
[subset] fix for collect_features and remove_redundant_lamngsys
...
previously remove_redundant_sys () is missing in harfbuzz, after
redundant langsys removal, some features are removed as well in
prune_features() in fonttools. This change is trying to get the same
result between harfbuzz and fonttools.
2021-03-17 14:24:04 -07:00
Garret Rieger
69d772e522
[subset] Fixed test gsub5 test files.
2021-03-17 15:22:07 -06:00
Qunxin Liu
0e1c0fa404
[subset] optimize glyph closure method: step 5
...
add testcase and some fixes
2021-03-17 15:22:07 -06:00
Garret Rieger
1b79b8cd2d
[subset] update gpos tests to reflect updated behaviour.
2021-03-16 15:23:11 -07:00
Garret Rieger
b1b1486d07
[subset] update expected files to not include cmap12 pruning.
2021-03-16 14:49:35 -07:00
Garret Rieger
190b7a98f8
[subset] Update PairPosFormat2 subsetting to match fontTools updated subsetting ( https://github.com/fonttools/fonttools/pull/2221 )
...
- subset class def 1 against the coverage table.
- Don't re-use class 0 in class def 2.
- Ignore class 0 glyphs for the purposes of determing format 1 vs format 2 encoding for ClassDef.
Add an additional test case which demonstrates these issues.
2021-03-16 14:49:35 -07:00
Khaled Hosny
4c34478b28
Merge pull request #2899 from harfbuzz/ci-fix
...
[ci] Don’t install meson from its master branch
2021-03-16 10:37:49 +02:00
Khaled Hosny
f2d08578e7
[tests] Increase shape-fuzzer timeout
2021-03-16 01:15:40 +02:00
Behdad Esfahbod
15f3ef0136
[test] Fix output format
2021-03-15 16:01:35 -06:00
Khaled Hosny
7686ff854b
[ot] Keep substituted Default_Ignorables ( #2886 )
...
Don’t replace Default_Ignorables with zero-width space if they are
substituted or multiplied, not just when ligated.
After this change, HarfBuzz output matches that of Uniscribe and
CoreText for the new tests.
Fixes https://github.com/harfbuzz/harfbuzz/issues/2883
2021-03-04 13:09:32 -08:00
Behdad Esfahbod
fd489433a8
[indic] Fix cluster-merging logic with cluster-level=1
...
Was producing non-monotonic cluster numbers because our faulty logic
was not merging clusters if something from before base and after base
had switched positions.
Fixes https://github.com/harfbuzz/harfbuzz/issues/2272
2021-03-02 16:30:09 -07:00
Behdad Esfahbod
1c693e8c28
[test] Fix unused-var warning
2021-02-22 17:11:36 -07:00
justvanrossum
1551f3d518
fixing more expected test results
2021-02-19 16:53:21 -07:00
justvanrossum
79e4f436e7
Apply rounding correctly when calculating glyph extents for CFF and CFF2; adjust expected test results
2021-02-19 16:53:21 -07:00
justvanrossum
d01ebeae21
calculate extents based on scaled then rounded values; undo two of the earlier test result adjustments
2021-02-19 16:53:21 -07:00
justvanrossum
1d02e9c63b
two more adjusted expected extents results (still not convinced this is the right thing, though)
2021-02-19 16:53:21 -07:00
justvanrossum
cd0babe6a6
adjust expected test result
2021-02-19 16:53:21 -07:00
Behdad Esfahbod
d8ea552d10
[aat] Improve unsafe-to-break logic
...
Reduces false-positives. See comments for new logic.
Fixes https://github.com/harfbuzz/harfbuzz/issues/2860
Adjusts run-tests.sh to allow unhashed absolute filenames.
2021-02-19 16:23:22 -07:00
Garret Rieger
5ca353a2d0
[subset] fix heap buffer overflow found by fuzzer.
2021-02-16 12:43:02 -07:00
David Corbett
751ed68fee
[indic] Fix shaping of U+0B55 ORIYA SIGN OVERLINE
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/2849
2021-02-14 12:47:34 -05:00
Garret Rieger
00d9276343
Add gpos9 expected files to Makefile.am
2021-02-11 13:41:31 -07:00
Garret Rieger
08a4997fde
[subset] Add subset support for Extension lookups (GPOS 9, GSUB 7).
2021-02-11 13:41:31 -07:00
Behdad Esfahbod
eb069f3948
[tests] Update expected output of recently-merged gpos5
...
The merged PR was from before landing this:
commit 7a72b20aa2
Author: Garret Rieger <grieger@google.com>
Date: Thu Sep 24 15:58:48 2020 -0700
[subset] Subset GDEF during layout subsetting tests.
2021-02-10 19:13:51 -07:00
Behdad Esfahbod
c7d232ce4e
Merge pull request #2701 from googlefonts/Mark-To-Ligature_grieger
...
[subset] GPOS 5 MarkToLigature subsetting support
2021-02-10 18:13:38 -07:00
Khaled Hosny
554aaa0c5d
[build] Fix make distcheck
...
A regression from 7b77ce0507
.
It was caught by the CI build in the PR, but apparently we are now used
to CI failures that they are effectively ignored.
Also, yay for multiple build systems.
2021-02-10 23:22:02 +02:00
Behdad Esfahbod
6a3fd94f3b
Merge pull request #2699 from googlefonts/gpos_8
...
[subset] Add a more complex layout subsetting test case and fix the issues it exposed.
2021-02-09 20:49:04 -05:00
Behdad Esfahbod
33a0f0b686
[test] Remove fuzzed test font that triggers virus alert
...
Fixes https://github.com/harfbuzz/harfbuzz/issues/2750
2021-02-09 12:55:45 -07:00
Garret Rieger
f94bf9f06f
[set fuzzer] limit the total number of set members in a fuzzing input.
...
Currently the fuzzer can create arbitarily long inputs which once big enough will trigger a timeout.
2021-01-26 10:22:07 -08:00
Garret Rieger
a4c3732f59
[ENOMEM] fix set clear() causing corruption if the set is in_error().
2021-01-21 12:12:05 -07:00
David Corbett
b2e7bb2a7c
Don’t map BCP 47 to coincidentally similar OT tag
2020-11-22 19:35:47 -08:00
David Corbett
17da41bd06
Update language system tag registry to OT 1.8.4
2020-11-18 11:13:35 -08:00
Khaled Hosny
c2cdcd4901
[tests] warning: unused variable 'num_glyphs'
2020-10-17 21:57:27 +02:00
David Corbett
0792690b73
[use] Skip WJ and ZWJ when clustering
2020-10-16 22:39:46 -07:00
Khaled Hosny
84dd65a874
[test] Remove timeout from test runners
...
See https://github.com/harfbuzz/harfbuzz/issues/2707#issuecomment-707744079
This wasn’t inconsistent as well, HB_TEST_SUBSET_FUZZER_TIMEOUT defaulted
to 12 in the test runner, but it was overridden to 50 in meson.build,
and then meson has its own test timeout.
2020-10-15 00:49:02 -07:00
Khaled Hosny
fa771a7f85
[tests] Fix memory leak in test
...
To make valgrind bot happy.
2020-10-11 13:15:39 -07:00
David Corbett
1d53268dfe
Fix two-way mapping of "man" and 'MNK '
2020-10-11 11:38:40 -07:00
Behdad Esfahbod
540d2cdddb
[tests/buffer] Revert unintended whitespace changes
...
From 9e5538d6a3
Tried squashing into, but too much merge conflict.
2020-10-09 22:27:55 -06:00
Behdad Esfahbod
04658ec48f
[tests/buffer] Update tests for previous commit
2020-10-09 22:27:55 -06:00
Simon Cozens
7c0bc0bb92
Serialize invalid buffer to !! (text) or [] (json)
...
There is no generic deserialize - you have to choose glyphs or unicode - so there is no way to deserialize this buffer.
2020-10-09 22:27:55 -06:00
Simon Cozens
150f391438
Prohibit mixed glyphs/unicode buffers in deserialization
2020-10-09 22:27:55 -06:00
Simon Cozens
3d3c87e7e7
Put the flags back in and serialize clusters.
...
Note that now JSON glyph buffers and Unicode buffers look very similar, except for the g/u property difference.
2020-10-09 22:27:55 -06:00
Simon Cozens
432a05b2af
(Simple) tests for Unicode serialization/deserialization
2020-10-09 22:27:55 -06:00
Garret Rieger
be33704c00
Add gpos 5 tests to meson build file.
2020-10-09 16:46:46 -07:00
Qunxin Liu
3a0b05faf1
[subset] GPOS 5 MarkToLigature subsetting support
2020-10-01 15:59:16 -07:00
Garret Rieger
010accb3d5
[subset] Add additional test cases for the Amiri tests.
2020-09-28 17:39:09 -07:00
Garret Rieger
3271a7cdaa
[subset] Remove redundant langys from Amiri test font.
...
FontTools removes these when subsetting but harfbuzz does not yet support redundant langsys removal. So this gets the Amiri tests passing for now.
2020-09-28 16:46:15 -07:00
Garret Rieger
9fad540245
[subset] check that sub rules in ContextFormat 1 and 2 intersect the glyphs set before recursing during closure lookups.
2020-09-28 13:24:25 -07:00
Garret Rieger
7b77ce0507
[subset] Add subsetting integration test using Amiri.
...
Demonstrates a failure in subsetting GPOS 8/GSUB 6.
2020-09-24 16:35:59 -07:00
Garret Rieger
7a72b20aa2
[subset] Subset GDEF during layout subsetting tests.
2020-09-24 15:58:48 -07:00
ebraminio
1f8b1e7f18
[ENOMEM] Return gracefully if stages isn't initialized correctly ( #2639 )
...
This happens if calls to 'm.lookups[table_index].push ()' has been
silently failed due to lack of memory.
This change just returns gracefully instead issuing the assert.
Fixes https://crbug.com/oss-fuzz/24494
2020-09-21 11:39:38 +03:30
Garret Rieger
bbbcad0dbb
Revert "[ENOMEM] don't perform set process operations if the other set is in an error state."
...
This reverts commit f3929abafe
.
2020-09-16 12:23:38 -06:00
Garret Rieger
f3929abafe
[ENOMEM] don't perform set process operations if the other set is in an error state.
...
Running a process while the other set is in an error state can potentially corrupt this sets map map (for example by overwritting all of the major values with 0).
2020-09-16 10:36:30 -07:00
Simon Cozens
584d3a43b2
Merge pull request #2681 from khaledhosny/myanmar-liga
...
[myanmar] Don’t disable liga feature
2020-09-16 15:08:50 +01:00
Khaled Hosny
7d64b09765
[myanmar] Don’t disable liga feature
...
This seems to have been carried over from the Indic shaper, but
Uniscribe enables it by default.
See https://github.com/harfbuzz/harfbuzz/issues/2213#issuecomment-686062915
2020-09-12 21:45:19 +02:00
Garret Rieger
8c3d4de796
[subset] Fix integer underflow in ContextFormat2.
2020-09-11 15:52:46 -07:00
David Corbett
91fe20f0f5
Disambiguate OT tags when primary tag is not first
2020-09-08 09:20:00 -04:00
David Corbett
e3db84a9d0
[use] Test CGJ and ZWNJ
2020-09-02 15:51:15 -07:00
Garret Rieger
9825e3dd2e
[ENOMEM] fix access to unitialized memory.
...
If the serialize() call fails to write the object then we can't safely read varstore_prime fields. Fixes https://oss-fuzz.com/testcase-detail/5137462782066688 .
2020-09-02 11:01:07 -07:00
David Corbett
420a74f772
[USE] Fix assertion failure for joining scripts
2020-08-28 14:11:48 -04:00
ebraminio
1e48225ca3
[ENOMEM] Check whether serialize context isn't in error
2020-08-13 23:22:14 +04:30
Ebrahim Byagowi
6e32145dc9
[meson] Make compatbile with 0.47.0
2020-08-13 18:28:42 +04:30
Garret Rieger
9562239f05
[ENOMEM] check for error in lookup visited set.
2020-08-13 01:43:11 +04:30
Garret Rieger
6f754852c1
[ENOMEM] skip asserts in to_bias if serializer is in an error state.
2020-08-12 11:25:30 +04:30
Ebrahim Byagowi
057769b1a3
[fuzzer] minor
2020-08-12 02:40:55 +04:30
Ebrahim Byagowi
0417938011
[fuzzer] Mark alloc_state as unused
...
It is really unused when failing-alloc isn't on.
2020-08-12 02:40:55 +04:30