| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2011 Google Inc. | 3 * Copyright 2011 Google Inc. |
| 4 * | 4 * |
| 5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
| 6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
| 7 */ | 7 */ |
| 8 | 8 |
| 9 | 9 |
| 10 | 10 |
| (...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 198 return SkISize::Make(1500, 1500); | 198 return SkISize::Make(1500, 1500); |
| 199 } | 199 } |
| 200 | 200 |
| 201 void onDraw(SkCanvas* canvas) override { | 201 void onDraw(SkCanvas* canvas) override { |
| 202 SkPaint origPaint; | 202 SkPaint origPaint; |
| 203 origPaint.setAntiAlias(true); | 203 origPaint.setAntiAlias(true); |
| 204 origPaint.setStyle(SkPaint::kStroke_Style); | 204 origPaint.setStyle(SkPaint::kStroke_Style); |
| 205 SkPaint fillPaint(origPaint); | 205 SkPaint fillPaint(origPaint); |
| 206 fillPaint.setColor(SK_ColorRED); | 206 fillPaint.setColor(SK_ColorRED); |
| 207 SkPaint strokePaint(origPaint); | 207 SkPaint strokePaint(origPaint); |
| 208 strokePaint.setColor(0xFF4444FF); | 208 strokePaint.setColor(sk_tool_utils::color_to_565(0xFF4444FF)); |
| 209 | 209 |
| 210 void (*procs[])(SkPath*, const SkRect&, SkString*) = { | 210 void (*procs[])(SkPath*, const SkRect&, SkString*) = { |
| 211 make0, make1, make2, make3, make4, make5 | 211 make0, make1, make2, make3, make4, make5 |
| 212 }; | 212 }; |
| 213 | 213 |
| 214 canvas->translate(SkIntToScalar(20), SkIntToScalar(80)); | 214 canvas->translate(SkIntToScalar(20), SkIntToScalar(80)); |
| 215 | 215 |
| 216 SkRect bounds = SkRect::MakeWH(SkIntToScalar(50), SkIntToScalar(50)); | 216 SkRect bounds = SkRect::MakeWH(SkIntToScalar(50), SkIntToScalar(50)); |
| 217 SkScalar dx = bounds.width() * 4/3; | 217 SkScalar dx = bounds.width() * 4/3; |
| 218 SkScalar dy = bounds.height() * 5; | 218 SkScalar dy = bounds.height() * 5; |
| (...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 273 | 273 |
| 274 static skiagm::GM* F0(void*) { return new StrokesGM; } | 274 static skiagm::GM* F0(void*) { return new StrokesGM; } |
| 275 static skiagm::GM* F1(void*) { return new Strokes2GM; } | 275 static skiagm::GM* F1(void*) { return new Strokes2GM; } |
| 276 static skiagm::GM* F2(void*) { return new Strokes3GM; } | 276 static skiagm::GM* F2(void*) { return new Strokes3GM; } |
| 277 static skiagm::GM* F3(void*) { return new Strokes4GM; } | 277 static skiagm::GM* F3(void*) { return new Strokes4GM; } |
| 278 | 278 |
| 279 static skiagm::GMRegistry R0(F0); | 279 static skiagm::GMRegistry R0(F0); |
| 280 static skiagm::GMRegistry R1(F1); | 280 static skiagm::GMRegistry R1(F1); |
| 281 static skiagm::GMRegistry R2(F2); | 281 static skiagm::GMRegistry R2(F2); |
| 282 static skiagm::GMRegistry R3(F3); | 282 static skiagm::GMRegistry R3(F3); |
| OLD | NEW |