<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[160130] trunk</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/160130">160130</a></dd>
<dt>Author</dt> <dd>zoltan@webkit.org</dd>
<dt>Date</dt> <dd>2013-12-04 14:53:24 -0800 (Wed, 04 Dec 2013)</dd>
</dl>

<h3>Log Message</h3>
<pre>[CSS Shapes] Support inset for shape-outside
&lt;https://webkit.org/b/125112&gt;

Reviewed by David Hyatt.

Source/WebCore:

This patch adds inset support for shape-outside. Parsing has previously landed in <a href="http://trac.webkit.org/projects/webkit/changeset/159968">r159968</a>.
Specification: http://dev.w3.org/csswg/css-shapes/#supported-basic-shapes

Tests: fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left.html
       fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right.html
       fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left.html
       fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right.html
       fast/shapes/shape-outside-floats/shape-outside-floats-inset.html

* platform/LengthSize.h:
(WebCore::LengthSize::floatSize): Add conversion to FloatSize.
* rendering/shapes/Shape.cpp:
(WebCore::Shape::createShape): Handle inset case.

LayoutTests:

* fast/shapes/resources/rounded-rectangle.js: Add support to generate partially rounded rectangles.
(scanConvertRoundedRectangleOutside):
(genLeftRoundedRectFloatShapeOutsideRefTest):
(genRightRoundedRectFloatShapeOutsideRefTest):
* fast/shapes/shape-outside-floats/shape-outside-floats-inset-expected.html: Added.
* fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left-expected.html: Added.
* fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left.html: Added.
* fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right-expected.html: Added.
* fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right.html: Added.
* fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left-expected.html: Added.
* fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left.html: Added.
* fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right-expected.html: Added.
* fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right.html: Added.
* fast/shapes/shape-outside-floats/shape-outside-floats-inset.html: Added.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkLayoutTestsfastshapesresourcesroundedrectanglejs">trunk/LayoutTests/fast/shapes/resources/rounded-rectangle.js</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreplatformLengthSizeh">trunk/Source/WebCore/platform/LengthSize.h</a></li>
<li><a href="#trunkSourceWebCorerenderingshapesShapecpp">trunk/Source/WebCore/rendering/shapes/Shape.cpp</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetexpectedhtml">trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-expected.html</a></li>
<li><a href="#trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedbottomleftexpectedhtml">trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left-expected.html</a></li>
<li><a href="#trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedbottomlefthtml">trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left.html</a></li>
<li><a href="#trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedbottomrightexpectedhtml">trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right-expected.html</a></li>
<li><a href="#trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedbottomrighthtml">trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right.html</a></li>
<li><a href="#trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedtopleftexpectedhtml">trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left-expected.html</a></li>
<li><a href="#trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedtoplefthtml">trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left.html</a></li>
<li><a href="#trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedtoprightexpectedhtml">trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right-expected.html</a></li>
<li><a href="#trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedtoprighthtml">trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right.html</a></li>
<li><a href="#trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsethtml">trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset.html</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (160129 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog        2013-12-04 22:51:37 UTC (rev 160129)
+++ trunk/LayoutTests/ChangeLog        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -1,3 +1,25 @@
</span><ins>+2013-12-04  Zoltan Horvath  &lt;zoltan@webkit.org&gt;
+
+        [CSS Shapes] Support inset for shape-outside
+        &lt;https://webkit.org/b/125112&gt;
+
+        Reviewed by David Hyatt.
+
+        * fast/shapes/resources/rounded-rectangle.js: Add support to generate partially rounded rectangles.
+        (scanConvertRoundedRectangleOutside):
+        (genLeftRoundedRectFloatShapeOutsideRefTest):
+        (genRightRoundedRectFloatShapeOutsideRefTest):
+        * fast/shapes/shape-outside-floats/shape-outside-floats-inset-expected.html: Added.
+        * fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left-expected.html: Added.
+        * fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left.html: Added.
+        * fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right-expected.html: Added.
+        * fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right.html: Added.
+        * fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left-expected.html: Added.
+        * fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left.html: Added.
+        * fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right-expected.html: Added.
+        * fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right.html: Added.
+        * fast/shapes/shape-outside-floats/shape-outside-floats-inset.html: Added.
+
</ins><span class="cx"> 2013-12-04  Bear Travis  &lt;betravis@adobe.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Web Inspector: [CSS Shapes] Support raster shape visualizations
</span></span></pre></div>
<a id="trunkLayoutTestsfastshapesresourcesroundedrectanglejs"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/fast/shapes/resources/rounded-rectangle.js (160129 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/shapes/resources/rounded-rectangle.js        2013-12-04 22:51:37 UTC (rev 160129)
+++ trunk/LayoutTests/fast/shapes/resources/rounded-rectangle.js        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -3,20 +3,27 @@
</span><span class="cx">     return rx * Math.sqrt(1 - (yi * yi) / (ry * ry));
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-function scanConvertRoundedRectangleOutside(r, height, lineHeight)
</del><ins>+function scanConvertRoundedRectangleOutside(r, height, lineHeight, corner)
</ins><span class="cx"> {
</span><span class="cx">     var intervals = [];
</span><ins>+    var upperCorner = true;
+    var lowerCorner = true;
</ins><span class="cx"> 
</span><ins>+    if (corner == &quot;upper&quot;)
+        lowerCorner = false;
+    else if (corner == &quot;lower&quot;)
+        upperCorner = false;
+
</ins><span class="cx">     for (var y = 0; y &lt; height; y += lineHeight) {
</span><span class="cx">         if (y + lineHeight &lt;= r.y || y &gt;= r.y + r.height)
</span><span class="cx">             continue;
</span><span class="cx"> 
</span><del>-        if (y + lineHeight &lt; r.y + r.ry) {
</del><ins>+        if (upperCorner &amp;&amp; (y + lineHeight &lt; r.y + r.ry)) {
</ins><span class="cx">             // within the upper rounded corner part of the rectangle
</span><span class="cx">             var dx = ellipseXIntercept(y + lineHeight - r.y - r.ry, r.rx, r.ry);
</span><span class="cx">             intervals.push( { y: y, left: r.x + r.rx - dx, right: r.x + r.width - r.rx + dx} );
</span><span class="cx">         }
</span><del>-        else if (y &gt; r.y + r.height - r.ry) {
</del><ins>+        else if (lowerCorner &amp;&amp; (y &gt; r.y + r.height - r.ry)) {
</ins><span class="cx">             // within the lower rounded corner part of the rectangle
</span><span class="cx">             var dx = ellipseXIntercept(y - (r.y + r.height - r.ry), r.rx, r.ry);
</span><span class="cx">             intervals.push( { y: y, left: r.x + r.rx - dx, right: r.x + r.width - r.rx + dx} );
</span><span class="lines">@@ -37,7 +44,7 @@
</span><span class="cx"> function genLeftRoundedRectFloatShapeOutsideRefTest(args)
</span><span class="cx"> {
</span><span class="cx">     var leftRoundedRect = args.roundedRect;
</span><del>-    var leftRoundedRectIntervals = scanConvertRoundedRectangleOutside(leftRoundedRect, args.containerHeight, args.lineHeight);
</del><ins>+    var leftRoundedRectIntervals = scanConvertRoundedRectangleOutside(leftRoundedRect, args.containerHeight, args.lineHeight, args.corner);
</ins><span class="cx">     var leftFloatDivs = leftRoundedRectIntervals.map(function(interval) { 
</span><span class="cx">         var width = SubPixelLayout.snapToLayoutUnit(interval.right);
</span><span class="cx">         var cls = &quot;left-&quot; + args.floatElementClassSuffix;
</span><span class="lines">@@ -50,11 +57,11 @@
</span><span class="cx"> {
</span><span class="cx">     var rightRoundedRect = Object.create(args.roundedRect);
</span><span class="cx">     rightRoundedRect.x = args.containerWidth - args.roundedRect.width;
</span><del>-    var rightRoundedRectIntervals = scanConvertRoundedRectangleOutside(rightRoundedRect, args.containerHeight, args.lineHeight);
</del><ins>+    var rightRoundedRectIntervals = scanConvertRoundedRectangleOutside(rightRoundedRect, args.containerHeight, args.lineHeight, args.corner);
</ins><span class="cx">     var rightFloatDivs = rightRoundedRectIntervals.map(function(interval) { 
</span><span class="cx">         var width = args.containerWidth - SubPixelLayout.snapToLayoutUnit(interval.left);
</span><span class="cx">         var cls = &quot;right-&quot; + args.floatElementClassSuffix;
</span><span class="cx">         return '&lt;div class=&quot;' + cls + '&quot; style=&quot;width:' + width + 'px&quot;&gt;&lt;/div&gt;'; 
</span><span class="cx">     });
</span><span class="cx">     document.getElementById(&quot;right-&quot; + args.insertElementIdSuffix).insertAdjacentHTML('afterend', rightFloatDivs.join(&quot;\n&quot;));
</span><del>-}
</del><span class="cx">\ No newline at end of file
</span><ins>+}
</ins></span></pre></div>
<a id="trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetexpectedhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-expected.html (0 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-expected.html                                (rev 0)
+++ trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-expected.html        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -0,0 +1,74 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+    &lt;style&gt;
+        .test {
+            font: 20px/1 Ahem, sans-serif;
+            border: 1px solid black;
+            line-height: 20px;
+        }
+        .container {
+            width: 60px;
+            height: 60px;
+            display: inline-block;
+        }
+        .float {
+            width: 40px;
+            height: 40px;
+        }
+        .top {
+            height: 20px;
+        }
+        .right {
+            width: 20px;
+        }
+        .bottom {
+            height: 20px;
+        }
+        .left {
+            width: 20px;
+        }
+    &lt;/style&gt;
+&lt;/head&gt;
+&lt;body&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      XXX
+      &lt;div style=&quot;float: left&quot; class=&quot;float top&quot;&gt;&lt;/div&gt;
+      X
+      XXX
+    &lt;/div&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      XXX
+      &lt;div style=&quot;float: right&quot; class=&quot;float top&quot;&gt;&lt;/div&gt;
+      X
+      XXX
+    &lt;/div&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      &lt;div style=&quot;float: left&quot; class=&quot;float right&quot;&gt;&lt;/div&gt;
+      XX
+      XX
+      XXX
+    &lt;/div&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      &lt;div style=&quot;float: left&quot; class=&quot;float bottom&quot;&gt;&lt;/div&gt;
+      X
+      XXX
+      XXX
+    &lt;/div&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      &lt;div style=&quot;float: right&quot; class=&quot;float bottom&quot;&gt;&lt;/div&gt;
+      X
+      XXX
+      XXX
+    &lt;/div&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      &lt;div style=&quot;float: right&quot; class=&quot;float left&quot;&gt;&lt;/div&gt;
+      XX
+      XX
+      XXX
+    &lt;/div&gt;
+
+    &lt;p&gt;Requires Ahem font. Each container contains a different inset shape-outside.
+    &lt;p&gt;Bug &lt;a href=&quot;http://webkit.org/b/125112&quot;&gt;125112&lt;/a&gt;: [CSS Shapes] Support inset for shape-outside&lt;/p&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedbottomleftexpectedhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left-expected.html (0 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left-expected.html                                (rev 0)
+++ trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left-expected.html        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -0,0 +1,65 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;style&gt;
+.container {
+    position: relative;
+    font: 20px/1 Ahem, sans-serif;
+    width: 500px;
+    height: 200px;
+    border: 1px solid black;
+}
+
+.rounded-rect {
+    width: 320px;
+    height: 160px;
+    border-bottom-left-radius: 60px 40px;
+    border: 1px solid blue;
+}
+
+#right-rounded-rect-outline {
+    position: absolute;
+    top: 20px;
+    right: 0px;
+}
+
+.right-rounded-rect-float-line {
+    float: right;
+    clear: right;
+    height: 20px;
+}
+&lt;/style&gt;
+&lt;body&gt;
+&lt;div class=&quot;container&quot; style=&quot;text-align: right&quot;&gt;
+X&lt;br/&gt;
+    &lt;div id=&quot;right-rounded-rect-outline&quot; class=&quot;rounded-rect&quot;&gt;&lt;/div&gt;
+    &lt;!-- generated right-rounded-rect-float-line divs will be inserted here --&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X
+&lt;/div&gt;
+&lt;script src=&quot;../resources/rounded-rectangle.js&quot;&gt;&lt;/script&gt;
+&lt;script src=&quot;../resources/subpixel-utils.js&quot;&gt;&lt;/script&gt;
+&lt;script&gt;
+genRightRoundedRectFloatShapeOutsideRefTest({
+    roundedRect: {x: 0, y: 22, width: 322, height: 160, rx: 60, ry: 40},
+    containerWidth: 500,
+    containerHeight: 200,
+    lineHeight: 20,
+    floatElementClassSuffix: &quot;rounded-rect-float-line&quot;,
+    insertElementIdSuffix: &quot;rounded-rect-outline&quot;,
+    corner: &quot;lower&quot;
+});
+&lt;/script&gt;
+
+&lt;p&gt;Requires Ahem font. There is a 0px size inset applied on the right float with 60px/40px bottom left radius.&lt;br&gt;
+The black squares should trace the left side of the rounded rectangle's blue outline.&lt;/p&gt;
+&lt;p&gt;Bug &lt;a href=&quot;http://webkit.org/b/125112&quot;&gt;125112&lt;/a&gt;: [CSS Shapes] Support inset for shape-outside&lt;/p&gt;
+
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedbottomlefthtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left.html (0 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left.html                                (rev 0)
+++ trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left.html        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -0,0 +1,38 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;style&gt;
+.container {
+    font: 20px/1 Ahem, sans-serif;
+    width: 500px;
+    height: 200px;
+    border: 1px solid black;
+}
+
+.rounded-rect {
+    width: 320px;
+    height: 160px;
+    border: 1px solid blue;
+    border-bottom-left-radius: 60px 40px;
+    -webkit-shape-outside: inset(0px 0px 0px 0px round 0 0 0 60px / 0 0 0 40px);
+}
+&lt;/style&gt;
+
+&lt;body&gt;
+&lt;div class=&quot;container&quot; style=&quot;text-align: right&quot;&gt;
+X&lt;br/&gt;
+    &lt;div style=&quot;float: right&quot; class=&quot;rounded-rect&quot;&gt;&lt;/div&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X
+&lt;/div&gt;
+
+&lt;p&gt;Requires Ahem font. There is a 0px size inset applied on the right float with 60px/40px bottom left radius.&lt;br&gt;
+The black squares should trace the left side of the rounded rectangle's blue outline.&lt;/p&gt;
+&lt;p&gt;Bug &lt;a href=&quot;http://webkit.org/b/125112&quot;&gt;125112&lt;/a&gt;: [CSS Shapes] Support inset for shape-outside&lt;/p&gt;
+
+&lt;/body&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedbottomrightexpectedhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right-expected.html (0 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right-expected.html                                (rev 0)
+++ trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right-expected.html        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -0,0 +1,65 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;style&gt;
+.container {
+    position: relative;
+    font: 20px/1 Ahem, sans-serif;
+    width: 500px;
+    height: 200px;
+    border: 1px solid black;
+}
+
+.rounded-rect {
+    width: 320px;
+    height: 160px;
+    border-bottom-right-radius: 200px 40px;
+    border: 1px solid blue;
+}
+
+#left-rounded-rect-outline {
+    position: absolute;
+    top: 20px;
+}
+
+.left-rounded-rect-float-line {
+    float: left;
+    clear: left;
+    height: 20px;
+}
+&lt;/style&gt;
+&lt;body&gt;
+&lt;div class=&quot;container&quot;&gt;
+X&lt;br/&gt;
+    &lt;div id=&quot;left-rounded-rect-outline&quot; class=&quot;rounded-rect&quot;&gt;&lt;/div&gt;
+    &lt;!-- generated right-rounded-rect-float-line divs will be inserted here --&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+&amp;nbsp;X
+&lt;/div&gt;
+&lt;script src=&quot;../resources/rounded-rectangle.js&quot;&gt;&lt;/script&gt;
+&lt;script src=&quot;../resources/subpixel-utils.js&quot;&gt;&lt;/script&gt;
+&lt;script&gt;
+genLeftRoundedRectFloatShapeOutsideRefTest({
+    roundedRect: {x: 0, y: 22, width: 322, height: 160, rx: 200, ry: 40},
+    containerWidth: 500,
+    containerHeight: 200,
+    lineHeight: 20,
+    floatElementClassSuffix: &quot;rounded-rect-float-line&quot;,
+    insertElementIdSuffix: &quot;rounded-rect-outline&quot;,
+    corner: &quot;lower&quot;
+});
+&lt;/script&gt;
+
+&lt;p&gt;Requires Ahem font. There is a 0px size inset applied on the right float with 60px/40px bottom right radius.&lt;br&gt;
+The black squares should trace the right side of the rounded rectangle's blue outline.
+The last line contains a non-break space in order to avoid rounding/painting problems in the test.&lt;/p&gt;
+&lt;p&gt;Bug &lt;a href=&quot;http://webkit.org/b/125112&quot;&gt;125112&lt;/a&gt;: [CSS Shapes] Support inset for shape-outside&lt;/p&gt;
+
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedbottomrighthtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right.html (0 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right.html                                (rev 0)
+++ trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right.html        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -0,0 +1,39 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;style&gt;
+.container {
+    font: 20px/1 Ahem, sans-serif;
+    width: 500px;
+    height: 200px;
+    border: 1px solid black;
+}
+
+.rounded-rect {
+    width: 320px;
+    height: 160px;
+    border: 1px solid blue;
+    border-bottom-right-radius: 200px 40px;
+    -webkit-shape-outside: inset(0px 0px 0px 0px round 0 0 200px 0 / 0 0 40px);
+}
+&lt;/style&gt;
+
+&lt;body&gt;
+&lt;div class=&quot;container&quot;&gt;
+X&lt;br/&gt;
+    &lt;div style=&quot;float: left&quot; class=&quot;rounded-rect&quot;&gt;&lt;/div&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+&amp;nbsp;X
+&lt;/div&gt;
+
+&lt;p&gt;Requires Ahem font. There is a 0px size inset applied on the right float with 60px/40px bottom right radius.&lt;br&gt;
+The black squares should trace the right side of the rounded rectangle's blue outline.
+The last line contains a non-break space in order to avoid rounding/painting problems in the test.&lt;/p&gt;
+&lt;p&gt;Bug &lt;a href=&quot;http://webkit.org/b/125112&quot;&gt;125112&lt;/a&gt;: [CSS Shapes] Support inset for shape-outside&lt;/p&gt;
+
+&lt;/body&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedtopleftexpectedhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left-expected.html (0 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left-expected.html                                (rev 0)
+++ trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left-expected.html        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -0,0 +1,66 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;style&gt;
+.container {
+    position: relative;
+    font: 20px/1 Ahem, sans-serif;
+    width: 500px;
+    height: 200px;
+    border: 1px solid black;
+}
+
+.rounded-rect {
+    width: 320px;
+    height: 160px;
+    border-top-left-radius: 60px 40px;
+    border: 1px solid blue;
+}
+
+#right-rounded-rect-outline {
+    position: absolute;
+    top: 20px;
+    right: 0px;
+}
+
+
+.right-rounded-rect-float-line {
+    float: right;
+    clear: right;
+    height: 20px;
+}
+&lt;/style&gt;
+&lt;body&gt;
+&lt;div class=&quot;container&quot; style=&quot;text-align: right&quot;&gt;
+X&lt;br/&gt;
+    &lt;div id=&quot;right-rounded-rect-outline&quot; class=&quot;rounded-rect&quot;&gt;&lt;/div&gt;
+    &lt;!-- generated right-rounded-rect-float-line divs will be inserted here --&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X
+&lt;/div&gt;
+&lt;script src=&quot;../resources/rounded-rectangle.js&quot;&gt;&lt;/script&gt;
+&lt;script src=&quot;../resources/subpixel-utils.js&quot;&gt;&lt;/script&gt;
+&lt;script&gt;
+genRightRoundedRectFloatShapeOutsideRefTest({
+    roundedRect: {x: 0, y: 20, width: 322, height: 160, rx: 60, ry: 40},
+    containerWidth: 500,
+    containerHeight: 200,
+    lineHeight: 20,
+    floatElementClassSuffix: &quot;rounded-rect-float-line&quot;,
+    insertElementIdSuffix: &quot;rounded-rect-outline&quot;,
+    corner: &quot;upper&quot;
+});
+&lt;/script&gt;
+
+&lt;p&gt;Requires Ahem font. There is a 0px size inset applied on the right float with 60px/40px top left radius.&lt;br&gt;
+The black squares should trace the left side of the rounded rectangle's blue outline.&lt;/p&gt;
+&lt;p&gt;Bug &lt;a href=&quot;http://webkit.org/b/125112&quot;&gt;125112&lt;/a&gt;: [CSS Shapes] Support inset for shape-outside&lt;/p&gt;
+
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedtoplefthtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left.html (0 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left.html                                (rev 0)
+++ trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left.html        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -0,0 +1,38 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;style&gt;
+.container {
+    font: 20px/1 Ahem, sans-serif;
+    width: 500px;
+    height: 200px;
+    border: 1px solid black;
+}
+
+.rounded-rect {
+    width: 320px;
+    height: 160px;
+    border: 1px solid blue;
+    border-top-left-radius: 60px 40px;
+    -webkit-shape-outside: inset(0px 0px 0px 0px round 60px 0 0 0 / 40px);
+}
+&lt;/style&gt;
+
+&lt;body&gt;
+&lt;div class=&quot;container&quot; style=&quot;text-align: right&quot;&gt;
+X&lt;br/&gt;
+    &lt;div style=&quot;float: right&quot; class=&quot;rounded-rect&quot;&gt;&lt;/div&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X&lt;br/&gt;
+X
+&lt;/div&gt;
+
+&lt;p&gt;Requires Ahem font. There is a 0px size inset applied on the right float with 60px/40px top left radius.&lt;br&gt;
+The black squares should trace the left side of the rounded rectangle's blue outline.&lt;/p&gt;
+&lt;p&gt;Bug &lt;a href=&quot;http://webkit.org/b/125112&quot;&gt;125112&lt;/a&gt;: [CSS Shapes] Support inset for shape-outside&lt;/p&gt;
+
+&lt;/body&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedtoprightexpectedhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right-expected.html (0 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right-expected.html                                (rev 0)
+++ trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right-expected.html        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -0,0 +1,60 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;style&gt;
+.container {
+    position: relative;
+    font: 20px/1 Ahem, sans-serif;
+    width: 500px;
+    height: 200px;
+    border: 1px solid black;
+}
+
+.rounded-rect {
+    width: 320px;
+    height: 160px;
+    border-top-right-radius: 200px 40px;
+    border: 1px solid blue;
+}
+
+#left-rounded-rect-outline {
+    position: absolute;
+    top: 20px;
+}
+
+.left-rounded-rect-float-line {
+    float: left;
+    clear: left;
+    height: 20px;
+}
+&lt;/style&gt;
+&lt;body&gt;
+&lt;div class=&quot;container&quot;&gt;
+X&lt;br/&gt;
+    &lt;div id=&quot;left-rounded-rect-outline&quot; class=&quot;rounded-rect&quot;&gt;&lt;/div&gt;
+    &lt;!-- generated right-rounded-rect-float-line divs will be inserted here --&gt;
+&amp;nbsp;X&lt;br/&gt;
+X&lt;br/&gt;
+X
+&lt;/div&gt;
+&lt;script src=&quot;../resources/rounded-rectangle.js&quot;&gt;&lt;/script&gt;
+&lt;script src=&quot;../resources/subpixel-utils.js&quot;&gt;&lt;/script&gt;
+&lt;script&gt;
+genLeftRoundedRectFloatShapeOutsideRefTest({
+    roundedRect: {x: 0, y: 20, width: 322, height: 160, rx: 200, ry: 40},
+    containerWidth: 500,
+    containerHeight: 200,
+    lineHeight: 20,
+    floatElementClassSuffix: &quot;rounded-rect-float-line&quot;,
+    insertElementIdSuffix: &quot;rounded-rect-outline&quot;,
+    corner: &quot;upper&quot;
+});
+&lt;/script&gt;
+
+&lt;p&gt;Requires Ahem font. There is a 0px size inset applied on the right float with 60px/40px top right radius.&lt;br&gt;
+The black squares should trace the right side of the rounded rectangle's blue outline.
+The second line contains a non-break space in order to avoid rounding/painting problems in the test.&lt;/p&gt;
+&lt;p&gt;Bug &lt;a href=&quot;http://webkit.org/b/125112&quot;&gt;125112&lt;/a&gt;: [CSS Shapes] Support inset for shape-outside&lt;/p&gt;
+
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsetroundedtoprighthtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right.html (0 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right.html                                (rev 0)
+++ trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right.html        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -0,0 +1,34 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;style&gt;
+.container {
+    font: 20px/1 Ahem, sans-serif;
+    width: 500px;
+    height: 200px;
+    border: 1px solid black;
+}
+
+.rounded-rect {
+    width: 320px;
+    height: 160px;
+    border: 1px solid blue;
+    border-top-right-radius: 200px 40px;
+    -webkit-shape-outside: inset(0px 0px 0px 0px round 0 200px 0 0 / 0 40px);
+}
+&lt;/style&gt;
+
+&lt;body&gt;
+&lt;div class=&quot;container&quot;&gt;
+X&lt;br/&gt;
+    &lt;div style=&quot;float: left&quot; class=&quot;rounded-rect&quot;&gt;&lt;/div&gt;
+&amp;nbsp;X&lt;br/&gt;
+X&lt;br/&gt;
+X
+&lt;/div&gt;
+
+&lt;p&gt;Requires Ahem font. There is a 0px size inset applied on the right float with 60px/40px top right radius.&lt;br&gt;
+The black squares should trace the right side of the rounded rectangle's blue outline.
+The second line contains a non-break space in order to avoid rounding/painting problems in the test.&lt;/p&gt;
+&lt;p&gt;Bug &lt;a href=&quot;http://webkit.org/b/125112&quot;&gt;125112&lt;/a&gt;: [CSS Shapes] Support inset for shape-outside&lt;/p&gt;
+
+&lt;/body&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastshapesshapeoutsidefloatsshapeoutsidefloatsinsethtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset.html (0 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset.html                                (rev 0)
+++ trunk/LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-inset.html        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -0,0 +1,74 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;style&gt;
+    .test {
+        font: 20px/1 Ahem, sans-serif;
+        border: 1px solid black;
+        line-height: 20px;
+    }
+    .container {
+        width: 60px;
+        height: 60px;
+        display: inline-block;
+    }
+    .float {
+        width: 40px;
+        height: 40px;
+    }
+    .top {
+        -webkit-shape-outside: inset(20px 0 0 0);
+    }
+    .right {
+        -webkit-shape-outside: inset(0 20px 0 0);
+    }
+    .bottom {
+        -webkit-shape-outside: inset(0 0 20px 0);
+    }
+    .left {
+        -webkit-shape-outside: inset(0 0 0 20px);
+    }
+&lt;/style&gt;
+&lt;/head&gt;
+&lt;body&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      &lt;div style=&quot;float: left&quot; class=&quot;float top&quot;&gt;&lt;/div&gt;
+      XXX
+      X
+      XXX
+    &lt;/div&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      &lt;div style=&quot;float: right&quot; class=&quot;float top&quot;&gt;&lt;/div&gt;
+      XXX
+      X
+      XXX
+    &lt;/div&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      &lt;div style=&quot;float: left&quot; class=&quot;float right&quot;&gt;&lt;/div&gt;
+      XX
+      XX
+      XXX
+    &lt;/div&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      &lt;div style=&quot;float: left&quot; class=&quot;float bottom&quot;&gt;&lt;/div&gt;
+      X
+      XXX
+      XXX
+    &lt;/div&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      &lt;div style=&quot;float: right&quot; class=&quot;float bottom&quot;&gt;&lt;/div&gt;
+      X
+      XXX
+      XXX
+    &lt;/div&gt;
+    &lt;div class=&quot;test container&quot;&gt;
+      &lt;div style=&quot;float: right&quot; class=&quot;float left&quot;&gt;&lt;/div&gt;
+      XX
+      XX
+      XXX
+    &lt;/div&gt;
+
+    &lt;p&gt;Requires Ahem font. Each container contains a different inset shape-outside.&lt;/0&gt;
+    &lt;p&gt;Bug &lt;a href=&quot;http://webkit.org/b/125112&quot;&gt;125112&lt;/a&gt;: [CSS Shapes] Support inset for shape-outside&lt;/p&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (160129 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2013-12-04 22:51:37 UTC (rev 160129)
+++ trunk/Source/WebCore/ChangeLog        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -1,3 +1,24 @@
</span><ins>+2013-12-04  Zoltan Horvath  &lt;zoltan@webkit.org&gt;
+
+        [CSS Shapes] Support inset for shape-outside
+        &lt;https://webkit.org/b/125112&gt;
+
+        Reviewed by David Hyatt.
+
+        This patch adds inset support for shape-outside. Parsing has previously landed in r159968.
+        Specification: http://dev.w3.org/csswg/css-shapes/#supported-basic-shapes
+
+        Tests: fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left.html
+               fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right.html
+               fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left.html
+               fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right.html
+               fast/shapes/shape-outside-floats/shape-outside-floats-inset.html
+
+        * platform/LengthSize.h:
+        (WebCore::LengthSize::floatSize): Add conversion to FloatSize.
+        * rendering/shapes/Shape.cpp:
+        (WebCore::Shape::createShape): Handle inset case.
+
</ins><span class="cx"> 2013-12-04  Bear Travis  &lt;betravis@adobe.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Web Inspector: [CSS Shapes] Support raster shape visualizations
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformLengthSizeh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/LengthSize.h (160129 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/LengthSize.h        2013-12-04 22:51:37 UTC (rev 160129)
+++ trunk/Source/WebCore/platform/LengthSize.h        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -21,6 +21,7 @@
</span><span class="cx"> #ifndef LengthSize_h
</span><span class="cx"> #define LengthSize_h
</span><span class="cx"> 
</span><ins>+#include &quot;FloatSize.h&quot;
</ins><span class="cx"> #include &quot;Length.h&quot;
</span><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="lines">@@ -53,6 +54,11 @@
</span><span class="cx">         return LengthSize(m_width.blend(from.width(), progress), m_height.blend(from.height(), progress));
</span><span class="cx">     }
</span><span class="cx"> 
</span><ins>+    FloatSize floatSize() const
+    {
+        return FloatSize(m_width.value(), m_height.value());
+    }
+
</ins><span class="cx"> private:
</span><span class="cx">     Length m_width;
</span><span class="cx">     Length m_height;
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingshapesShapecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/shapes/Shape.cpp (160129 => 160130)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/shapes/Shape.cpp        2013-12-04 22:51:37 UTC (rev 160129)
+++ trunk/Source/WebCore/rendering/shapes/Shape.cpp        2013-12-04 22:53:24 UTC (rev 160130)
</span><span class="lines">@@ -222,6 +222,31 @@
</span><span class="cx">         break;
</span><span class="cx">     }
</span><span class="cx"> 
</span><ins>+    case BasicShape::BasicShapeInsetType: {
+        const BasicShapeInset* rectangle = static_cast&lt;const BasicShapeInset*&gt;(basicShape);
+        float left = floatValueForLength(rectangle-&gt;left(), boxWidth);
+        float top = floatValueForLength(rectangle-&gt;top(), boxHeight);
+
+        FloatRect rect(left,
+            top,
+            boxWidth - left - floatValueForLength(rectangle-&gt;right(), boxWidth),
+            boxHeight - top - floatValueForLength(rectangle-&gt;bottom(), boxHeight));
+        FloatRect logicalRect = physicalRectToLogical(rect, logicalBoxSize.height(), writingMode);
+
+        // FloatRoundedRect constuctor has different order for the corners: topLeft, topRight, bottomLeft, bottomRight
+        FloatRoundedRect logicalBounds(logicalRect,
+            rectangle-&gt;topLeftRadius().floatSize(),
+            rectangle-&gt;topRightRadius().floatSize(),
+            rectangle-&gt;bottomLeftRadius().floatSize(),
+            rectangle-&gt;bottomRightRadius().floatSize());
+
+        float shapeMargin = floatValueForLength(margin, 0);
+        float shapePadding = floatValueForLength(padding, 0);
+
+        shape = createBoxShape(logicalBounds, shapeMargin, shapePadding);
+        break;
+    }
+
</ins><span class="cx">     default:
</span><span class="cx">         ASSERT_NOT_REACHED();
</span><span class="cx">     }
</span></span></pre>
</div>
</div>

</body>
</html>