aboutsummaryrefslogtreecommitdiffhomepage
path: root/gm/dftext.cpp
diff options
context:
space:
mode:
authorGravatar jvanverth <jvanverth@google.com>2015-03-16 12:58:43 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-03-16 12:58:44 -0700
commitd68a550ec890c3e3135ffa119621e17e55d58dd6 (patch)
treef54ac347f699686e902ab090b2be9468e8ef79a9 /gm/dftext.cpp
parent95a4fe3737f5a23a88dbec198f24247a9232f538 (diff)
Fix up some issues introduced by https://codereview.chromium.org/1013773002/
Need to check for zero-length gradients when using the new correction. Make sure we use the old text sizes for color emoji test in dftext GM. BUG=skia:3540 Review URL: https://codereview.chromium.org/1009973004
Diffstat (limited to 'gm/dftext.cpp')
-rwxr-xr-xgm/dftext.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/gm/dftext.cpp b/gm/dftext.cpp
index 2ce28c3930..f3d39e527c 100755
--- a/gm/dftext.cpp
+++ b/gm/dftext.cpp
@@ -201,19 +201,24 @@ protected:
paint.setLCDRenderText(false);
SkAutoCanvasRestore acr(canvas, true);
canvas->skew(0.0f, 0.151515f);
- paint.setTextSize(32);
+ paint.setTextSize(SkIntToScalar(32));
canvas->drawText(text, textLen, 745, 70, paint);
}
{
paint.setLCDRenderText(true);
SkAutoCanvasRestore acr(canvas, true);
canvas->skew(0.5f, 0.0f);
- paint.setTextSize(32);
+ paint.setTextSize(SkIntToScalar(32));
canvas->drawText(text, textLen, 580, 230, paint);
}
// check color emoji
paint.setTypeface(fTypeface);
+#ifdef SK_BUILD_FOR_ANDROID
+ paint.setTextSize(SkIntToScalar(19));
+#else
+ paint.setTextSize(SkIntToScalar(22));
+#endif
canvas->drawText(text, textLen, 670, 100, paint);
#if SK_SUPPORT_GPU