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

Side by Side Diff: gm/fontmgr.cpp

Issue 1842753002: Style bikeshed - remove extraneous whitespace (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 8 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 unified diff | Download patch
« no previous file with comments | « gm/filterfastbounds.cpp ('k') | gm/gammatext.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2013 Google Inc. 2 * Copyright 2013 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "gm.h" 8 #include "gm.h"
9 #include "SkCanvas.h" 9 #include "SkCanvas.h"
10 #include "SkFontMgr.h" 10 #include "SkFontMgr.h"
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after
255 void onDraw(SkCanvas* canvas) override { 255 void onDraw(SkCanvas* canvas) override {
256 SkPaint paint; 256 SkPaint paint;
257 paint.setAntiAlias(true); 257 paint.setAntiAlias(true);
258 paint.setSubpixelText(true); 258 paint.setSubpixelText(true);
259 paint.setTextSize(100); 259 paint.setTextSize(100);
260 paint.setStyle(SkPaint::kStroke_Style); 260 paint.setStyle(SkPaint::kStroke_Style);
261 paint.setTextScaleX(fScaleX); 261 paint.setTextScaleX(fScaleX);
262 paint.setTextSkewX(fSkewX); 262 paint.setTextSkewX(fSkewX);
263 263
264 const SkColor boundsColors[2] = { SK_ColorRED, SK_ColorBLUE }; 264 const SkColor boundsColors[2] = { SK_ColorRED, SK_ColorBLUE };
265 265
266 SkFontMgr* fm = fFM; 266 SkFontMgr* fm = fFM;
267 int count = SkMin32(fm->countFamilies(), 32); 267 int count = SkMin32(fm->countFamilies(), 32);
268 268
269 int index = 0; 269 int index = 0;
270 SkScalar x = 0, y = 0; 270 SkScalar x = 0, y = 0;
271 271
272 canvas->translate(80, 120); 272 canvas->translate(80, 120);
273 273
274 for (int i = 0; i < count; ++i) { 274 for (int i = 0; i < count; ++i) {
275 SkAutoTUnref<SkFontStyleSet> set(fm->createStyleSet(i)); 275 SkAutoTUnref<SkFontStyleSet> set(fm->createStyleSet(i));
(...skipping 26 matching lines...) Expand all
302 302
303 DEF_GM(return new FontMgrGM;) 303 DEF_GM(return new FontMgrGM;)
304 DEF_GM(return new FontMgrMatchGM;) 304 DEF_GM(return new FontMgrMatchGM;)
305 DEF_GM(return new FontMgrBoundsGM(1.0, 0);) 305 DEF_GM(return new FontMgrBoundsGM(1.0, 0);)
306 DEF_GM(return new FontMgrBoundsGM(0.75, 0);) 306 DEF_GM(return new FontMgrBoundsGM(0.75, 0);)
307 DEF_GM(return new FontMgrBoundsGM(1.0, -0.25);) 307 DEF_GM(return new FontMgrBoundsGM(1.0, -0.25);)
308 308
309 #ifdef SK_BUILD_FOR_WIN 309 #ifdef SK_BUILD_FOR_WIN
310 DEF_GM(return new FontMgrGM(SkFontMgr_New_DirectWrite());) 310 DEF_GM(return new FontMgrGM(SkFontMgr_New_DirectWrite());)
311 #endif 311 #endif
OLDNEW
« no previous file with comments | « gm/filterfastbounds.cpp ('k') | gm/gammatext.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698