Commit Graph

138 Commits

Author SHA1 Message Date
Qunxin Liu b33a0d628e fuzzer crash fix: Null-dereference WRITE
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=18363
2019-10-22 01:01:08 +03:30
Qunxin Liu b66094ada0 [subset] GSUB Lookup Type 6: ChainContextSubst 2019-10-18 16:52:55 -07:00
Garret Rieger eff91bbb4b Add missing pop() for the failure case of script subsetting. 2019-10-18 15:10:30 -07:00
Garret Rieger 831daf4c76 Enforce HB_MAX_LANGSYS limit during layout subsetting. 2019-10-18 15:10:30 -07:00
Garret Rieger 9871461bce Enforce HB_MAX_SCRIPTS during subsetting of the script table. 2019-10-18 15:10:30 -07:00
Garret Rieger 36f18cecbb Add subset_offset_array helper function which simplifies subsetting offset arrays during stream operations. 2019-10-09 13:52:04 -07:00
Ebrahim Byagowi 0558413f27 Minor, tweak spaces 2019-10-01 13:50:11 +03:30
Behdad Esfahbod faace9437e
Merge pull request #1807 from harfbuzz/subset-varstore
VariationStore serializer
2019-09-30 13:34:05 -07:00
Qunxin Liu b0c3eb06b6 [subset] GPOS Lookup Type 3: CursivePos 2019-09-25 05:43:25 +09:00
Ebrahim Byagowi d512087e4d Rename GlyphID to HBGlyphID
Avoid collision with macOS's ATSUnicodeTypes.h GlyphID
2019-09-14 11:55:53 +04:30
Behdad Esfahbod 0e294c455e Rename VAR to HB_VAR_ARRAY 2019-09-06 16:54:27 -04:00
Behdad Esfahbod c379faed2b Fix a few struct size declarations
Was wrong.  As excercised by defining VAR to other than 1 in hb.hh.
2019-09-06 16:41:12 -04:00
qxliu76 0313ef86e3 bug fix in optimizing coverage table format (#1942)
We are comparing number of shorts, NOT number of bytes.
2019-08-29 14:09:05 -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
blueshade7 68ac767e43 added skip(), get_next_value() to inc_bimap to subset VarStore with retain-gids 2019-07-12 23:02:29 -07:00
blueshade7 634390ecaf added VariationStore serializer to be used by HVAR/VVAR subsetters 2019-07-01 18:52:57 -07:00
Behdad Esfahbod 6c725c7799 [config] Add HB_NO_LAYOUT_FEATURE_PARAMS
Part of https://github.com/harfbuzz/harfbuzz/issues/1652
2019-06-19 20:12:25 -07:00
Behdad Esfahbod c8f529a07e [config] Add HB_NO_HINTING, enabled by HB_TINY
Disables HintingDevice tables and Anchors addressing contour points.

Part of https://github.com/harfbuzz/harfbuzz/issues/1652
2019-06-19 19:33: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 1834cf86d4 [serialize] Pass offset to serialize_subset() 2019-05-31 14:39:32 -07:00
Behdad Esfahbod 9260441624 [serialize] Pass offset to serialize_copy() 2019-05-31 14:35:01 -07:00
Garret Rieger 962f95cf80 [subset] Switch SingleSubst to use iterators in serialize. 2019-05-15 18:37:32 -07:00
Behdad Esfahbod 889dc1eb06 [iter] Remove sort categorization
See comments.
2019-05-14 22:28:07 -07:00
Behdad Esfahbod 513762849a [iter] Track strictly-sorted iterators
This make output of hb_enumerate() sorted regardless of input iterator.
2019-05-13 15:36:14 -07:00
Behdad Esfahbod a487fc3324 Another extra semi-colon 2019-05-13 14:16:33 -07:00
Behdad Esfahbod 4d67743ffd [subset] Use more auto typing 2019-05-10 18:43:48 -07:00
Behdad Esfahbod a27a31b9ee Minor 2019-05-10 18:43:48 -07:00
Behdad Esfahbod 2ade008628 [serialize] More rewrite 2019-05-10 18:43:48 -07:00
Behdad Esfahbod 99ed6e29d8 [serialize] Fix a TODO 2019-05-10 18:43:48 -07:00
Behdad Esfahbod 25a5b287f2 Fix sanitize fail of extension sublookups
Fixes https://bugs.chromium.org/p/chromium/issues/detail?id=960331
2019-05-10 16:03:20 -07:00
Behdad Esfahbod 9c0c3589f3 Minor 2019-05-10 13:56:50 -07:00
Behdad Esfahbod 5d4437fad0 Minor 2019-05-10 13:43:29 -07:00
Behdad Esfahbod ed972d5d73 [iter] Rewrite test functions
Notably, add hb_is_source_of(,) and hb_is_sink_of(,) to replace most
uses of hb_is_iterator_of(,).
2019-05-09 16:58:28 -07:00
Behdad Esfahbod 4c9e0c37a3 [serialize] LangSys subset->copy 2019-05-08 10:40:39 -07:00
Behdad Esfahbod af571dbffc [meta] Replace most hb_enable_if with hb_requires
They do absolutely same thing.  hb_requires is to encode constraints,
whereas hb_enable_if is for more conditional enabling.
2019-05-07 21:39:20 -07:00
Behdad Esfahbod 83e3eabd84 Whitespace 2019-05-07 20:58:43 -07:00
Behdad Esfahbod e33ad25222 [serialize] FeatureVariations subset->copy 2019-05-07 15:46:24 -07:00
Behdad Esfahbod 4c2fd05ca5 [iter] Implement range-based for loops
Part of https://github.com/harfbuzz/harfbuzz/issues/1648
2019-05-06 19:57:35 -07:00
Behdad Esfahbod 36bb24f7b4 [dispatch] Forward arguments in all dispatch multiplexers 2019-05-05 10:14:17 -07:00
Behdad Esfahbod 88a4147240 [serializer] Accept exact type in serialize_subset/copy() 2019-05-02 14:22:31 -07:00
Ebrahim Byagowi 92588782d7
Remove space between right angle brackets now that we have C++11 (#1689) 2019-04-30 13:05:10 -07:00
Behdad Esfahbod 699de689e9 Delete default assignment operator Offset<> 2019-04-15 16:00:20 -04:00
Behdad Esfahbod c68eb7002f Minor 2019-04-03 16:24:12 -07:00
Behdad Esfahbod 85adf4ad5c [GDEF] Don't assume glyphlist is sorted
As was hit by the fuzzer.

Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=14032
2019-04-03 16:07:36 -07:00
Jonathan Kew e5d6fe9782 Don't skip setting the .end field of the first range
Fixes a bug in CoverageFormat2::serialize whereby the first range
was not serialized correctly if it consists of only a single glyph ID.
This broke shaping of U+0626 in the Arabic fallback shaper, because it
is not found in the coverage table of the 'init' and 'medi' lookups.

Also fix similar bug in ClassDefFormat2::serialize, noted during code
inspection (I haven't observed a case that was actually affected by
this, but it looks broken).

Fixes https://github.com/harfbuzz/harfbuzz/issues/1504
2019-03-31 19:02:47 -07:00
Behdad Esfahbod b986c6a321 [C++11] Remove IntType::set() in favor of operator= 2019-03-29 20:21:21 -07:00
Behdad Esfahbod cbe2118c58 Merge branch 'master' into iter 2019-01-30 15:07:09 -08:00
Behdad Esfahbod 849a0f1758 [iter] Add hb_iter_with_fallback_t instead 2019-01-29 17:10:19 -08:00
Behdad Esfahbod 4d40ed9d1a [iter] Add hb_iter_with_mixin_t<> 2019-01-29 13:55:23 -08:00
Behdad Esfahbod 84a25d79c6 [iter] Rename 2019-01-29 13:39:19 -08:00