Commit 66c0a58b authored by ckitagawa's avatar ckitagawa Committed by Commit Bot

[Paint Preview] Don't drop hints for subset fonts

As noted in crbug/1010396 dropping hints breaks some CJK Freetype fonts.
Disabling this will slightly increase subset font sizes for fonts that
rely on bytecode hints. However, this seems to be uncommon based on the
discussion in the bug.

Change-Id: Ib2a621ebfcfad3fbc015f50ec7c5bf3b18e6fa7e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1873238
Auto-Submit: Calder Kitagawa <ckitagawa@chromium.org>
Reviewed-by: default avatarMehran Mahmoudi <mahmoudi@chromium.org>
Commit-Queue: Calder Kitagawa <ckitagawa@chromium.org>
Cr-Commit-Position: refs/heads/master@{#708190}
parent a669c0d1
...@@ -89,7 +89,6 @@ sk_sp<SkData> SubsetFont(SkTypeface* typeface, const GlyphUsage& usage) { ...@@ -89,7 +89,6 @@ sk_sp<SkData> SubsetFont(SkTypeface* typeface, const GlyphUsage& usage) {
hb_subset_input_glyph_set(input.get()); // Owned by |input|. hb_subset_input_glyph_set(input.get()); // Owned by |input|.
usage.ForEach(base::BindRepeating(&AddGlyphs, base::Unretained(glyphs))); usage.ForEach(base::BindRepeating(&AddGlyphs, base::Unretained(glyphs)));
hb_subset_input_set_retain_gids(input.get(), true); hb_subset_input_set_retain_gids(input.get(), true);
hb_subset_input_set_drop_hints(input.get(), true);
HbFace subset_face(hb_subset(face.get(), input.get())); HbFace subset_face(hb_subset(face.get(), input.get()));
HbBlob subset_blob(hb_face_reference_blob(subset_face.get())); HbBlob subset_blob(hb_face_reference_blob(subset_face.get()));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment