#include <SkStrokeRec.h>
|
| SkStrokeRec (InitStyle style) |
|
| SkStrokeRec (const SkPaint &, SkPaint::Style, SkScalar resScale=1) |
|
| SkStrokeRec (const SkPaint &, SkScalar resScale=1) |
|
Style | getStyle () const |
|
SkScalar | getWidth () const |
|
SkScalar | getMiter () const |
|
SkPaint::Cap | getCap () const |
|
SkPaint::Join | getJoin () const |
|
bool | isHairlineStyle () const |
|
bool | isFillStyle () const |
|
void | setFillStyle () |
|
void | setHairlineStyle () |
|
void | setStrokeStyle (SkScalar width, bool strokeAndFill=false) |
| Specify the strokewidth, and optionally if you want stroke + fill. More...
|
|
void | setStrokeParams (SkPaint::Cap cap, SkPaint::Join join, SkScalar miterLimit) |
|
SkScalar | getResScale () const |
|
void | setResScale (SkScalar rs) |
|
bool | needToApply () const |
| Returns true if this specifes any thick stroking, i.e. More...
|
|
bool | applyToPath (SkPath *dst, const SkPath &src) const |
| Apply these stroke parameters to the src path, returning the result in dst. More...
|
|
void | applyToPaint (SkPaint *paint) const |
| Apply these stroke parameters to a paint. More...
|
|
SkScalar | getInflationRadius () const |
| Gives a conservative value for the outset that should applied to a geometries bounds to account for any inflation due to applying this strokeRec to the geometry. More...
|
|
bool | hasEqualEffect (const SkStrokeRec &other) const |
| Compare if two SkStrokeRecs have an equal effect on a path. More...
|
|
◆ InitStyle
Enumerator |
---|
kHairline_InitStyle | |
kFill_InitStyle | |
◆ Style
Enumerator |
---|
kHairline_Style | |
kFill_Style | |
kStroke_Style | |
kStrokeAndFill_Style | |
◆ SkStrokeRec() [1/3]
◆ SkStrokeRec() [2/3]
◆ SkStrokeRec() [3/3]
◆ applyToPaint()
void SkStrokeRec::applyToPaint |
( |
SkPaint * |
paint | ) |
const |
Apply these stroke parameters to a paint.
◆ applyToPath()
bool SkStrokeRec::applyToPath |
( |
SkPath * |
dst, |
|
|
const SkPath & |
src |
|
) |
| const |
Apply these stroke parameters to the src path, returning the result in dst.
If there was no change (i.e. style == hairline or fill) this returns false and dst is unchanged. Otherwise returns true and the result is stored in dst.
src and dst may be the same path.
◆ getCap()
◆ getInflationRadius()
SkScalar SkStrokeRec::getInflationRadius |
( |
| ) |
const |
Gives a conservative value for the outset that should applied to a geometries bounds to account for any inflation due to applying this strokeRec to the geometry.
◆ GetInflationRadius() [1/2]
Equivalent to: SkStrokeRec rec(paint, style); rec.getInflationRadius(); This does not account for other effects on the paint (i.e.
path effect).
◆ GetInflationRadius() [2/2]
◆ getJoin()
◆ getMiter()
SkScalar SkStrokeRec::getMiter |
( |
| ) |
const |
|
inline |
◆ getResScale()
SkScalar SkStrokeRec::getResScale |
( |
| ) |
const |
|
inline |
◆ getStyle()
Style SkStrokeRec::getStyle |
( |
| ) |
const |
◆ getWidth()
SkScalar SkStrokeRec::getWidth |
( |
| ) |
const |
|
inline |
◆ hasEqualEffect()
bool SkStrokeRec::hasEqualEffect |
( |
const SkStrokeRec & |
other | ) |
const |
|
inline |
Compare if two SkStrokeRecs have an equal effect on a path.
Equal SkStrokeRecs produce equal paths. Equality of produced paths does not take the ResScale parameter into account.
◆ isFillStyle()
bool SkStrokeRec::isFillStyle |
( |
| ) |
const |
|
inline |
◆ isHairlineStyle()
bool SkStrokeRec::isHairlineStyle |
( |
| ) |
const |
|
inline |
◆ needToApply()
bool SkStrokeRec::needToApply |
( |
| ) |
const |
|
inline |
Returns true if this specifes any thick stroking, i.e.
applyToPath() will return true.
◆ setFillStyle()
void SkStrokeRec::setFillStyle |
( |
| ) |
|
◆ setHairlineStyle()
void SkStrokeRec::setHairlineStyle |
( |
| ) |
|
◆ setResScale()
void SkStrokeRec::setResScale |
( |
SkScalar |
rs | ) |
|
|
inline |
◆ setStrokeParams()
◆ setStrokeStyle()
void SkStrokeRec::setStrokeStyle |
( |
SkScalar |
width, |
|
|
bool |
strokeAndFill = false |
|
) |
| |
Specify the strokewidth, and optionally if you want stroke + fill.
Note, if width==0, then this request is taken to mean: strokeAndFill==true -> new style will be Fill strokeAndFill==false -> new style will be Hairline
◆ kStyleCount
The documentation for this class was generated from the following file: