| 1 |
// Copyright 2019 Google LLC. |
| 2 |
// Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. |
| 3 |
#include "tools/fiddle/examples.h" |
| 4 |
REG_FIDDLE(Canvas_getLocalClipBounds_2, 256, 256, true, 0) { |
| 5 |
void draw(SkCanvas* canvas) { |
| 6 |
SkCanvas local(256, 256); |
| 7 |
canvas = &local; |
| 8 |
SkRect bounds; |
| 9 |
SkDebugf("local bounds empty = %s\n", canvas->getLocalClipBounds(&bounds) |
| 10 |
? "false" : "true"); |
| 11 |
SkPath path; |
| 12 |
canvas->clipPath(path); |
| 13 |
SkDebugf("local bounds empty = %s\n", canvas->getLocalClipBounds(&bounds) |
| 14 |
? "false" : "true"); |
| 15 |
} |
| 16 |
} // END FIDDLE |