aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/ports/SkFontHost_FreeType.cpp
diff options
context:
space:
mode:
authorGravatar Ben Wagner <bungeman@google.com>2017-10-16 15:07:52 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-10-27 14:41:02 +0000
commit2d6b3937e04dcd1ab7f1e9a7f49f9bb3fd43b261 (patch)
treeecf85c4206ec0dabcba86fcea12699c7d49121ab /src/ports/SkFontHost_FreeType.cpp
parentd8a9dc958e4987f3ade3edce00627dfb63670006 (diff)
Remove subpixel positioning implies no bytecode hinting.
SkTypeface_FreeType::onFilterRec currently assumes that if asked to do subpixel positioning, don't do bytecode hinting. The idea was that both could not be satisfied at the same time, so pick something. This is no longer true, as with the v40 interpreter it is possible to get subpixel positioned but bytcode hinted glyphs. BUG=skia:6931 Change-Id: I4aef1670abc75623ad29bab0716d5ec9ebd2d906 Reviewed-on: https://skia-review.googlesource.com/59984 Reviewed-by: Ben Wagner <bungeman@google.com> Commit-Queue: Ben Wagner <bungeman@google.com>
Diffstat (limited to 'src/ports/SkFontHost_FreeType.cpp')
-rw-r--r--src/ports/SkFontHost_FreeType.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/ports/SkFontHost_FreeType.cpp b/src/ports/SkFontHost_FreeType.cpp
index 340572a268..aa571e04c6 100644
--- a/src/ports/SkFontHost_FreeType.cpp
+++ b/src/ports/SkFontHost_FreeType.cpp
@@ -675,11 +675,13 @@ void SkTypeface_FreeType::onFilterRec(SkScalerContextRec* rec) const {
// collapse full->normal hinting if we're not doing LCD
h = SkPaint::kNormal_Hinting;
}
+#ifdef SK_IGNORE_SUBPIXEL_HINTING_FIX
if ((rec->fFlags & SkScalerContext::kSubpixelPositioning_Flag)) {
if (SkPaint::kNo_Hinting != h) {
h = SkPaint::kSlight_Hinting;
}
}
+#endif
// rotated text looks bad with hinting, so we disable it as needed
if (!isAxisAligned(*rec)) {