Currently, the contents of the box is correctly clipped by the region at the border box. However, the box decorations are clipped at the content box.
Created attachment 224368 [details] Patch
Comment on attachment 224368 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=224368&action=review > Source/WebCore/rendering/RenderRegion.cpp:525 > mappedRect.intersect(flowThreadPortionRect()); I think the correct order of operations is to expand the flowThreadPortionRect() with the paddings and then intersect. This way: 1. You expand only when actually clipping 2. You don't expand a rectangle already intersected with the flowThreadPortionRect() that doesn't need the extra space to display correctly. > Source/WebCore/rendering/RenderRegion.cpp:533 > + if (isFirstRegion()) { This should be startRegion. > Source/WebCore/rendering/RenderRegion.cpp:543 > + if (isLastRegion()) { This should be lastRegion.
Created attachment 224377 [details] Patch
Comment on attachment 224377 [details] Patch r=me. Before committing, please update the CL with the new helper you implemented. Thanks!
Created attachment 224381 [details] Patch for landing
Comment on attachment 224381 [details] Patch for landing Clearing flags on attachment: 224381 Committed r164231: <http://trac.webkit.org/changeset/164231>