Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Functions
RRect_copy_const_SkRRect.cpp File Reference
#include "tools/fiddle/examples.h"

Go to the source code of this file.

Functions

 REG_FIDDLE (RRect_copy_const_SkRRect, 256, 60, false, 0)
 

Function Documentation

◆ REG_FIDDLE()

REG_FIDDLE ( RRect_copy_const_SkRRect  ,
256  ,
60  ,
false  ,
 
)

Definition at line 5 of file RRect_copy_const_SkRRect.cpp.

5 {
6void draw(SkCanvas* canvas) {
7 SkRRect rrect = SkRRect::MakeRect({10, 10, 100, 50});
8 SkRRect rrect2(rrect);
9 rrect2.inset(20, 20);
10 SkPaint p;
11 p.setStyle(SkPaint::kStroke_Style);
12 p.setStrokeWidth(10);
13 canvas->drawRRect(rrect, p);
14 canvas->drawRRect(rrect2, p);
15}
16} // END FIDDLE
static void draw(SkCanvas *canvas, SkRect &target, int x, int y)
Definition aaclip.cpp:27
void drawRRect(const SkRRect &rrect, const SkPaint &paint)
@ kStroke_Style
set to stroke geometry
Definition SkPaint.h:194
static SkRRect MakeRect(const SkRect &r)
Definition SkRRect.h:149
SkRRect rrect
Definition SkRecords.h:232