<!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>[194500] trunk</title>
</head>
<body>

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

<h3>Log Message</h3>
<pre>Simple line layout:: Add text-decoration support.
https://bugs.webkit.org/show_bug.cgi?id=152623

Reviewed by Antti Koivisto.

Source/WebCore:

This patch enables text-decoration for simple line layout.
-webkit-text-underline-position: under requires normal line layout context, skip it for now.

Test: fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration.html

* rendering/SimpleLineLayout.cpp:
(WebCore::SimpleLineLayout::canUseForStyle):
(WebCore::SimpleLineLayout::printReason):
* rendering/SimpleLineLayoutFunctions.cpp:
(WebCore::SimpleLineLayout::paintFlow): In case of multiple RenderText renderers (long text), it's ok
to pass the first text renderer as they all share the same set of decorations.

LayoutTests:

Existing tests cases also cover decoration correctness.

* fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration-expected.html: Added.
* fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration.html: Added.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorerenderingSimpleLineLayoutcpp">trunk/Source/WebCore/rendering/SimpleLineLayout.cpp</a></li>
<li><a href="#trunkSourceWebCorerenderingSimpleLineLayoutFunctionscpp">trunk/Source/WebCore/rendering/SimpleLineLayoutFunctions.cpp</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsfastcss3textcss3textdecorationsimplelinelayouttextdecorationexpectedhtml">trunk/LayoutTests/fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration-expected.html</a></li>
<li><a href="#trunkLayoutTestsfastcss3textcss3textdecorationsimplelinelayouttextdecorationhtml">trunk/LayoutTests/fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration.html</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (194499 => 194500)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog        2016-01-02 12:19:55 UTC (rev 194499)
+++ trunk/LayoutTests/ChangeLog        2016-01-02 19:42:22 UTC (rev 194500)
</span><span class="lines">@@ -1,3 +1,15 @@
</span><ins>+2016-01-02  Zalan Bujtas  &lt;zalan@apple.com&gt;
+
+        Simple line layout:: Add text-decoration support.
+        https://bugs.webkit.org/show_bug.cgi?id=152623
+
+        Reviewed by Antti Koivisto.
+
+        Existing tests cases also cover decoration correctness.
+
+        * fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration-expected.html: Added.
+        * fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration.html: Added.
+
</ins><span class="cx"> 2016-01-01  Brady Eidson  &lt;beidson@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Modern IDB: storage/indexeddb/database-deletepending-flag.html fails.
</span></span></pre></div>
<a id="trunkLayoutTestsfastcss3textcss3textdecorationsimplelinelayouttextdecorationexpectedhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration-expected.html (0 => 194500)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration-expected.html                                (rev 0)
+++ trunk/LayoutTests/fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration-expected.html        2016-01-02 19:42:22 UTC (rev 194500)
</span><span class="lines">@@ -0,0 +1,19 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This tests that we paint simple line layout text-decoration correctly.&lt;/title&gt;
+&lt;script&gt;
+    if (window.internals)
+        internals.settings.setSimpleLineLayoutEnabled(false);
+&lt;/script&gt;
+&lt;/head&gt;
+&lt;body&gt;
+&lt;div style=&quot;text-decoration: underline;&quot;&gt;&lt;br&gt;supported&lt;br&gt;&lt;br&gt;supported&lt;br&gt;&lt;/div&gt;
+&lt;div style=&quot;text-decoration: underline;&quot;&gt;&lt;br&gt;&lt;/div&gt;
+&lt;div style=&quot;text-decoration: underline;&quot;&gt;&lt;br&gt;&lt;br&gt;&lt;/div&gt;
+&lt;div style=&quot;text-decoration: underline; -webkit-text-underline-position: under;&quot;&gt;not supported&lt;/div&gt;
+&lt;div style=&quot;text-decoration: underline; -webkit-text-underline-position: auto;&quot;&gt;supported&lt;/div&gt;
+&lt;div style=&quot;text-decoration: underline; -webkit-text-underline-position: alphabetic;&quot;&gt;supported&lt;/div&gt;
+&lt;div style=&quot;text-decoration: line-through;&quot;&gt;supported&lt;/div&gt;
+&lt;div style=&quot;text-decoration: overline;&quot;&gt;supported&lt;/div&gt;
+&lt;/body&gt;
</ins></span></pre></div>
<a id="trunkLayoutTestsfastcss3textcss3textdecorationsimplelinelayouttextdecorationhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration.html (0 => 194500)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration.html                                (rev 0)
+++ trunk/LayoutTests/fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration.html        2016-01-02 19:42:22 UTC (rev 194500)
</span><span class="lines">@@ -0,0 +1,15 @@
</span><ins>+&lt;!DOCTYPE html&gt;
+&lt;html&gt;
+&lt;head&gt;
+&lt;title&gt;This tests that we paint simple line layout text-decoration correctly.&lt;/title&gt;
+&lt;/head&gt;
+&lt;body&gt;
+&lt;div style=&quot;text-decoration: underline;&quot;&gt;&lt;br&gt;supported&lt;br&gt;&lt;br&gt;supported&lt;br&gt;&lt;/div&gt;
+&lt;div style=&quot;text-decoration: underline;&quot;&gt;&lt;br&gt;&lt;/div&gt;
+&lt;div style=&quot;text-decoration: underline;&quot;&gt;&lt;br&gt;&lt;br&gt;&lt;/div&gt;
+&lt;div style=&quot;text-decoration: underline; -webkit-text-underline-position: under;&quot;&gt;not supported&lt;/div&gt;
+&lt;div style=&quot;text-decoration: underline; -webkit-text-underline-position: auto;&quot;&gt;supported&lt;/div&gt;
+&lt;div style=&quot;text-decoration: underline; -webkit-text-underline-position: alphabetic;&quot;&gt;supported&lt;/div&gt;
+&lt;div style=&quot;text-decoration: line-through;&quot;&gt;supported&lt;/div&gt;
+&lt;div style=&quot;text-decoration: overline;&quot;&gt;supported&lt;/div&gt;
+&lt;/body&gt;
</ins></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (194499 => 194500)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2016-01-02 12:19:55 UTC (rev 194499)
+++ trunk/Source/WebCore/ChangeLog        2016-01-02 19:42:22 UTC (rev 194500)
</span><span class="lines">@@ -1,3 +1,22 @@
</span><ins>+2016-01-02  Zalan Bujtas  &lt;zalan@apple.com&gt;
+
+        Simple line layout:: Add text-decoration support.
+        https://bugs.webkit.org/show_bug.cgi?id=152623
+
+        Reviewed by Antti Koivisto.
+
+        This patch enables text-decoration for simple line layout.
+        -webkit-text-underline-position: under requires normal line layout context, skip it for now.
+
+        Test: fast/css3-text/css3-text-decoration/simple-line-layout-text-decoration.html
+
+        * rendering/SimpleLineLayout.cpp:
+        (WebCore::SimpleLineLayout::canUseForStyle):
+        (WebCore::SimpleLineLayout::printReason):
+        * rendering/SimpleLineLayoutFunctions.cpp:
+        (WebCore::SimpleLineLayout::paintFlow): In case of multiple RenderText renderers (long text), it's ok
+        to pass the first text renderer as they all share the same set of decorations. 
+
</ins><span class="cx"> 2015-12-31  Andy Estes  &lt;aestes@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Replace WTF::move with WTFMove
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingSimpleLineLayoutcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/SimpleLineLayout.cpp (194499 => 194500)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/SimpleLineLayout.cpp        2016-01-02 12:19:55 UTC (rev 194499)
+++ trunk/Source/WebCore/rendering/SimpleLineLayout.cpp        2016-01-02 19:42:22 UTC (rev 194500)
</span><span class="lines">@@ -62,57 +62,57 @@
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><span class="cx"> enum AvoidanceReason_ : uint64_t {
</span><del>-    FlowIsInsideRegion                  = 1LLU  &lt;&lt; 0,
-    FlowHasHorizonalWritingMode         = 1LLU  &lt;&lt; 1,
-    FlowHasOutline                      = 1LLU  &lt;&lt; 2,
-    FlowIsRuby                          = 1LLU  &lt;&lt; 3,
-    FlowIsPaginated                     = 1LLU  &lt;&lt; 4,
-    FlowHasTextOverflow                 = 1LLU  &lt;&lt; 5,
-    FlowIsDepricatedFlexBox             = 1LLU  &lt;&lt; 6,
-    FlowParentIsPlaceholderElement      = 1LLU  &lt;&lt; 7,
-    FlowParentIsTextAreaWithWrapping    = 1LLU  &lt;&lt; 8,
-    FlowHasNonSupportedChild            = 1LLU  &lt;&lt; 9,
-    FlowHasUnsupportedFloat             = 1LLU  &lt;&lt; 10,
-    FlowHasTextDecoration               = 1LLU  &lt;&lt; 11,
-    FlowIsJustifyAligned                = 1LLU  &lt;&lt; 12,
-    FlowHasOverflowVisible              = 1LLU  &lt;&lt; 13,
-    FlowIsNotLTR                        = 1LLU  &lt;&lt; 14,
-    FlowHasLineBoxContainProperty       = 1LLU  &lt;&lt; 15,
-    FlowIsNotTopToBottom                = 1LLU  &lt;&lt; 16,
-    FlowHasLineBreak                    = 1LLU  &lt;&lt; 17,
-    FlowHasWordBreak                    = 1LLU  &lt;&lt; 18,
-    FlowHasNonNormalUnicodeBiDi         = 1LLU  &lt;&lt; 19,
-    FlowHasRTLOrdering                  = 1LLU  &lt;&lt; 20,
-    FlowHasLineAlignEdges               = 1LLU  &lt;&lt; 21,
-    FlowHasLineSnap                     = 1LLU  &lt;&lt; 22,
-    FlowHasHypensAuto                   = 1LLU  &lt;&lt; 23,
-    FlowHasTextEmphasisFillOrMark       = 1LLU  &lt;&lt; 24,
-    FlowHasTextShadow                   = 1LLU  &lt;&lt; 25,
-    FlowHasPseudoFirstLine              = 1LLU  &lt;&lt; 26,
-    FlowHasPseudoFirstLetter            = 1LLU  &lt;&lt; 27,
-    FlowHasTextCombine                  = 1LLU  &lt;&lt; 28,
-    FlowHasTextFillBox                  = 1LLU  &lt;&lt; 29,
-    FlowHasBorderFitLines               = 1LLU  &lt;&lt; 30,
-    FlowHasNonAutoLineBreak             = 1LLU  &lt;&lt; 31,
-    FlowHasNonAutoTrailingWord          = 1LLU  &lt;&lt; 32,
-    FlowHasSVGFont                      = 1LLU  &lt;&lt; 33,
-    FlowTextIsEmpty                     = 1LLU  &lt;&lt; 34,
-    FlowTextHasNoBreakSpace             = 1LLU  &lt;&lt; 35,
-    FlowTextHasSoftHyphen               = 1LLU  &lt;&lt; 36,
-    FlowTextHasDirectionCharacter       = 1LLU  &lt;&lt; 37,
-    FlowIsMissingPrimaryFont            = 1LLU  &lt;&lt; 38,
-    FlowFontIsMissingGlyph              = 1LLU  &lt;&lt; 39,
-    FlowTextIsCombineText               = 1LLU  &lt;&lt; 40,
-    FlowTextIsRenderCounter             = 1LLU  &lt;&lt; 41,
-    FlowTextIsRenderQuote               = 1LLU  &lt;&lt; 42,
-    FlowTextIsTextFragment              = 1LLU  &lt;&lt; 43,
-    FlowTextIsSVGInlineText             = 1LLU  &lt;&lt; 44,
-    FlowFontIsNotSimple                 = 1LLU  &lt;&lt; 45,
-    FeatureIsDisabled                   = 1LLU  &lt;&lt; 46,
-    FlowHasNoParent                     = 1LLU  &lt;&lt; 47,
-    FlowHasNoChild                      = 1LLU  &lt;&lt; 48,
-    FlowChildIsSelected                 = 1LLU  &lt;&lt; 49,
-    EndOfReasons                        = 1LLU  &lt;&lt; 50
</del><ins>+    FlowIsInsideRegion                    = 1LLU  &lt;&lt; 0,
+    FlowHasHorizonalWritingMode           = 1LLU  &lt;&lt; 1,
+    FlowHasOutline                        = 1LLU  &lt;&lt; 2,
+    FlowIsRuby                            = 1LLU  &lt;&lt; 3,
+    FlowIsPaginated                       = 1LLU  &lt;&lt; 4,
+    FlowHasTextOverflow                   = 1LLU  &lt;&lt; 5,
+    FlowIsDepricatedFlexBox               = 1LLU  &lt;&lt; 6,
+    FlowParentIsPlaceholderElement        = 1LLU  &lt;&lt; 7,
+    FlowParentIsTextAreaWithWrapping      = 1LLU  &lt;&lt; 8,
+    FlowHasNonSupportedChild              = 1LLU  &lt;&lt; 9,
+    FlowHasUnsupportedFloat               = 1LLU  &lt;&lt; 10,
+    FlowHasUnsupportedUnderlineDecoration = 1LLU  &lt;&lt; 11,
+    FlowIsJustifyAligned                  = 1LLU  &lt;&lt; 12,
+    FlowHasOverflowVisible                = 1LLU  &lt;&lt; 13,
+    FlowIsNotLTR                          = 1LLU  &lt;&lt; 14,
+    FlowHasLineBoxContainProperty         = 1LLU  &lt;&lt; 15,
+    FlowIsNotTopToBottom                  = 1LLU  &lt;&lt; 16,
+    FlowHasLineBreak                      = 1LLU  &lt;&lt; 17,
+    FlowHasWordBreak                      = 1LLU  &lt;&lt; 18,
+    FlowHasNonNormalUnicodeBiDi           = 1LLU  &lt;&lt; 19,
+    FlowHasRTLOrdering                    = 1LLU  &lt;&lt; 20,
+    FlowHasLineAlignEdges                 = 1LLU  &lt;&lt; 21,
+    FlowHasLineSnap                       = 1LLU  &lt;&lt; 22,
+    FlowHasHypensAuto                     = 1LLU  &lt;&lt; 23,
+    FlowHasTextEmphasisFillOrMark         = 1LLU  &lt;&lt; 24,
+    FlowHasTextShadow                     = 1LLU  &lt;&lt; 25,
+    FlowHasPseudoFirstLine                = 1LLU  &lt;&lt; 26,
+    FlowHasPseudoFirstLetter              = 1LLU  &lt;&lt; 27,
+    FlowHasTextCombine                    = 1LLU  &lt;&lt; 28,
+    FlowHasTextFillBox                    = 1LLU  &lt;&lt; 29,
+    FlowHasBorderFitLines                 = 1LLU  &lt;&lt; 30,
+    FlowHasNonAutoLineBreak               = 1LLU  &lt;&lt; 31,
+    FlowHasNonAutoTrailingWord            = 1LLU  &lt;&lt; 32,
+    FlowHasSVGFont                        = 1LLU  &lt;&lt; 33,
+    FlowTextIsEmpty                       = 1LLU  &lt;&lt; 34,
+    FlowTextHasNoBreakSpace               = 1LLU  &lt;&lt; 35,
+    FlowTextHasSoftHyphen                 = 1LLU  &lt;&lt; 36,
+    FlowTextHasDirectionCharacter         = 1LLU  &lt;&lt; 37,
+    FlowIsMissingPrimaryFont              = 1LLU  &lt;&lt; 38,
+    FlowFontIsMissingGlyph                = 1LLU  &lt;&lt; 39,
+    FlowTextIsCombineText                 = 1LLU  &lt;&lt; 40,
+    FlowTextIsRenderCounter               = 1LLU  &lt;&lt; 41,
+    FlowTextIsRenderQuote                 = 1LLU  &lt;&lt; 42,
+    FlowTextIsTextFragment                = 1LLU  &lt;&lt; 43,
+    FlowTextIsSVGInlineText               = 1LLU  &lt;&lt; 44,
+    FlowFontIsNotSimple                   = 1LLU  &lt;&lt; 45,
+    FeatureIsDisabled                     = 1LLU  &lt;&lt; 46,
+    FlowHasNoParent                       = 1LLU  &lt;&lt; 47,
+    FlowHasNoChild                        = 1LLU  &lt;&lt; 48,
+    FlowChildIsSelected                   = 1LLU  &lt;&lt; 49,
+    EndOfReasons                          = 1LLU  &lt;&lt; 50
</ins><span class="cx"> };
</span><span class="cx"> const unsigned NoReason = 0;
</span><span class="cx"> 
</span><span class="lines">@@ -211,8 +211,8 @@
</span><span class="cx">     AvoidanceReasonFlags reasons = { };
</span><span class="cx">     if (style.textOverflow())
</span><span class="cx">         SET_REASON_AND_RETURN_IF_NEEDED(FlowHasTextOverflow, reasons, includeReasons);
</span><del>-    if (style.textDecorationsInEffect() != TextDecorationNone)
-        SET_REASON_AND_RETURN_IF_NEEDED(FlowHasTextDecoration, reasons, includeReasons);
</del><ins>+    if ((style.textDecorationsInEffect() &amp; TextDecorationUnderline) &amp;&amp; style.textUnderlinePosition() == TextUnderlinePositionUnder)
+        SET_REASON_AND_RETURN_IF_NEEDED(FlowHasUnsupportedUnderlineDecoration, reasons, includeReasons);
</ins><span class="cx">     if (style.textAlign() == JUSTIFY)
</span><span class="cx">         SET_REASON_AND_RETURN_IF_NEEDED(FlowIsJustifyAligned, reasons, includeReasons);
</span><span class="cx">     // Non-visible overflow should be pretty easy to support.
</span><span class="lines">@@ -820,8 +820,8 @@
</span><span class="cx">     case FlowHasUnsupportedFloat:
</span><span class="cx">         stream &lt;&lt; &quot;complicated float&quot;;
</span><span class="cx">         break;
</span><del>-    case FlowHasTextDecoration:
-        stream &lt;&lt; &quot;text-decoration&quot;;
</del><ins>+    case FlowHasUnsupportedUnderlineDecoration:
+        stream &lt;&lt; &quot;text-underline-position: under&quot;;
</ins><span class="cx">         break;
</span><span class="cx">     case FlowIsJustifyAligned:
</span><span class="cx">         stream &lt;&lt; &quot;text-align: justify&quot;;
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingSimpleLineLayoutFunctionscpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/SimpleLineLayoutFunctions.cpp (194499 => 194500)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/SimpleLineLayoutFunctions.cpp        2016-01-02 12:19:55 UTC (rev 194499)
+++ trunk/Source/WebCore/rendering/SimpleLineLayoutFunctions.cpp        2016-01-02 19:42:22 UTC (rev 194500)
</span><span class="lines">@@ -35,12 +35,14 @@
</span><span class="cx"> #include &quot;InlineTextBox.h&quot;
</span><span class="cx"> #include &quot;PaintInfo.h&quot;
</span><span class="cx"> #include &quot;RenderBlockFlow.h&quot;
</span><ins>+#include &quot;RenderIterator.h&quot;
</ins><span class="cx"> #include &quot;RenderStyle.h&quot;
</span><span class="cx"> #include &quot;RenderText.h&quot;
</span><span class="cx"> #include &quot;RenderView.h&quot;
</span><span class="cx"> #include &quot;Settings.h&quot;
</span><span class="cx"> #include &quot;SimpleLineLayoutResolver.h&quot;
</span><span class="cx"> #include &quot;Text.h&quot;
</span><ins>+#include &quot;TextDecorationPainter.h&quot;
</ins><span class="cx"> #include &quot;TextPaintStyle.h&quot;
</span><span class="cx"> #include &quot;TextPainter.h&quot;
</span><span class="cx"> 
</span><span class="lines">@@ -78,6 +80,16 @@
</span><span class="cx">     textPainter.setFont(style.fontCascade());
</span><span class="cx">     textPainter.setTextPaintStyle(computeTextPaintStyle(flow.frame(), style, paintInfo));
</span><span class="cx"> 
</span><ins>+    Optional&lt;TextDecorationPainter&gt; textDecorationPainter;
+    if (style.textDecorationsInEffect() != TextDecorationNone) {
+        const RenderText* textRenderer = childrenOfType&lt;RenderText&gt;(flow).first();
+        if (textRenderer) {
+            textDecorationPainter = TextDecorationPainter(paintInfo.context(), style.textDecorationsInEffect(), *textRenderer, false);
+            textDecorationPainter-&gt;setFont(style.fontCascade());
+            textDecorationPainter-&gt;setBaseline(style.fontMetrics().ascent());
+        }
+    }
+
</ins><span class="cx">     LayoutRect paintRect = paintInfo.rect;
</span><span class="cx">     paintRect.moveBy(-paintOffset);
</span><span class="cx"> 
</span><span class="lines">@@ -100,6 +112,10 @@
</span><span class="cx">         textRun.setXPos(0);
</span><span class="cx">         FloatPoint textOrigin = FloatPoint(rect.x() + paintOffset.x(), roundToDevicePixel(run.baselinePosition() + paintOffset.y(), deviceScaleFactor));
</span><span class="cx">         textPainter.paintText(textRun, textRun.length(), rect, textOrigin);
</span><ins>+        if (textDecorationPainter) {
+            textDecorationPainter-&gt;setWidth(rect.width());
+            textDecorationPainter-&gt;paintTextDecoration(textRun, textOrigin, rect.location() + paintOffset);
+        }
</ins><span class="cx">         if (debugBordersEnabled)
</span><span class="cx">             paintDebugBorders(paintInfo.context(), LayoutRect(run.rect()), paintOffset);
</span><span class="cx">     }
</span></span></pre>
</div>
</div>

</body>
</html>