48 {
49 struct FillAndName {
52 };
53 constexpr FillAndName gFills[] = {
58 };
59 struct StyleAndName {
62 };
63 constexpr StyleAndName
gStyles[] = {
67 };
68
70 const char title[] = "Empty Paths Drawn Into Rectangle Clips With "
71 "Indicated Style and Fill";
73
76 int i = 0;
80 for (
size_t style = 0; style < std::size(
gStyles); ++style) {
81 for (size_t fill = 0; fill < std::size(gFills); ++fill) {
82 if (0 == i % 4) {
86 } else {
88 }
89 ++i;
90
91
95 this->drawEmpty(canvas,
color, rect,
97
104
109 labelFont, labelPaint);
111 labelFont, labelPaint);
112 }
113 }
116 }
SkStrokeRec::Style fStyle
constexpr SkColor SK_ColorBLACK
void drawRect(const SkRect &rect, const SkPaint &paint)
void translate(SkScalar dx, SkScalar dy)
void drawString(const char str[], SkScalar x, SkScalar y, const SkFont &font, const SkPaint &paint)
void setStyle(Style style)
void setColor(SkColor color)
void setAntiAlias(bool aa)
@ kStroke_Style
set to stroke geometry
@ kFill_Style
set to fill geometry
@ kStrokeAndFill_Style
sets to stroke and fill geometry
void setStrokeWidth(SkScalar width)
sk_sp< SkBlender > blender SkRect rect
font
Font Metadata and Metrics.
static constexpr SkRect MakeWH(float w, float h)
static constexpr SkFontStyle gStyles[]