-
Notifications
You must be signed in to change notification settings - Fork 682
rework handling of requiredFeature #39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
… including Old Hangul sequences that don't have Unicode compositions. Merge clusters in decomposed syllables.
…nt implements it using a zero-width glyph.
…as some fonts want these to be visible/spacing glyphs.
…e Jamo Filler glyphs.
…d by Dohyun Kim).
I believe Windows 8 disables it, and spec update dated Jan 2014 also clearly says it's disabled by default: http://www.microsoft.com/typography/OpenTypeDev/arabic/intro.htm#features
The OT shaper supersedes the fallback shaper in every case and the latter become an extra weight for 99.9% of users.
See thread "[HarfBuzz] compilation error of 0.9.26 with MinGW" started by Werner.
Seems like configure.ac is already able to handle it.
Apparently some modern fonts have proper GPOS mark positioning tables, but undesirable precomposed forms! See thread "Hebrew composition to presentation forms" and: http://tex.stackexchange.com/questions/156775/having-trouble-with-vowel-positioning-in-ezra-sil-xelatex Test case: U+fb1d,05d9,05b4
Useful for Android / Chrome / etc when ICU is built in the same library as harfbuzz itself.
This is a higher-priority shaper than default shaper ("ot"), but
only picks up fonts that have AAT "morx"/"mort" table.
Note that for this to work the font face's get_table() implementation
should know how to return the full font blob.
Based on patch from Konstantin Ritt.
Not tested.
...to avoid an unused function warning; see mozilla bug https://bugzilla.mozilla.org/show_bug.cgi?id=984081.
On iOS CoreText and CoreGraphics are stand-alone frameworks
Many GCC versions don't define __arm64__
As requested by Martin Hosken on the list.
Disables any cluster-merging. Added for testing purposes while we investigate what kind of API to add for this.
commit b5a0f69 Author: Behdad Esfahbod <behdad@behdad.org> Date: Thu Oct 17 18:04:23 2013 +0200 [indic] Pass zero-context=false to would_substitute for newer scripts For scripts without an old/new spec distinction, use zero-context=false. This changes behavior in Sinhala / Khmer, but doesn't seem to regress. This will be useful and used in Javanese. The *intention* was to change zero-context from true to false for scripts that don't have old-vs-new specs. However, checking the code, looks like we essentially change zero-context to always be true; ie. we only changed things for old-spec, and we broke them. That's what causes this bug: https://bugs.freedesktop.org/show_bug.cgi?id=76705 The root of the bug is here: /* Use zero-context would_substitute() matching for new-spec of the main * Indic scripts, but not for old-spec or scripts with one spec only. */ bool zero_context = indic_plan->config->has_old_spec || !indic_plan->is_old_spec; Note that is_old_spec itself is: indic_plan->is_old_spec = indic_plan->config->has_old_spec && ((plan->map.chosen_script[0] & 0x000000FF) != '2'); It's easy to show that zero_context is now always true. What we really meant was: bool zero_context = indic_plan->config->has_old_spec && !indic_plan->is_old_spec; Ie, "&&" instead of "||". We made this change supposedly to make Javanese work. But apparently we got it working regardless! So I'm going to fix this to only change the logic for old-spec and not touch other cases.
…l.ttf from winxp [mozilla bug 986802]
|
Thanks Jonathan. Three points:
I think I really prefer to just move the RequiredFeature application to the last stage. Your approach is quite neat, but makes too much assumptions on the tag of the feature being set correctly. I'm undecided, please advise which way you think we should take this. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
See mozilla bug https://bugzilla.mozilla.org/show_bug.cgi?id=986802.
Testcase for this is to use arial.ttf from Windows XP, and disable the 'liga' feature; the lam-alef ligature should still happen, because requiredFeature points to the 'rlig' feature, but this will only work if it is processed at the proper stage, not if its lookups are inserted before all others.
Expected result:
$ ./test/shaping/hb-unicode-encode 644,627 | BUILD/util/hb-shape arial-winxp.ttf --features liga=0
[afii62840=0+1114]
Without this patch, we get:
$ ./test/shaping/hb-unicode-encode 644,627 | BUILD/util/hb-shape arial-winxp.ttf --features liga=0
[afii62760=1+470|afii62817=0+424]
because the 'rlig' lookup is applied too early, before the basic joining forms.