Chromium Code Reviews| Index: src/core/SkDraw.cpp |
| diff --git a/src/core/SkDraw.cpp b/src/core/SkDraw.cpp |
| index 3532efd7e5e5e7d9fd27fd57754fea2610760465..cf744cea02e2db5c2836f304b1f53b1365daf099 100644 |
| --- a/src/core/SkDraw.cpp |
| +++ b/src/core/SkDraw.cpp |
| @@ -817,7 +817,11 @@ void SkDraw::drawRect(const SkRect& rect, const SkPaint& paint) const { |
| devRect.roundOut(&ir); |
| if (paint.getStyle() != SkPaint::kFill_Style) { |
| // extra space for hairlines |
| - ir.inset(-1, -1); |
| + if (paint.getStrokeWidth() == 0) { |
| + ir.outset(1, 1); |
| + } else { |
| + ir.outset(paint.getStrokeWidth(), paint.getStrokeWidth()); |
|
reed1
2014/09/09 13:05:49
stroke_width / 2 ?
|
| + } |
| } |
| if (fRC->quickReject(ir)) { |
| return; |