diff --git a/src/hb-coretext-font.cc b/src/hb-coretext-font.cc index ec85a516c..b57bb9731 100644 --- a/src/hb-coretext-font.cc +++ b/src/hb-coretext-font.cc @@ -194,6 +194,10 @@ hb_coretext_get_variation_glyph (hb_font_t *font HB_UNUSED, if (cg_glyph[i]) return false; + // Humm. CoreText falls back to the default glyph if the variation selector + // is not supported. We cannot truly detect that case. So, in essence, + // we are always returning true here... + *glyph = cg_glyph[0]; return true; } diff --git a/test/shape/data/in-house/tests/variation-selectors.tests b/test/shape/data/in-house/tests/variation-selectors.tests index bcf656489..775e90de4 100644 --- a/test/shape/data/in-house/tests/variation-selectors.tests +++ b/test/shape/data/in-house/tests/variation-selectors.tests @@ -1,2 +1,3 @@ +@font-funcs-=coretext # CoreText does not let us detect unsupported variation-selectors ../fonts/bbc24004e776f348a0f72287d24b0124867ee750.ttf;;U+0066,U+FE00,U+0069;[gid5=0+1134|gid1=0+0] ../fonts/bbc24004e776f348a0f72287d24b0124867ee750.ttf;--not-found-variation-selector-glyph=1000000;U+0066,U+FE00,U+0069;[gid2=0+711|gid1000000=0+0|gid3=2+497] diff --git a/test/shape/run-tests.py b/test/shape/run-tests.py index da50f6d27..a3e8fc15f 100755 --- a/test/shape/run-tests.py +++ b/test/shape/run-tests.py @@ -83,10 +83,10 @@ for what in ["shaper", "face-loader", "font-funcs"]: ) # Capture the output what_list = what_process.communicate()[0].decode("utf-8").strip().split() - print(what, end=": ") - print(what_list) + whats = plural(what) var_name = supported_whats_var_name(what) globals()[var_name] = what_list + print(f"Supported {whats}: {what_list}") passes = 0 fails = 0 @@ -150,7 +150,7 @@ for filename in args: values = [v for v in values if v in supported] var_name = all_whats_var_name(what) - print(f"Setting {var_name} to {values}") + print(f"Setting {whats} to test to {values}") globals()[var_name] = values consumed = True if consumed: