Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(364)

Unified Diff: gm/degeneratesegments.cpp

Issue 1235343004: make arithmode bigtext colortype* degeneratesegments gm portable (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gm/colortypexfermode.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/degeneratesegments.cpp
diff --git a/gm/degeneratesegments.cpp b/gm/degeneratesegments.cpp
index e5ca18796adfa72611dda0ce6fec8d08d0fd25ad..4016e45a281f2800afe7c668cb6fc385a4d02cf7 100644
--- a/gm/degeneratesegments.cpp
+++ b/gm/degeneratesegments.cpp
@@ -287,8 +287,7 @@ protected:
SkPaint titlePaint;
titlePaint.setColor(SK_ColorBLACK);
titlePaint.setAntiAlias(true);
- sk_tool_utils::set_portable_typeface(&titlePaint);
- titlePaint.setLCDRenderText(true);
+ sk_tool_utils::set_portable_typeface_always(&titlePaint);
titlePaint.setTextSize(15 * SK_Scalar1);
const char title[] = "Random Paths Drawn Into Rectangle Clips With "
"Indicated Style, Fill and Linecaps, "
@@ -317,7 +316,7 @@ protected:
canvas->translate(rect.width() + 4*SK_Scalar1, 0);
}
- SkColor color = 0xff007000;
+ SkColor color = sk_tool_utils::color_to_565(0xff007000);
StyleAndName style = gStyles[(rand.nextU() >> 16) % numStyles];
CapAndName cap = gCaps[(rand.nextU() >> 16) % numCaps];
FillAndName fill = gFills[(rand.nextU() >> 16) % numFills];
@@ -348,8 +347,7 @@ protected:
SkPaint labelPaint;
labelPaint.setColor(color);
labelPaint.setAntiAlias(true);
- sk_tool_utils::set_portable_typeface(&labelPaint);
- labelPaint.setLCDRenderText(true);
+ sk_tool_utils::set_portable_typeface_always(&labelPaint);
labelPaint.setTextSize(10 * SK_Scalar1);
canvas->drawText(style.fName,
strlen(style.fName),
« no previous file with comments | « gm/colortypexfermode.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698