diff options
| author | rmistry@google.com <rmistry@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-08-23 18:19:56 +0000 |
|---|---|---|
| committer | rmistry@google.com <rmistry@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-08-23 18:19:56 +0000 |
| commit | ae933ce0ea5fd9d21cb6ef2cee7e729d32690aac (patch) | |
| tree | 62d80e33b16679d01454cf814977a7030d3a5462 /samplecode/SampleDraw.cpp | |
| parent | d6176b0dcacb124539e0cfd051e6d93a9782f020 (diff) | |
Result of running tools/sanitize_source_files.py (which was added in https://codereview.appspot.com/6465078/)
This CL is part III of IV (I broke down the 1280 files into 4 CLs).
Review URL: https://codereview.appspot.com/6475053
git-svn-id: http://skia.googlecode.com/svn/trunk@5264 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'samplecode/SampleDraw.cpp')
| -rw-r--r-- | samplecode/SampleDraw.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/samplecode/SampleDraw.cpp b/samplecode/SampleDraw.cpp index c4185859a2..e1f62fe07b 100644 --- a/samplecode/SampleDraw.cpp +++ b/samplecode/SampleDraw.cpp @@ -13,19 +13,19 @@ static void test_clearonlayers(SkCanvas* canvas) { SkCanvas& c = *canvas; - + SkPaint paint; paint.setColor(SK_ColorBLUE); paint.setStyle(SkPaint::kStrokeAndFill_Style); SkRect rect = SkRect::MakeXYWH(25, 25, 50, 50); c.drawRect(rect, paint); - + c.clipRect(rect); - + c.saveLayer(NULL, NULL); rect = SkRect::MakeXYWH(50, 10, 40, 80); c.clipRect(rect, SkRegion::kUnion_Op); - + rect = SkRect::MakeXYWH(50, 0, 50, 100); // You might draw something here, but it's not necessary. // paint.setColor(SK_ColorRED); @@ -37,11 +37,11 @@ static void test_clearonlayers(SkCanvas* canvas) { static void test_strokerect(SkCanvas* canvas, const SkRect& r) { SkPaint p; - + p.setAntiAlias(true); p.setStyle(SkPaint::kStroke_Style); p.setStrokeWidth(4); - + canvas->drawRect(r, p); SkPath path; @@ -61,27 +61,27 @@ static void test_strokerect(SkCanvas* canvas) { r.offset(0.25f, 0.3333f); test_strokerect(canvas, r); canvas->translate(0, 20); - + r.set(10, 10, 14.5f, 14.5f); r.offset(0.25f, 0.3333f); test_strokerect(canvas, r); canvas->translate(0, 20); - + r.set(10, 10, 14.5f, 20); r.offset(0.25f, 0.3333f); test_strokerect(canvas, r); canvas->translate(0, 20); - + r.set(10, 10, 20, 14.5f); r.offset(0.25f, 0.3333f); test_strokerect(canvas, r); canvas->translate(0, 20); - + r.set(10, 10, 20, 20); r.offset(0.25f, 0.3333f); test_strokerect(canvas, r); canvas->translate(0, 20); - + } class Draw : public SkRefCnt { @@ -236,7 +236,7 @@ public: } virtual Draw* create(const SkPoint&, const SkPoint&) = 0; - + private: SkPaint fPaint; }; @@ -291,7 +291,7 @@ public: } return NULL; } - + protected: // overrides from SkEventSink virtual bool onQuery(SkEvent* evt) { |
