diff options
author | jvanverth <jvanverth@google.com> | 2014-09-16 05:45:19 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-09-16 05:45:19 -0700 |
commit | 9564ce60a657acce89fb956deb8645b324eaad1e (patch) | |
tree | 0fbe408f717124b40ef6c0822828c6d5371fcf0e /gm/fontscaler.cpp | |
parent | 49005bf8929dd8ca86431e13414d683b509cd538 (diff) |
Fix scaling issue with distance field text.
Picks the correct distance field size based on both the text size and
the max matrix scale. Adjusts the matrix scale if non-unity. Also adds
GM for verifying proper distance field scaling.
BUG=skia:2928
R=bsalomon@google.com, joshualitt@google.com
Author: jvanverth@google.com
Review URL: https://codereview.chromium.org/568843002
Diffstat (limited to 'gm/fontscaler.cpp')
-rw-r--r-- | gm/fontscaler.cpp | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/gm/fontscaler.cpp b/gm/fontscaler.cpp index 8aef8f0ebe..eb38013cb1 100644 --- a/gm/fontscaler.cpp +++ b/gm/fontscaler.cpp @@ -72,12 +72,10 @@ protected: canvas->drawRect(r, p); } - int index = 0; for (int ps = 6; ps <= 22; ps++) { paint.setTextSize(SkIntToScalar(ps)); canvas->drawText(text, textLen, x, y, paint); y += paint.getFontMetrics(NULL); - index += 1; } } canvas->translate(0, SkIntToScalar(360)); |