<!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>[178903] branches/safari-600.5-branch</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/178903">178903</a></dd>
<dt>Author</dt> <dd>matthew_hanson@apple.com</dd>
<dt>Date</dt> <dd>2015-01-22 01:31:59 -0800 (Thu, 22 Jan 2015)</dd>
</dl>

<h3>Log Message</h3>
<pre>Merge <a href="http://trac.webkit.org/projects/webkit/changeset/172797">r172797</a>. rdar://problem/19451324</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#branchessafari6005branchLayoutTestsChangeLog">branches/safari-600.5-branch/LayoutTests/ChangeLog</a></li>
<li><a href="#branchessafari6005branchLayoutTestsTestExpectations">branches/safari-600.5-branch/LayoutTests/TestExpectations</a></li>
<li><a href="#branchessafari6005branchSourceWebCoreChangeLog">branches/safari-600.5-branch/Source/WebCore/ChangeLog</a></li>
<li><a href="#branchessafari6005branchSourceWebCorerenderingRenderObjectcpp">branches/safari-600.5-branch/Source/WebCore/rendering/RenderObject.cpp</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdashedatallexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-at-all-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdashedatallhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-at-all.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdashedexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdashedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdottedatallexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-at-all-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdottedatallhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-at-all.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdottedexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdottedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdoubleatallexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-at-all-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdoubleatallhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-at-all.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdoubleexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingdoublehtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintinggrooveatallexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-groove-at-all-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintinggrooveatallhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-groove-at-all.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintinginsetatallexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-at-all-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintinginsetatallhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-at-all.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintinginsetexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintinginsethtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingoutsetatallexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-at-all-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingoutsetatallhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-at-all.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingoutsetexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingoutsethtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingridgeatallexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-ridge-at-all-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingridgeatallhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-ridge-at-all.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingsolidatallexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-at-all-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingsolidatallhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-at-all.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingsolidexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordersborderpaintingsolidhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordershidpiborderpaintinggrooveexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-groove-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordershidpiborderpaintinggroovehtml">branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-groove.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordershidpiborderpaintingridgeexpectedhtml">branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-ridge-expected.html</a></li>
<li><a href="#branchessafari6005branchLayoutTestsfastbordershidpiborderpaintingridgehtml">branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-ridge.html</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="branchessafari6005branchLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: branches/safari-600.5-branch/LayoutTests/ChangeLog (178902 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/ChangeLog        2015-01-22 09:31:49 UTC (rev 178902)
+++ branches/safari-600.5-branch/LayoutTests/ChangeLog        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -1,5 +1,54 @@
</span><span class="cx"> 2015-01-22  Matthew Hanson  &lt;matthew_hanson@apple.com&gt;
</span><span class="cx"> 
</span><ins>+        Merge r172797. rdar://problem/19451324
+
+    2014-08-20  Zalan Bujtas  &lt;zalan@apple.com&gt;
+
+            Dashed/dotted borders do not paint.
+            https://bugs.webkit.org/show_bug.cgi?id=135898
+
+            Reviewed by Simon Fraser.
+
+            *-at-all files test that we always paint borders.
+            The other set of files test that borders are painted properly. They take
+            advantage of the fact that borders with radius use a different painting code path.
+
+            * TestExpectations:
+            * fast/borders/border-painting-dashed-at-all-expected.html: Added.
+            * fast/borders/border-painting-dashed-at-all.html: Added.
+            * fast/borders/border-painting-dashed-expected.html: Added.
+            * fast/borders/border-painting-dashed.html: Added.
+            * fast/borders/border-painting-dotted-at-all-expected.html: Added.
+            * fast/borders/border-painting-dotted-at-all.html: Added.
+            * fast/borders/border-painting-dotted-expected.html: Added.
+            * fast/borders/border-painting-dotted.html: Added.
+            * fast/borders/border-painting-double-at-all-expected.html: Added.
+            * fast/borders/border-painting-double-at-all.html: Added.
+            * fast/borders/border-painting-double-expected.html: Added.
+            * fast/borders/border-painting-double.html: Added.
+            * fast/borders/border-painting-groove-at-all-expected.html: Added.
+            * fast/borders/border-painting-groove-at-all.html: Added.
+            * fast/borders/border-painting-inset-at-all-expected.html: Added.
+            * fast/borders/border-painting-inset-at-all.html: Added.
+            * fast/borders/border-painting-inset-expected.html: Added.
+            * fast/borders/border-painting-inset.html: Added.
+            * fast/borders/border-painting-outset-at-all-expected.html: Added.
+            * fast/borders/border-painting-outset-at-all.html: Added.
+            * fast/borders/border-painting-outset-expected.html: Added.
+            * fast/borders/border-painting-outset.html: Added.
+            * fast/borders/border-painting-ridge-at-all-expected.html: Added.
+            * fast/borders/border-painting-ridge-at-all.html: Added.
+            * fast/borders/border-painting-solid-at-all-expected.html: Added.
+            * fast/borders/border-painting-solid-at-all.html: Added.
+            * fast/borders/border-painting-solid-expected.html: Added.
+            * fast/borders/border-painting-solid.html: Added.
+            * fast/borders/hidpi-border-painting-groove-expected.html: Added.
+            * fast/borders/hidpi-border-painting-groove.html: Added.
+            * fast/borders/hidpi-border-painting-ridge-expected.html: Added.
+            * fast/borders/hidpi-border-painting-ridge.html: Added.
+
+2015-01-22  Matthew Hanson  &lt;matthew_hanson@apple.com&gt;
+
</ins><span class="cx">         Merge r172504. rdar://problem/19451367
</span><span class="cx"> 
</span><span class="cx">     2014-08-12  Myles C. Maxfield  &lt;mmaxfield@apple.com&gt;
</span></span></pre></div>
<a id="branchessafari6005branchLayoutTestsTestExpectations"></a>
<div class="modfile"><h4>Modified: branches/safari-600.5-branch/LayoutTests/TestExpectations (178902 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/TestExpectations        2015-01-22 09:31:49 UTC (rev 178902)
+++ branches/safari-600.5-branch/LayoutTests/TestExpectations        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -137,3 +137,8 @@
</span><span class="cx"> fast/inline/hidpi-selection-gap-overlaps-inline-selection.html [ Skip ]
</span><span class="cx"> fast/multicol/mixed-opacity-fixed-test.html [ Skip ]
</span><span class="cx"> fast/inline/hidpi-selection-gap-overlaps-inline-selection.html [ Skip ]
</span><ins>+
+# border painting diff (Path vs. drawLine)
+webkit.org/b/136078 fast/borders/border-painting-dashed.html [ ImageOnlyFailure ]
+webkit.org/b/136078 fast/borders/border-painting-dotted.html [ ImageOnlyFailure ]
+webkit.org/b/136078 fast/borders/border-painting-double.html [ ImageOnlyFailure ]
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdashedatallexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-at-all-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-at-all-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-at-all-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,31 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  div {
+    position: absolute;
+    top: 0px;
+    width: 1px;
+    background-color: red;
+  }
+  
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      var e = document.createElement(&quot;div&quot;);
+      e.style.left = x + &quot;px&quot;;
+      e.style.height = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      borderWidth += 1;
+      w = 10 * i;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdashedatallhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-at-all.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-at-all.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-at-all.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,46 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    top: 0px;
+    height: 10px;
+    border-top: dashed red;
+  }
+  
+  .hide {
+    position: fixed;
+    top: 0px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.borderTopWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hideBox = document.createElement(&quot;div&quot;);
+      hideBox.className = &quot;hide&quot;;
+      hideBox.style.left = x + 1 + &quot;px&quot;;
+      hideBox.style.width = w - 1 + &quot;px&quot;;
+      hideBox.style.height = borderWidth + &quot;px&quot;;
+      document.body.appendChild(hideBox);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdashedexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,80 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted. It takes advantage of the fact that borders with radius get through a different code path (Path vs. drawLine).&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: dashed;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      e.style.borderRadius = borderWidth + 1 + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdashedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dashed.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,79 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: dashed;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdottedatallexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-at-all-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-at-all-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-at-all-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,31 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dotted borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  div {
+    position: absolute;
+    top: 0px;
+    width: 1px;
+    background-color: red;
+  }
+  
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      var e = document.createElement(&quot;div&quot;);
+      e.style.left = x + &quot;px&quot;;
+      e.style.height = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      borderWidth += 1;
+      w = 10 * i;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdottedatallhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-at-all.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-at-all.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-at-all.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,46 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    top: 0px;
+    height: 10px;
+    border-top: dotted red;
+  }
+  
+  .hide {
+    position: fixed;
+    top: 0px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.borderTopWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hideBox = document.createElement(&quot;div&quot;);
+      hideBox.className = &quot;hide&quot;;
+      hideBox.style.left = x + 1 + &quot;px&quot;;
+      hideBox.style.width = w - 1 + &quot;px&quot;;
+      hideBox.style.height = borderWidth + &quot;px&quot;;
+      document.body.appendChild(hideBox);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdottedexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,80 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dotted borders are painted. It takes advantage of the fact that borders with radius get through a different code path (Path vs. drawLine).&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: dotted;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      e.style.borderRadius = borderWidth + 1 + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdottedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-dotted.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,79 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dotted borders are painted.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: dotted;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdoubleatallexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-at-all-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-at-all-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-at-all-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,32 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that double borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  div {
+    position: absolute;
+    top: 0px;
+    height: 1px;
+    background-color: red;
+  }
+  
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+
+      var e = document.createElement(&quot;div&quot;);
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdoubleatallhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-at-all.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-at-all.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-at-all.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,47 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    top: 0px;
+    height: 10px;
+    border-top: double red;
+  }
+  
+  .hide {
+    position: fixed;
+    top: 0px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.borderTopWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hideBox = document.createElement(&quot;div&quot;);
+      hideBox.className = &quot;hide&quot;;
+      hideBox.style.top = &quot;1px&quot;;
+      hideBox.style.left = x + &quot;px&quot;;
+      hideBox.style.width = w + &quot;px&quot;;
+      hideBox.style.height = borderWidth + &quot;px&quot;;
+      document.body.appendChild(hideBox);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdoubleexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,80 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that double borders are painted. It takes advantage of the fact that borders with radius get through a different code path (Path vs. drawLine).&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: double;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 3;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      e.style.borderRadius = borderWidth + 1 + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins><span class="cx">\ No newline at end of file
</span></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingdoublehtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-double.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,79 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that double borders are painted.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: double;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 3;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintinggrooveatallexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-groove-at-all-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-groove-at-all-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-groove-at-all-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,32 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that groove borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  div {
+    position: absolute;
+    background-color: red;
+  }
+  
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+
+      var e = document.createElement(&quot;div&quot;);
+      e.style.top =  borderWidth / 2 + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.height =  borderWidth / 2 + &quot;px&quot;;
+      e.style.width =  w + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintinggrooveatallhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-groove-at-all.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-groove-at-all.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-groove-at-all.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,46 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    top: 0px;
+    height: 10px;
+    border-top: groove red;
+  }
+  
+  .hide {
+    position: fixed;
+    top: 0px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.borderTopWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hideBox = document.createElement(&quot;div&quot;);
+      hideBox.className = &quot;hide&quot;;
+      hideBox.style.left = x + &quot;px&quot;;
+      hideBox.style.width = w + &quot;px&quot;;
+      hideBox.style.height = borderWidth / 2 + &quot;px&quot;;
+      document.body.appendChild(hideBox);
+
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintinginsetatallexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-at-all-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-at-all-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-at-all-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,32 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that inset borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  div {
+    position: absolute;
+    top: 10px;
+    background-color: red;
+  }
+  
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+
+      var e = document.createElement(&quot;div&quot;);
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintinginsetatallhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-at-all.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-at-all.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-at-all.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,34 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    top: 0px;
+    height: 10px;
+    border-bottom: inset red;
+  }
+  
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.borderBottomWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintinginsetexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,80 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that inset borders are painted. It takes advantage of the fact that borders with radius get through a different code path (Path vs. drawLine).&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: inset;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      e.style.borderRadius = borderWidth + 1 + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintinginsethtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-inset.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,79 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that inset borders are painted.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: inset;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingoutsetatallexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-at-all-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-at-all-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-at-all-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,33 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  div {
+    position: absolute;
+    top: 0px;
+    width: 1px;
+    background-color: red;
+  }
+  
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+
+      var e = document.createElement(&quot;div&quot;);
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingoutsetatallhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-at-all.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-at-all.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-at-all.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,34 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    top: 0px;
+    height: 10px;
+    border-top: outset red;
+  }
+  
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.borderTopWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingoutsetexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,80 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that outset borders are painted. It takes advantage of the fact that borders with radius get through a different code path (Path vs. drawLine).&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: outset;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      var e = document.createElement(&quot;div&quot;);
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      e.style.borderRadius = borderWidth + 1 + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingoutsethtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-outset.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,79 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that outset borders are painted.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: outset;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      var e = document.createElement(&quot;div&quot;);
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingridgeatallexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-ridge-at-all-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-ridge-at-all-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-ridge-at-all-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,32 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  div {
+    position: absolute;
+    top: 0px;
+    background-color: red;
+  }
+  
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+
+      var e = document.createElement(&quot;div&quot;);
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = borderWidth / 2 + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingridgeatallhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-ridge-at-all.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-ridge-at-all.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-ridge-at-all.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,47 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    top: 0px;
+    height: 10px;
+    border-top: ridge red;
+  }
+  
+  .hide {
+    position: fixed;
+    top: 0px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.borderTopWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hideBox = document.createElement(&quot;div&quot;);
+      hideBox.className = &quot;hide&quot;;
+      hideBox.style.top =  borderWidth / 2 + &quot;px&quot;;
+      hideBox.style.left = x + &quot;px&quot;;
+      hideBox.style.width = w + &quot;px&quot;;
+      hideBox.style.height = borderWidth / 2 + &quot;px&quot;;
+      document.body.appendChild(hideBox);
+
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingsolidatallexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-at-all-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-at-all-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-at-all-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,32 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  div {
+    position: absolute;
+    top: 0px;
+    background-color: red;
+  }
+  
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+
+      var e = document.createElement(&quot;div&quot;);
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingsolidatallhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-at-all.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-at-all.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-at-all.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,33 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that dashed borders are painted at all.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    top: 0px;
+    height: 10px;
+    border-top: solid red;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  for (var i = 1; i &lt; 10; ++i) {
+      w = 10 * i;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.borderTopWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingsolidexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,80 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that solid borders are painted. It takes advantage of the fact that borders with radius get through a different code path (Path vs. drawLine).&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: solid;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      e.style.borderRadius = borderWidth + 1 + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordersborderpaintingsolidhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/border-painting-solid.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,79 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that solid borders are painted.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: solid;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordershidpiborderpaintinggrooveexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-groove-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-groove-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-groove-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,80 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that groove borders are painted. It takes advantage of the fact that borders with radius get through a different code path (Path vs. drawLine).&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: groove;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      e.style.borderRadius = borderWidth + 1 + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordershidpiborderpaintinggroovehtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-groove.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-groove.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-groove.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,79 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that groove borders are painted.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: groove;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordershidpiborderpaintingridgeexpectedhtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-ridge-expected.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-ridge-expected.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-ridge-expected.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,80 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that ridge borders are painted. It takes advantage of the fact that borders with radius get through a different code path (Path vs. drawLine).&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: ridge;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      e.style.borderRadius = borderWidth + 1 + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchLayoutTestsfastbordershidpiborderpaintingridgehtml"></a>
<div class="addfile"><h4>Added: branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-ridge.html (0 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-ridge.html                                (rev 0)
+++ branches/safari-600.5-branch/LayoutTests/fast/borders/hidpi-border-painting-ridge.html        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -0,0 +1,79 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This test that ridge borders are painted.&lt;/title&gt;
+&lt;style&gt;
+  .borderBox {
+    position: absolute;
+    width: 30px;
+    height: 30px;
+    border-style: ridge;
+    border-color: red;
+  }
+  
+  .hide {
+    position: fixed;
+    width: 4px;
+    height: 4px;
+    background-color: white;
+  }
+&lt;/style&gt;
+&lt;head&gt;
+&lt;body&gt;
+&lt;script&gt;
+  var borderWidth = 1;
+  var x = 0;
+  var y = 0;
+  var cornerBoxSize = 0;
+  for (var i = 0; i &lt; 10; ++i) {
+      w = 20 * i;
+      h = 20 * i;
+      cornerBoxSize = 2 * borderWidth;
+      
+      var e = document.createElement(&quot;div&quot;);
+      e.className = &quot;borderBox&quot;;
+      e.style.top =  y + &quot;px&quot;;
+      e.style.left = x + &quot;px&quot;;
+      e.style.width = w + &quot;px&quot;;
+      e.style.height = h + &quot;px&quot;;
+      e.style.borderWidth = borderWidth + &quot;px&quot;;
+      document.body.appendChild(e);
+
+      var hb1 = document.createElement(&quot;div&quot;);
+      hb1.className = &quot;hide&quot;;
+      hb1.style.top = y + &quot;px&quot;;
+      hb1.style.left = x + &quot;px&quot;;
+      hb1.style.width = cornerBoxSize + &quot;px&quot;;
+      hb1.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb1);
+
+      var hb2 = document.createElement(&quot;div&quot;);
+      hb2.className = &quot;hide&quot;;
+      hb2.style.top = y + &quot;px&quot;;
+      hb2.style.left = x + w + &quot;px&quot;;
+      hb2.style.width = cornerBoxSize + &quot;px&quot;;
+      hb2.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb2);
+
+      var hb3 = document.createElement(&quot;div&quot;);
+      hb3.className = &quot;hide&quot;;
+      hb3.style.top = y + h + &quot;px&quot;;
+      hb3.style.left = x + &quot;px&quot;;
+      hb3.style.width = cornerBoxSize + &quot;px&quot;;
+      hb3.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb3);
+
+      var hb4 = document.createElement(&quot;div&quot;);
+      hb4.className = &quot;hide&quot;;
+      hb4.style.top = y + w + &quot;px&quot;;
+      hb4.style.left = x + h + &quot;px&quot;;
+      hb4.style.width = cornerBoxSize + &quot;px&quot;;
+      hb4.style.height = cornerBoxSize + &quot;px&quot;;
+      document.body.appendChild(hb4);
+      
+      borderWidth += 1;
+      x += (w + 2 * borderWidth);
+  }
+&lt;/script&gt;
+&lt;/body&gt;
+&lt;/html&gt;
</ins></span></pre></div>
<a id="branchessafari6005branchSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: branches/safari-600.5-branch/Source/WebCore/ChangeLog (178902 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/Source/WebCore/ChangeLog        2015-01-22 09:31:49 UTC (rev 178902)
+++ branches/safari-600.5-branch/Source/WebCore/ChangeLog        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -1,5 +1,41 @@
</span><span class="cx"> 2015-01-22  Matthew Hanson  &lt;matthew_hanson@apple.com&gt;
</span><span class="cx"> 
</span><ins>+        Merge r172797. rdar://problem/19451324
+
+    2014-08-20  Zalan Bujtas  &lt;zalan@apple.com&gt;
+
+            Dashed/dotted borders do not paint.
+            https://bugs.webkit.org/show_bug.cgi?id=135898
+
+            Reviewed by Simon Fraser.
+
+            Remove the empty line checks for drawLines. There's no need to protect the graphics
+            context from empty lines.
+
+            Tests: fast/borders/border-painting-dashed-at-all.html
+                   fast/borders/border-painting-dashed.html
+                   fast/borders/border-painting-dotted-at-all.html
+                   fast/borders/border-painting-dotted.html
+                   fast/borders/border-painting-double-at-all.html
+                   fast/borders/border-painting-double.html
+                   fast/borders/border-painting-groove-at-all.html
+                   fast/borders/border-painting-inset-at-all.html
+                   fast/borders/border-painting-inset.html
+                   fast/borders/border-painting-outset-at-all.html
+                   fast/borders/border-painting-outset.html
+                   fast/borders/border-painting-ridge-at-all.html
+                   fast/borders/border-painting-solid-at-all.html
+                   fast/borders/border-painting-solid.html
+                   fast/borders/hidpi-border-painting-groove.html
+                   fast/borders/hidpi-border-painting-ridge.html
+
+            * rendering/RenderObject.cpp:
+            (WebCore::RenderObject::drawLineForBoxSide):
+            (WebCore::drawBorderLineRect): Deleted.
+            (WebCore::drawBorderLine): Deleted.
+
+2015-01-22  Matthew Hanson  &lt;matthew_hanson@apple.com&gt;
+
</ins><span class="cx">         Merge r172504. rdar://problem/19451367
</span><span class="cx"> 
</span><span class="cx">     2014-08-12  Myles C. Maxfield  &lt;mmaxfield@apple.com&gt;
</span></span></pre></div>
<a id="branchessafari6005branchSourceWebCorerenderingRenderObjectcpp"></a>
<div class="modfile"><h4>Modified: branches/safari-600.5-branch/Source/WebCore/rendering/RenderObject.cpp (178902 => 178903)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-600.5-branch/Source/WebCore/rendering/RenderObject.cpp        2015-01-22 09:31:49 UTC (rev 178902)
+++ branches/safari-600.5-branch/Source/WebCore/rendering/RenderObject.cpp        2015-01-22 09:31:59 UTC (rev 178903)
</span><span class="lines">@@ -737,23 +737,6 @@
</span><span class="cx">     return toRenderBlock(o);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-static void drawBorderLineRect(GraphicsContext&amp; graphicsContext, const LayoutRect&amp; rect, float deviceScaleFactor)
-{
-    FloatRect pixelSnappedRect = pixelSnappedForPainting(rect, deviceScaleFactor);
-    if (pixelSnappedRect.isEmpty())
-        return;
-    graphicsContext.drawRect(pixelSnappedRect);
-}
-
-static void drawBorderLine(GraphicsContext&amp; graphicsContext, const LayoutPoint&amp; point1, const LayoutPoint&amp; point2, float deviceScaleFactor)
-{
-    FloatPoint p1 = roundedForPainting(point1, deviceScaleFactor);
-    FloatPoint p2 = roundedForPainting(point2, deviceScaleFactor);
-    if (p1.x() == p2.x() || p1.y() == p2.y())
-        return;
-    graphicsContext.drawLine(point1, point2);
-}
-
</del><span class="cx"> void RenderObject::drawLineForBoxSide(GraphicsContext* graphicsContext, float x1, float y1, float x2, float y2,
</span><span class="cx">     BoxSide side, Color color, EBorderStyle borderStyle, float adjacentWidth1, float adjacentWidth2, bool antialias) const
</span><span class="cx"> {
</span><span class="lines">@@ -797,11 +780,11 @@
</span><span class="cx">                 switch (side) {
</span><span class="cx">                     case BSBottom:
</span><span class="cx">                     case BSTop:
</span><del>-                        drawBorderLine(*graphicsContext, LayoutPoint(x1, adjustedY), LayoutPoint(x2, adjustedY), deviceScaleFactor);
</del><ins>+                        graphicsContext-&gt;drawLine(FloatPoint(x1, adjustedY), FloatPoint(x2, adjustedY));
</ins><span class="cx">                         break;
</span><span class="cx">                     case BSRight:
</span><span class="cx">                     case BSLeft:
</span><del>-                        drawBorderLine(*graphicsContext, LayoutPoint(adjustedX, y1), LayoutPoint(adjustedX, y2), deviceScaleFactor);
</del><ins>+                        graphicsContext-&gt;drawLine(FloatPoint(adjustedX, y1), FloatPoint(adjustedX, y2));
</ins><span class="cx">                         break;
</span><span class="cx">                 }
</span><span class="cx">                 graphicsContext-&gt;setShouldAntialias(wasAntialiased);
</span><span class="lines">@@ -824,13 +807,13 @@
</span><span class="cx">                 switch (side) {
</span><span class="cx">                     case BSTop:
</span><span class="cx">                     case BSBottom:
</span><del>-                        drawBorderLineRect(*graphicsContext, LayoutRect(x1, y1, length, thirdOfThickness), deviceScaleFactor);
-                        drawBorderLineRect(*graphicsContext, LayoutRect(x1, y2 - thirdOfThickness, length, thirdOfThickness), deviceScaleFactor);
</del><ins>+                        graphicsContext-&gt;drawRect(pixelSnappedForPainting(x1, y1, length, thirdOfThickness, deviceScaleFactor));
+                        graphicsContext-&gt;drawRect(pixelSnappedForPainting(x1, y2 - thirdOfThickness, length, thirdOfThickness, deviceScaleFactor));
</ins><span class="cx">                         break;
</span><span class="cx">                     case BSLeft:
</span><span class="cx">                     case BSRight:
</span><del>-                        drawBorderLineRect(*graphicsContext, LayoutRect(x1, y1, thirdOfThickness, length), deviceScaleFactor);
-                        drawBorderLineRect(*graphicsContext, LayoutRect(x2 - thirdOfThickness, y1, thirdOfThickness, length), deviceScaleFactor);
</del><ins>+                        graphicsContext-&gt;drawRect(pixelSnappedForPainting(x1, y1, thirdOfThickness, length, deviceScaleFactor));
+                        graphicsContext-&gt;drawRect(pixelSnappedForPainting(x2 - thirdOfThickness, y1, thirdOfThickness, length, deviceScaleFactor));
</ins><span class="cx">                         break;
</span><span class="cx">                 }
</span><span class="cx"> 
</span><span class="lines">@@ -976,7 +959,7 @@
</span><span class="cx">                 graphicsContext-&gt;setFillColor(color, style.colorSpace());
</span><span class="cx">                 bool wasAntialiased = graphicsContext-&gt;shouldAntialias();
</span><span class="cx">                 graphicsContext-&gt;setShouldAntialias(antialias);
</span><del>-                drawBorderLineRect(*graphicsContext, LayoutRect(x1, y1, x2 - x1, y2 - y1), deviceScaleFactor);
</del><ins>+                graphicsContext-&gt;drawRect(pixelSnappedForPainting(x1, y1, x2 - x1, y2 - y1, deviceScaleFactor));
</ins><span class="cx">                 graphicsContext-&gt;setShouldAntialias(wasAntialiased);
</span><span class="cx">                 graphicsContext-&gt;setStrokeStyle(oldStrokeStyle);
</span><span class="cx">                 return;
</span><span class="lines">@@ -987,8 +970,7 @@
</span><span class="cx">             y1 = roundToDevicePixel(y1, deviceScaleFactor);
</span><span class="cx">             x2 = roundToDevicePixel(x2, deviceScaleFactor);
</span><span class="cx">             y2 = roundToDevicePixel(y2, deviceScaleFactor);
</span><del>-            if (x1 == x2 || y1 == y2)
-                return;
</del><ins>+
</ins><span class="cx">             FloatPoint quad[4];
</span><span class="cx">             switch (side) {
</span><span class="cx">                 case BSTop:
</span></span></pre>
</div>
</div>

</body>
</html>