OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2006 The Android Open Source Project | 2 * Copyright 2006 The Android Open Source Project |
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 SkCanvas_DEFINED | 8 #ifndef SkCanvas_DEFINED |
9 #define SkCanvas_DEFINED | 9 #define SkCanvas_DEFINED |
10 | 10 |
(...skipping 1334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1345 | 1345 |
1346 virtual void willSave() {} | 1346 virtual void willSave() {} |
1347 // Overriders should call the corresponding INHERITED method up the inherita
nce chain. | 1347 // Overriders should call the corresponding INHERITED method up the inherita
nce chain. |
1348 virtual SaveLayerStrategy getSaveLayerStrategy(const SaveLayerRec&) { | 1348 virtual SaveLayerStrategy getSaveLayerStrategy(const SaveLayerRec&) { |
1349 return kFullLayer_SaveLayerStrategy; | 1349 return kFullLayer_SaveLayerStrategy; |
1350 } | 1350 } |
1351 virtual void willRestore() {} | 1351 virtual void willRestore() {} |
1352 virtual void didRestore() {} | 1352 virtual void didRestore() {} |
1353 virtual void didConcat(const SkMatrix&) {} | 1353 virtual void didConcat(const SkMatrix&) {} |
1354 virtual void didSetMatrix(const SkMatrix&) {} | 1354 virtual void didSetMatrix(const SkMatrix&) {} |
1355 virtual void didTranslate(SkScalar dx, SkScalar dy) { | |
1356 this->didConcat(SkMatrix::MakeTrans(dx, dy)); | |
1357 } | |
1358 | 1355 |
1359 #ifdef SK_EXPERIMENTAL_SHADOWING | 1356 #ifdef SK_EXPERIMENTAL_SHADOWING |
1360 virtual void didTranslateZ(SkScalar) {} | 1357 virtual void didTranslateZ(SkScalar) {} |
1361 #endif | 1358 #endif |
1362 | 1359 |
1363 virtual void onDrawAnnotation(const SkRect&, const char key[], SkData* value
); | 1360 virtual void onDrawAnnotation(const SkRect&, const char key[], SkData* value
); |
1364 virtual void onDrawDRRect(const SkRRect&, const SkRRect&, const SkPaint&); | 1361 virtual void onDrawDRRect(const SkRRect&, const SkRRect&, const SkPaint&); |
1365 | 1362 |
1366 virtual void onDrawText(const void* text, size_t byteLength, SkScalar x, | 1363 virtual void onDrawText(const void* text, size_t byteLength, SkScalar x, |
1367 SkScalar y, const SkPaint& paint); | 1364 SkScalar y, const SkPaint& paint); |
(...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1684 | 1681 |
1685 class SkCanvasClipVisitor { | 1682 class SkCanvasClipVisitor { |
1686 public: | 1683 public: |
1687 virtual ~SkCanvasClipVisitor(); | 1684 virtual ~SkCanvasClipVisitor(); |
1688 virtual void clipRect(const SkRect&, SkRegion::Op, bool antialias) = 0; | 1685 virtual void clipRect(const SkRect&, SkRegion::Op, bool antialias) = 0; |
1689 virtual void clipRRect(const SkRRect&, SkRegion::Op, bool antialias) = 0; | 1686 virtual void clipRRect(const SkRRect&, SkRegion::Op, bool antialias) = 0; |
1690 virtual void clipPath(const SkPath&, SkRegion::Op, bool antialias) = 0; | 1687 virtual void clipPath(const SkPath&, SkRegion::Op, bool antialias) = 0; |
1691 }; | 1688 }; |
1692 | 1689 |
1693 #endif | 1690 #endif |
OLD | NEW |