src/hb-ot-layout.cc


Log

Author Commit Date CI Message
Behdad Esfahbod a81dd105 2022-11-26T13:43:15 [layout] Adjust printing feature tags For required-feature, print spaces, not nul bytes.
Behdad Esfahbod 56e3868b 2022-11-26T13:14:23 [layout/buffer-message] Print feature name in lookup buffer messages
Behdad Esfahbod ed43bc51 2022-11-20T13:10:19 [buffer] Move delete_glyphs_inplace() here
Behdad Esfahbod 561946c7 2022-11-16T17:58:59 [layout] Comment
Behdad Esfahbod 27a8fe7d 2022-11-16T17:49:44 [layout] Only update buffer digest if buffer changed by a pause
Behdad Esfahbod 8b2a2111 2022-11-16T16:57:44 [layout] Keep digest updated in the context Don't recompute digest after every (applied) GSUB lookup.
Behdad Esfahbod a5964a2d 2022-11-16T16:45:23 [layout] Minor simplify
Behdad Esfahbod 80b87588 2022-11-16T16:26:41 [layout] Add a buffer message for digest-skipped lookups
Behdad Esfahbod dff1b809 2022-11-16T16:19:05 [buffer] Add .digest() and use
Behdad Esfahbod 654a2eaf 2022-11-16T16:09:04 [layout] Use buffer-digest for GSUB as well Combined with previous commit, this shows up to 12% speed up with Roboto and the en-words (ie. short strings) benchmark, about 5% for longer English tests, and no adverse effect on heavier fonts.
Behdad Esfahbod 15b6c325 2022-11-16T15:59:13 [layout] Use a buffer digest for GPOS to skip whole lookups
Khaled Hosny 3ce4b8f5 2022-10-08T19:10:07 5.3.0
Qunxin Liu f4813e3b 2022-09-09T10:34:09 [instance] update collect_lookups/prune_features()/closure_features() with variations Some features will be substituted with variations, so we do not collect lookups from the original feature tables.
Behdad Esfahbod b70032ed 2022-09-22T15:59:16 [layout] Fix typo in docs
Behdad Esfahbod 752060a4 2022-09-01T13:47:12 [layout] Document hb_ot_layout_lookup_get_optical_bound()
Behdad Esfahbod 71c6cba0 2022-09-01T13:43:19 [layout] Rename API: -hb_ot_layout_get_optical_bound() +hb_ot_layout_lookup_get_optical_bound()
Behdad Esfahbod 3892128a 2022-09-01T13:40:53 [layout] Add HB_NO_LAYOUT_RARELY_USED
Behdad Esfahbod 8e88653f 2022-09-01T13:39:26 [layout] Move code around
Behdad Esfahbod 4bf96211 2022-08-31T09:18:18 [optical-bounds] Optimize
Behdad Esfahbod 5d6f1a88 2022-08-31T08:31:24 [layout] Add hb_ot_layout_get_optical_bound()
Behdad Esfahbod 14eb3d37 2022-09-01T13:18:42 [layout] Improve annotations
Matthias Clasen 29d5c7f6 2022-08-31T15:03:09 docs: Improve docs for some apis Various functions take hb_tag_t arrays. Those arrays are expected to be 0-terminated. Document that.
Behdad Esfahbod c96bfca3 2022-08-31T08:05:14 [get-alternates] Minor simplify
Behdad Esfahbod 41aa02ae 2022-08-29T11:17:22 [layout] Improve get_feature_tags documentation Fixes https://github.com/harfbuzz/harfbuzz/issues/3798
Khaled Hosny 371c8867 2022-08-23T22:28:58 Add few missing since tags
Garret Rieger 5fdae684 2022-06-29T23:52:08 [reorg] Move GSUB.hh up one level and change GSUB namespace to GSUB_impl.
Khaled Hosny 98e90cc6 2022-06-30T08:43:57 [docs] Reduce warnings Use markdown syntax for inline code blocks instead of %true, %false, and %NULL.
Garret Rieger 3fbf2dec 2022-06-28T23:55:32 [reorg] Move OT::Layout::GPOS_impl::GPOS to OT::Layout::GPOS.
Garret Rieger 88ef3c5a 2022-06-28T23:26:49 [reorg] Change OT::Layout::GPOS to OT::Layout::GPOS_impl.
Garret Rieger 74f45f7c 2022-06-24T23:14:30 [reorg] Move remaining GPOS lookup types to new directory.
Behdad Esfahbod c13ff395 2022-06-08T06:25:23 [layout] Rename apply_recurse_func to specialization of dispatch_recurse_func
Behdad Esfahbod 42051fe1 2022-06-08T04:00:21 [layout] s/inplace/always_inplace/g
Behdad Esfahbod b96622d1 2022-06-05T02:45:41 [layout] Use a cache for main input ClassDef of (Chain)ContextLookupFormat2 This commit adds a per-lookup caching infrastructure to GSUB/GPOS, and uses it to cache input ClassDef.get_class value for (Chain)ContextLookupFormat2. For fonts heavy on use of heave class-based2 context matching, this shows a good speedup. For NotoNastaliqUrdu for example, I observe 17% speedup. Unfortunately not many other lookups can use a cache like this :(. https://github.com/harfbuzz/harfbuzz/pull/3636
Behdad Esfahbod 15543f70 2022-06-04T10:55:50 [indic-like] Move allocation of syllable() buffer var to shapers that use it In indic, we don't have a pause location release the var.
Behdad Esfahbod e6409d39 2022-06-05T06:57:37 Revert "[layout] Use a cache for main input ClassDef of (Chain)ContextLookups" This reverts commit 57d1c08739d0acd94b96da2f9d5dd6c0ff3b3722. Err. This was an accident.
Behdad Esfahbod 57d1c087 2022-06-05T02:45:41 [layout] Use a cache for main input ClassDef of (Chain)ContextLookups
Behdad Esfahbod 997d9cc4 2022-06-02T18:04:12 [map] Make unique_ptr hashable
Behdad Esfahbod e9407a2b 2022-06-02T11:29:44 Use shared_ptr<hb_set_t> in one place See if valgrind is happy...
Behdad Esfahbod 3957d292 2022-05-29T07:30:58 [layout] Remove stale comment
Behdad Esfahbod 044d7a06 2022-03-28T12:38:56 [indic-like] Add per-lookup per-syllable flag This allows mix-and-matching per-syllable and other lookups. In fact, removes the clear-syllables call completely. Fixes https://github.com/harfbuzz/harfbuzz/issues/3513
Garret Rieger b342adeb 2022-03-23T16:28:22 [reorg] Move GSUB into OT::Layout::GSUB namespace.
Behdad Esfahbod cad2fe8e 2022-03-15T10:49:29 [baseline] Fix HB_NO_METRICS build Fixes https://github.com/harfbuzz/harfbuzz/issues/3482
Behdad Esfahbod a8a89b80 2022-03-15T10:48:03 [layout] Whitespace
Behdad Esfahbod 6bf8f0a3 2022-03-15T10:44:41 [baseline] Use ot-metrics fallback API
Matthias Clasen e7ab42b2 2022-03-10T09:05:43 [layout] Fix handling of baseline variations For BASE table format 1.1, the handling of design space vs user space coordinates was inconsistent. We were applying design -> user transformation twice for the deltas, leading to wrong baseline values. Patch by Ebrahim Byagowi <ebrahim@gnu.org> Fixes: #3476
Khaled Hosny 8d1b000a 2022-03-01T21:27:32 4.0.0
Matthias Clasen 95bb2ff7 2022-02-16T13:10:52 [ot-layout] Add central baselines Add HB_OT_LAYOUT_BASELINE_TAG_IDEO_EMBOX_CENTRAL and HB_OT_LAYOUT_BASELINE_TAG_IDEO_FACE_CENTRAL which are the centers of the ideographic em-box and face box.
Matthias Clasen f81578fd 2022-02-13T19:15:36 [ot-layout] Synthesize missing baselines Add a variation of hb_ot_layout_get_baseline that synthesizes missing baselines, using heuristics in part taken from the CSS Inline Layout Module, Level 3. Includes some new tests for synthesized baselines. The base2.ttf is a subset of Noto Sans Bengali that includes just the Bengali Ka. New API: hb_ot_layout_get_baseline_with_fallback
Behdad Esfahbod 98079109 2022-02-13T18:15:32 [ot-layout] Add +hb_ot_layout_get_horizontal_baseline_tag_for_script() New API: +hb_ot_layout_get_horizontal_baseline_tag_for_script()
Matthias Clasen 9909e332 2022-02-15T18:02:09 Improve docs for hb_ot_layout_get_ligature_carets Add some relevant details to the documentation for this function. Fixes: #3168
Garret Rieger bc899650 2022-01-28T13:54:10 [subset] Fix for issue #3397. cur_intersected_glyphs gets modified during recursion leading to incorrect filtering of sub tables in some cases. So don't use cur_intersected_glyphs. Instead just add an additional entry onto the parent_active_glyphs () stack. Additionaly expands NotoNastaliqUrdu tests to include coverage of the issue from #3397.
Behdad Esfahbod bea5369c 2022-01-04T10:52:05 [buffer] Rename swap_buffers() to sync()
Garret Rieger d6702570 2021-12-10T13:52:05 [subset] reset the visited lookup count before each closure iteration.
Behdad Esfahbod 394f7729 2021-11-19T11:49:23 [map] Allow storing classes in the hashmap Fixes https://github.com/harfbuzz/harfbuzz/issues/3293 The trick was to change the type of the invalid key/value to be non-class.
Matthias Clasen 1e07d42a 2021-11-07T01:19:42 Typo fix
Matthias Clasen 1fd7fd98 2021-11-06T10:18:20 Cosmetics: Avoid confusing indentation This line had me confused for a second because the condition looked like a cast and the if just looked misplaced. Add a line break to prevent such confusion.
Matthias Clasen 3471f8f6 2021-11-06T10:17:20 docs: Clarify a doc comment Reword the docs for hb_ot_layout_script_select_language and be a bit more specific about the returned index.
Qunxin Liu 364b6b39 2021-10-31T14:38:20 [subset] Don't assume FeatureList is sorted Though the spec said FeatureRecords are sorted alphabetically by feature tag, there're font files with unsorted FeatureList. And harfbuzz is not able to subset these files correctly because we use binary search in finding featureRecords when collecting lookups. Also find_duplicate_features needs to be updated to handle this.
Behdad Esfahbod 6d555ce8 2021-11-02T00:18:22 [meta] Use std::forward instead of hb_forward()
Khaled Hosny b36f1510 2021-09-18T23:09:07 [doc] Add missing version tags
Behdad Esfahbod 95b04f74 2021-07-12T17:35:45 [buffer] Remove unnecessary have_separate_output()
Behdad Esfahbod 3807061d 2021-07-12T17:02:03 [ot-layout] Don't remove_output() before reverse substitution No need anymore, because of new swap_buffers() semantics. Just assert instead.
Behdad Esfahbod a7f4c985 2021-07-12T17:00:46 [ot-layout] Always swap_buffers() even if no substitutions happened
Behdad Esfahbod 62b441e6 2021-07-12T16:59:34 [layout] Use Proxy::inplace instead of table index check Equivalent.
Behdad Esfahbod 431f1640 2021-07-12T16:57:25 [layout] Don't call clear_output() before pause-func
Behdad Esfahbod 1cb0ca1f 2021-07-12T16:52:31 Whitespace
Behdad Esfahbod 40884af1 2021-07-09T17:17:05 [ot-layout] Narrow down random feature logic vs safe-to-break
Behdad Esfahbod 33b579d0 2021-07-09T17:12:09 [ot-layout] Clear random flag for subsequent flags Ouch!
Behdad Esfahbod bb48bf52 2021-07-08T10:53:45 Rename misc uses of "free" In preparation for fixing https://github.com/harfbuzz/harfbuzz/issues/3044
Garret Rieger bc06af97 2021-06-16T15:49:14 [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.
Behdad Esfahbod 93e6a9bc 2021-06-15T15:38:49 Revert "Remove unneeded buffer clear_output / remove_output calls" This reverts commit 06175b71433bc42edc07d342e6354035e37fb5fd. One of the sanitizers is failing. Pushing again as PR to debug. I have suspicions.
Behdad Esfahbod 06175b71 2021-06-15T14:33:27 Remove unneeded buffer clear_output / remove_output calls Made sure clear_output is always paired with swap_buffers. Trying to see if we can move towards RAII-like buffer iterators instead of the buffer keeping an iterator internally.
Khaled Hosny a9fb6a0c 2021-06-06T14:40:50 [aat] Add start table/end table to buffer messages Related to https://github.com/harfbuzz/harfbuzz/issues/3008
Behdad Esfahbod cf9538e8 2021-06-04T22:33:16 Removal remaining uses of "blacklist" terminology
Khaled Hosny 90713f27 2021-04-30T16:56:39 [hb-ot-layout] Document some return values
Qunxin Liu 0e1c0fa4 2021-01-12T10:17:14 [subset] optimize glyph closure method: step 5 add testcase and some fixes
Behdad Esfahbod 8450f43a 2021-03-15T15:18:06 [buffer] HB_NODISCARD next_glyph()
Khaled Hosny 5151c2b6 2020-12-31T00:28:27 [introspection] Replace deprecated allow-none Use optional or nullable as appropriate.
Khaled Hosny 8e8c3e58 2020-12-30T23:37:49 [docs] Complete hb-ot-layout docs a bit
Khaled Hosny a8e72ee7 2020-12-30T23:08:40 [docs] Use %true and %false consistently
Khaled Hosny e93de636 2020-12-27T00:57:29 [docs] Document unused language in get_baseline Document that language_tag in hb_ot_layout_get_baseline() is currently unused. Fixes https://github.com/harfbuzz/harfbuzz/issues/2662
Simon Cozens 428c111f 2020-09-18T16:24:47 Fix spacing around casts
Nathan Willis 70331ca4 2019-04-22T19:25:42 [Docs] Minor update GTK-Doc comments in hb-ot-layout.
Ebrahim Byagowi 122a2897 2020-07-05T22:45:11 [aat] Remove lcar support Very low use, only two distinct font files, Apple Chancery.ttf and Hoefler Text.ttc have it so it really doesn't worth the size addition and so, but one may argue that whole ligature caret is low use but guess we better to encourage GDEF one anyway.
Ebrahim Byagowi e4203c14 2020-06-22T05:03:27 2.6.8
Ebrahim Byagowi d38eb49f 2020-06-19T23:40:42 Move the iteration logic to FeatureParamsCharacterVariants Hopefully I can make members protected also.
Ebrahim Byagowi 9b3d4f45 2020-06-19T23:33:07 Use dagger in hb_ot_layout_feature_get_characters The way it used to work was a bit nonidiomatic but the replacment is idiomatic way of iterating used elsewhere. The new code just doesn't check nullability of "characters", which isn't what we do anywhere else.
Ebrahim Byagowi 63422c4c 2020-06-19T23:24:04 [ot-layout] simplify
Ebrahim Byagowi f1488152 2020-06-19T23:07:28 [doc] Remove the not needed comment All the other similar iterating API are like this and don't have such comment, written at the time I wasn't familiar enough with the way such API are shaped.
Behdad Esfahbod 70d6696c 2020-06-18T17:09:39 [dispatch] Don't require debug_depth for untraced objects
Behdad Esfahbod 5bc4cedd 2020-06-18T17:04:35 Rename
Behdad Esfahbod 8d0a90ac 2020-06-18T16:53:54 [dispatch] Default debug level to 0
Behdad Esfahbod e47a2ab8 2020-06-18T16:48:07 Remove unused dispatcher names
Behdad Esfahbod b2a1accc 2020-06-18T16:41:31 Simplify get_glyph_alternates() dispatcher Trying to make it **very simple** to add a specialized dispatcher for one API to be routed to just a few objects (one in this case).
Behdad Esfahbod ffe8d3f3 2020-06-18T16:31:39 Use dispatch for get_glyph_alternates_t First time we do this in a way that if target object doesn't have the matching function we basically "ignore". Risky but I feel like is the right decision for this case. I'm going to put back the template varargs and use those, which would make the dispatcher be just that: "dispatcher", and wouldn't need to carry the call context. That would be a refreshing change I think.
Behdad Esfahbod 5bede338 2020-06-18T15:25:19 Whitespace
Ebrahim Byagowi 1bac8582 2020-06-18T22:56:07 [layout] Rename _get_alternates to _get_glyph_alternates
Ebrahim Byagowi d3c16979 2020-06-18T08:37:21 [layout] move alternate buffer iteration logic to AlternateSet
Ebrahim Byagowi 1348a2c8 2020-06-16T21:05:16 [layout] hb_ot_layout_lookup_get_alternates, a new API An API to retrieve one-to-one alternates from a given GSUB lookup index.
Behdad Esfahbod e7c79e16 2020-06-17T15:32:40 Merge pull request #2287 from simoncozens/instrumentation Add messages for GPOS/GSUB (take 2)