| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 #ifndef SkStrokeRec_DEFINED | 8 #ifndef SkStrokeRec_DEFINED |
| 9 #define SkStrokeRec_DEFINED | 9 #define SkStrokeRec_DEFINED |
| 10 | 10 |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 SkStrokeRec(const SkStrokeRec&); | 23 SkStrokeRec(const SkStrokeRec&); |
| 24 SkStrokeRec(const SkPaint&, SkPaint::Style); | 24 SkStrokeRec(const SkPaint&, SkPaint::Style); |
| 25 explicit SkStrokeRec(const SkPaint&); | 25 explicit SkStrokeRec(const SkPaint&); |
| 26 | 26 |
| 27 enum Style { | 27 enum Style { |
| 28 kHairline_Style, | 28 kHairline_Style, |
| 29 kFill_Style, | 29 kFill_Style, |
| 30 kStroke_Style, | 30 kStroke_Style, |
| 31 kStrokeAndFill_Style | 31 kStrokeAndFill_Style |
| 32 }; | 32 }; |
| 33 enum { |
| 34 kStyleCount = kStrokeAndFill_Style + 1 |
| 35 }; |
| 33 | 36 |
| 34 Style getStyle() const; | 37 Style getStyle() const; |
| 35 SkScalar getWidth() const { return fWidth; } | 38 SkScalar getWidth() const { return fWidth; } |
| 36 SkScalar getMiter() const { return fMiterLimit; } | 39 SkScalar getMiter() const { return fMiterLimit; } |
| 37 SkPaint::Cap getCap() const { return fCap; } | 40 SkPaint::Cap getCap() const { return fCap; } |
| 38 SkPaint::Join getJoin() const { return fJoin; } | 41 SkPaint::Join getJoin() const { return fJoin; } |
| 39 | 42 |
| 40 bool isHairlineStyle() const { | 43 bool isHairlineStyle() const { |
| 41 return kHairline_Style == this->getStyle(); | 44 return kHairline_Style == this->getStyle(); |
| 42 } | 45 } |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 95 | 98 |
| 96 | 99 |
| 97 SkScalar fWidth; | 100 SkScalar fWidth; |
| 98 SkScalar fMiterLimit; | 101 SkScalar fMiterLimit; |
| 99 SkPaint::Cap fCap; | 102 SkPaint::Cap fCap; |
| 100 SkPaint::Join fJoin; | 103 SkPaint::Join fJoin; |
| 101 bool fStrokeAndFill; | 104 bool fStrokeAndFill; |
| 102 }; | 105 }; |
| 103 | 106 |
| 104 #endif | 107 #endif |
| OLD | NEW |