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

Unified Diff: gm/lcdtext.cpp

Issue 1842753002: Style bikeshed - remove extraneous whitespace (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 9 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/lcdblendmodes.cpp ('k') | gm/lightingshader.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/lcdtext.cpp
diff --git a/gm/lcdtext.cpp b/gm/lcdtext.cpp
index a2bfa01d3827ccac3f66a267042c523a1984de45..978bfd641ee1ca6afea86337a478a001408012e0 100644
--- a/gm/lcdtext.cpp
+++ b/gm/lcdtext.cpp
@@ -23,19 +23,19 @@ public:
const int pointSize = 36;
textHeight = SkIntToScalar(pointSize);
}
-
+
protected:
-
+
SkString onShortName() {
SkString name("lcdtext");
name.append(sk_tool_utils::major_platform_os_name());
return name;
}
-
+
SkISize onISize() { return SkISize::Make(640, 480); }
-
+
virtual void onDraw(SkCanvas* canvas) {
-
+
y = textHeight;
drawText(canvas, SkString("TEXT: SubpixelTrue LCDRenderTrue"),
true, true);
@@ -46,7 +46,7 @@ protected:
drawText(canvas, SkString("TEXT: SubpixelFalse LCDRenderFalse"),
false, false);
}
-
+
void drawText(SkCanvas* canvas, const SkString& string,
bool subpixelTextEnabled, bool lcdRenderTextEnabled) {
SkPaint paint;
@@ -56,11 +56,11 @@ protected:
paint.setSubpixelText(subpixelTextEnabled);
paint.setLCDRenderText(lcdRenderTextEnabled);
paint.setTextSize(textHeight);
-
+
canvas->drawText(string.c_str(), string.size(), 0, y, paint);
y += textHeight;
}
-
+
private:
typedef skiagm::GM INHERITED;
SkScalar y, textHeight;
@@ -85,14 +85,14 @@ class LcdTextSizeGM : public skiagm::GM {
public:
LcdTextSizeGM() {}
-
+
protected:
SkString onShortName() {
return SkString("lcdtextsize");
}
-
+
SkISize onISize() { return SkISize::Make(320, 120); }
-
+
virtual void onDraw(SkCanvas* canvas) {
const char* lcd_text = "LCD";
const char* gray_text = "GRAY";
« no previous file with comments | « gm/lcdblendmodes.cpp ('k') | gm/lightingshader.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698