• Home
  • Raw
  • Download

Lines Matching refs:paint

22 static bool setFont(SkPaint* paint, const char name[]) {  in setFont()  argument
25 paint->setTypeface(tf)->unref(); in setFont()
57 SkPaint paint; in drawGrad() local
58 paint.setShader(s)->unref(); in drawGrad()
60 canvas->drawRect(r, paint); in drawGrad()
76 SkPaint paint; in onDraw() local
77 setFont(&paint, sk_tool_utils::platform_font_name("serif")); in onDraw()
78 paint.setTextSize(SkIntToScalar(16)); in onDraw()
79 paint.setAntiAlias(true); in onDraw()
80 paint.setLCDRenderText(true); in onDraw()
84 paint.setColor(fg[i]); in onDraw()
89 canvas->drawText(text, len, x, y, paint); in onDraw()
90 y += paint.getTextSize() * 2; in onDraw()
112 static void set_face(SkPaint* paint) { in set_face() argument
114 SkSafeUnref(paint->setTypeface(face)); in set_face()
117 static void draw_pair(SkCanvas* canvas, SkPaint* paint, SkShader* shader) { in draw_pair() argument
121 paint->setShader(nullptr); in draw_pair()
122 canvas->drawText(text, len, 10, 20, *paint); in draw_pair()
123 paint->setShader(SkShader::CreateColorShader(paint->getColor()))->unref(); in draw_pair()
124 canvas->drawText(text, len, 10, 40, *paint); in draw_pair()
125 paint->setShader(shader); in draw_pair()
126 canvas->drawText(text, len, 10, 60, *paint); in draw_pair()
164 SkPaint paint; in onDraw() local
165 paint.setAntiAlias(true); in onDraw()
166 paint.setLCDRenderText(true); in onDraw()
167 paint.setTextSize(18); in onDraw()
168 set_face(&paint); in onDraw()
171 paint.setColor(fColors[i]); in onDraw()
172 draw_pair(canvas, &paint, fShaders[i]); in onDraw()