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 SkPaint_DEFINED | 8 #ifndef SkPaint_DEFINED |
9 #define SkPaint_DEFINED | 9 #define SkPaint_DEFINED |
10 | 10 |
(...skipping 543 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
554 /** Set or clear the patheffect object. | 554 /** Set or clear the patheffect object. |
555 <p /> | 555 <p /> |
556 Pass NULL to clear any previous patheffect. | 556 Pass NULL to clear any previous patheffect. |
557 As a convenience, the parameter passed is also returned. | 557 As a convenience, the parameter passed is also returned. |
558 If a previous patheffect exists, its reference count is decremented. | 558 If a previous patheffect exists, its reference count is decremented. |
559 If patheffect is not NULL, its reference count is incremented. | 559 If patheffect is not NULL, its reference count is incremented. |
560 @param effect May be NULL. The new patheffect to be installed in the | 560 @param effect May be NULL. The new patheffect to be installed in the |
561 paint | 561 paint |
562 @return effect | 562 @return effect |
563 */ | 563 */ |
564 SkPathEffect* setPathEffect(SkPathEffect* effect); | |
565 void setPathEffect(sk_sp<SkPathEffect>); | 564 void setPathEffect(sk_sp<SkPathEffect>); |
| 565 #ifdef SK_SUPPORT_LEGACY_PATHEFFECT_PTR |
| 566 SkPathEffect* setPathEffect(SkPathEffect* effect) { |
| 567 this->setPathEffect(sk_ref_sp(effect)); |
| 568 return effect; |
| 569 } |
| 570 #endif |
566 | 571 |
567 /** Get the paint's maskfilter object. | 572 /** Get the paint's maskfilter object. |
568 <p /> | 573 <p /> |
569 The maskfilter reference count is not affected. | 574 The maskfilter reference count is not affected. |
570 @return the paint's maskfilter (or NULL) | 575 @return the paint's maskfilter (or NULL) |
571 */ | 576 */ |
572 SkMaskFilter* getMaskFilter() const { return fMaskFilter.get(); } | 577 SkMaskFilter* getMaskFilter() const { return fMaskFilter.get(); } |
573 | 578 |
574 /** Set or clear the maskfilter object. | 579 /** Set or clear the maskfilter object. |
575 <p /> | 580 <p /> |
(...skipping 570 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1146 friend class GrStencilAndCoverTextContext; | 1151 friend class GrStencilAndCoverTextContext; |
1147 friend class GrPathRendering; | 1152 friend class GrPathRendering; |
1148 friend class GrTextUtils; | 1153 friend class GrTextUtils; |
1149 friend class GrGLPathRendering; | 1154 friend class GrGLPathRendering; |
1150 friend class SkScalerContext; | 1155 friend class SkScalerContext; |
1151 friend class SkTextBaseIter; | 1156 friend class SkTextBaseIter; |
1152 friend class SkCanonicalizePaint; | 1157 friend class SkCanonicalizePaint; |
1153 }; | 1158 }; |
1154 | 1159 |
1155 #endif | 1160 #endif |
OLD | NEW |