Changeset 51722 in webkit
- Timestamp:
- Dec 4, 2009 4:39:27 PM (14 years ago)
- Location:
- trunk/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebCore/ChangeLog
r51718 r51722 1 2009-12-04 Adam Langley <agl@google.com> 2 3 Reviewed by Eric Seidel. 4 5 Chromium: make rounded borders heavier. 6 7 Skia draws its rounded corners differently from the other ports. 8 Whereas they have anti-aliased clipping regions, Skia only has 1-bit 9 regions. (Which is technically more correct, but somewhat unhelpful 10 for us.) Instead, with Skia we use a layer and collect all the 11 clipping paths in effect. When the state is popped, we paint 12 transparency outside the clipping paths and merge the layer down. 13 14 This appears to cause rounded borders to look a little thin, which is 15 addressed in this patch. 16 17 This is well covered by existing tests but will require new baselines 18 in the Chromium tree. 19 20 https://bugs.webkit.org/show_bug.cgi?id=31778 21 22 * platform/graphics/skia/GraphicsContextSkia.cpp: 23 (WebCore::GraphicsContext::addInnerRoundedRectClip): 24 1 25 2009-12-04 Simon Fraser <simon.fraser@apple.com> 2 26 -
trunk/WebCore/platform/graphics/skia/GraphicsContextSkia.cpp
r50852 r51722 294 294 // only perform the inset if we won't invert r 295 295 if (2 * thickness < rect.width() && 2 * thickness < rect.height()) { 296 r.inset(SkIntToScalar(thickness), SkIntToScalar(thickness)); 296 // Adding one to the thickness doesn't make the border too thick as 297 // it's painted over afterwards. But without this adjustment the 298 // border appears a little anemic after anti-aliasing. 299 r.inset(SkIntToScalar(thickness + 1), SkIntToScalar(thickness + 1)); 297 300 path.addOval(r, SkPath::kCCW_Direction); 298 301 }
Note: See TracChangeset
for help on using the changeset viewer.