<!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>[213141] releases/WebKitGTK/webkit-2.16/Source/WebCore</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/213141">213141</a></dd>
<dt>Author</dt> <dd>carlosgc@webkit.org</dd>
<dt>Date</dt> <dd>2017-02-28 01:46:51 -0800 (Tue, 28 Feb 2017)</dd>
</dl>

<h3>Log Message</h3>
<pre>Merge <a href="http://trac.webkit.org/projects/webkit/changeset/212986">r212986</a> - Simple line layout: Re-adjust paginated lines when block height changes.
https://bugs.webkit.org/show_bug.cgi?id=168838
&lt;rdar://problem/30701233&gt;

Reviewed by Antti Koivisto.

When the estimated block height is wrong, we issue an additional layout on the inline children
so that we get the pagination right (this layout is setChildNeedsLayout(MarkOnlyThis) only).
Since the height change only affects the struts and page breaks (and again, the relayoutChildren flag is false)
we don't need to re-layout the content, but instead we just need to re-adjust the pagination for the simple lines.
This patch also moves the pagination logic to SimpleLineLayoutPagination.cpp.

Not enabled yet.

* CMakeLists.txt:
* WebCore.xcodeproj/project.pbxproj:
* rendering/RenderBlockFlow.cpp:
(WebCore::RenderBlockFlow::layoutSimpleLines):
* rendering/RenderingAllInOne.cpp:
* rendering/SimpleLineLayout.cpp:
(WebCore::SimpleLineLayout::canUseForWithReason):
(WebCore::SimpleLineLayout::create):
(WebCore::SimpleLineLayout::Layout::create):
(WebCore::SimpleLineLayout::Layout::Layout):
(WebCore::SimpleLineLayout::computeLineTopAndBottomWithOverflow): Deleted.
(WebCore::SimpleLineLayout::computeLineBreakIndex): Deleted.
(WebCore::SimpleLineLayout::computeOffsetAfterLineBreak): Deleted.
(WebCore::SimpleLineLayout::setPageBreakForLine): Deleted.
(WebCore::SimpleLineLayout::updateMinimumPageHeight): Deleted.
(WebCore::SimpleLineLayout::adjustLinePositionsForPagination): Deleted.
* rendering/SimpleLineLayout.h:
(WebCore::SimpleLineLayout::Layout::setIsPaginated):
(WebCore::SimpleLineLayout::Layout::setLineStruts):
* rendering/SimpleLineLayoutPagination.cpp: Added.
(WebCore::SimpleLineLayout::computeLineTopAndBottomWithOverflow):
(WebCore::SimpleLineLayout::computeLineBreakIndex):
(WebCore::SimpleLineLayout::computeOffsetAfterLineBreak):
(WebCore::SimpleLineLayout::setPageBreakForLine):
(WebCore::SimpleLineLayout::updateMinimumPageHeight):
(WebCore::SimpleLineLayout::adjustLinePositionsForPagination):
* rendering/SimpleLineLayoutPagination.h: Added.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#releasesWebKitGTKwebkit216SourceWebCoreCMakeListstxt">releases/WebKitGTK/webkit-2.16/Source/WebCore/CMakeLists.txt</a></li>
<li><a href="#releasesWebKitGTKwebkit216SourceWebCoreChangeLog">releases/WebKitGTK/webkit-2.16/Source/WebCore/ChangeLog</a></li>
<li><a href="#releasesWebKitGTKwebkit216SourceWebCoreWebCorexcodeprojprojectpbxproj">releases/WebKitGTK/webkit-2.16/Source/WebCore/WebCore.xcodeproj/project.pbxproj</a></li>
<li><a href="#releasesWebKitGTKwebkit216SourceWebCorerenderingRenderBlockFlowcpp">releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/RenderBlockFlow.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit216SourceWebCorerenderingRenderingAllInOnecpp">releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/RenderingAllInOne.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit216SourceWebCorerenderingSimpleLineLayoutcpp">releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayout.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit216SourceWebCorerenderingSimpleLineLayouth">releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayout.h</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#releasesWebKitGTKwebkit216SourceWebCorerenderingSimpleLineLayoutPaginationcpp">releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayoutPagination.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit216SourceWebCorerenderingSimpleLineLayoutPaginationh">releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayoutPagination.h</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="releasesWebKitGTKwebkit216SourceWebCoreCMakeListstxt"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.16/Source/WebCore/CMakeLists.txt (213140 => 213141)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.16/Source/WebCore/CMakeLists.txt        2017-02-28 09:42:18 UTC (rev 213140)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/CMakeLists.txt        2017-02-28 09:46:51 UTC (rev 213141)
</span><span class="lines">@@ -2479,6 +2479,7 @@
</span><span class="cx">     rendering/SimpleLineLayout.cpp
</span><span class="cx">     rendering/SimpleLineLayoutFlowContents.cpp
</span><span class="cx">     rendering/SimpleLineLayoutFunctions.cpp
</span><ins>+    rendering/SimpleLineLayoutPagination.cpp
</ins><span class="cx">     rendering/SimpleLineLayoutResolver.cpp
</span><span class="cx">     rendering/SimpleLineLayoutTextFragmentIterator.cpp
</span><span class="cx">     rendering/TextDecorationPainter.cpp
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit216SourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.16/Source/WebCore/ChangeLog (213140 => 213141)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.16/Source/WebCore/ChangeLog        2017-02-28 09:42:18 UTC (rev 213140)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/ChangeLog        2017-02-28 09:46:51 UTC (rev 213141)
</span><span class="lines">@@ -1,3 +1,47 @@
</span><ins>+2017-02-24  Zalan Bujtas  &lt;zalan@apple.com&gt;
+
+        Simple line layout: Re-adjust paginated lines when block height changes.
+        https://bugs.webkit.org/show_bug.cgi?id=168838
+        &lt;rdar://problem/30701233&gt;
+
+        Reviewed by Antti Koivisto.
+
+        When the estimated block height is wrong, we issue an additional layout on the inline children
+        so that we get the pagination right (this layout is setChildNeedsLayout(MarkOnlyThis) only).
+        Since the height change only affects the struts and page breaks (and again, the relayoutChildren flag is false)
+        we don't need to re-layout the content, but instead we just need to re-adjust the pagination for the simple lines. 
+        This patch also moves the pagination logic to SimpleLineLayoutPagination.cpp.
+
+        Not enabled yet.
+
+        * CMakeLists.txt:
+        * WebCore.xcodeproj/project.pbxproj:
+        * rendering/RenderBlockFlow.cpp:
+        (WebCore::RenderBlockFlow::layoutSimpleLines):
+        * rendering/RenderingAllInOne.cpp:
+        * rendering/SimpleLineLayout.cpp:
+        (WebCore::SimpleLineLayout::canUseForWithReason):
+        (WebCore::SimpleLineLayout::create):
+        (WebCore::SimpleLineLayout::Layout::create):
+        (WebCore::SimpleLineLayout::Layout::Layout):
+        (WebCore::SimpleLineLayout::computeLineTopAndBottomWithOverflow): Deleted.
+        (WebCore::SimpleLineLayout::computeLineBreakIndex): Deleted.
+        (WebCore::SimpleLineLayout::computeOffsetAfterLineBreak): Deleted.
+        (WebCore::SimpleLineLayout::setPageBreakForLine): Deleted.
+        (WebCore::SimpleLineLayout::updateMinimumPageHeight): Deleted.
+        (WebCore::SimpleLineLayout::adjustLinePositionsForPagination): Deleted.
+        * rendering/SimpleLineLayout.h:
+        (WebCore::SimpleLineLayout::Layout::setIsPaginated):
+        (WebCore::SimpleLineLayout::Layout::setLineStruts):
+        * rendering/SimpleLineLayoutPagination.cpp: Added.
+        (WebCore::SimpleLineLayout::computeLineTopAndBottomWithOverflow):
+        (WebCore::SimpleLineLayout::computeLineBreakIndex):
+        (WebCore::SimpleLineLayout::computeOffsetAfterLineBreak):
+        (WebCore::SimpleLineLayout::setPageBreakForLine):
+        (WebCore::SimpleLineLayout::updateMinimumPageHeight):
+        (WebCore::SimpleLineLayout::adjustLinePositionsForPagination):
+        * rendering/SimpleLineLayoutPagination.h: Added.
+
</ins><span class="cx"> 2017-02-24  Alex Christensen  &lt;achristensen@webkit.org&gt;
</span><span class="cx"> 
</span><span class="cx">         Non-special relative URLs should not ignore extra slashes
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit216SourceWebCoreWebCorexcodeprojprojectpbxproj"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.16/Source/WebCore/WebCore.xcodeproj/project.pbxproj (213140 => 213141)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.16/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2017-02-28 09:42:18 UTC (rev 213140)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2017-02-28 09:46:51 UTC (rev 213141)
</span><span class="lines">@@ -567,6 +567,8 @@
</span><span class="cx">                 0FFD4D6018651FA300512F6E /* AsyncScrollingCoordinator.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 0FFD4D5E18651FA300512F6E /* AsyncScrollingCoordinator.cpp */; };
</span><span class="cx">                 0FFD4D6118651FA300512F6E /* AsyncScrollingCoordinator.h in Headers */ = {isa = PBXBuildFile; fileRef = 0FFD4D5F18651FA300512F6E /* AsyncScrollingCoordinator.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 10FB084B14E15C7E00A3DB98 /* PublicURLManager.h in Headers */ = {isa = PBXBuildFile; fileRef = 10FB084A14E15C7E00A3DB98 /* PublicURLManager.h */; };
</span><ins>+                112B34D21E60B8A700BB310A /* SimpleLineLayoutPagination.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 112B34D01E60B8A700BB310A /* SimpleLineLayoutPagination.cpp */; };
+                112B34D51E60B98300BB310A /* SimpleLineLayoutPagination.h in Headers */ = {isa = PBXBuildFile; fileRef = 112B34D41E60B98300BB310A /* SimpleLineLayoutPagination.h */; };
</ins><span class="cx">                 120DE3ED1C86CA3E00B6D4DD /* WebAnimation.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 120DE3EA1C80161C00B6D4DD /* WebAnimation.cpp */; };
</span><span class="cx">                 120DE3F11C86CCC600B6D4DD /* AnimationEffect.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 120DE3EE1C86CCBD00B6D4DD /* AnimationEffect.cpp */; };
</span><span class="cx">                 120DE3F81C87C5A800B6D4DD /* JSWebAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = 120DE3F51C87C58E00B6D4DD /* JSWebAnimation.h */; };
</span><span class="lines">@@ -7676,6 +7678,8 @@
</span><span class="cx">                 0FFD4D5E18651FA300512F6E /* AsyncScrollingCoordinator.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = AsyncScrollingCoordinator.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 0FFD4D5F18651FA300512F6E /* AsyncScrollingCoordinator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AsyncScrollingCoordinator.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 10FB084A14E15C7E00A3DB98 /* PublicURLManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PublicURLManager.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><ins>+                112B34D01E60B8A700BB310A /* SimpleLineLayoutPagination.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SimpleLineLayoutPagination.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
+                112B34D41E60B98300BB310A /* SimpleLineLayoutPagination.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SimpleLineLayoutPagination.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</ins><span class="cx">                 120DE3EA1C80161C00B6D4DD /* WebAnimation.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebAnimation.cpp; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 120DE3EB1C80161C00B6D4DD /* WebAnimation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebAnimation.h; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="cx">                 120DE3EC1C80161C00B6D4DD /* WebAnimation.idl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = WebAnimation.idl; sourceTree = &quot;&lt;group&gt;&quot;; };
</span><span class="lines">@@ -24309,6 +24313,8 @@
</span><span class="cx">                                 585D6E021A1A792E00FA4F12 /* SimpleLineLayoutFlowContents.h */,
</span><span class="cx">                                 E4E9B11A18145692003ACCDF /* SimpleLineLayoutFunctions.cpp */,
</span><span class="cx">                                 E4E9B11C1814569C003ACCDF /* SimpleLineLayoutFunctions.h */,
</span><ins>+                                112B34D41E60B98300BB310A /* SimpleLineLayoutPagination.h */,
+                                112B34D01E60B8A700BB310A /* SimpleLineLayoutPagination.cpp */,
</ins><span class="cx">                                 585D6DFB1A15355600FA4F12 /* SimpleLineLayoutResolver.cpp */,
</span><span class="cx">                                 E4E9B1181810916F003ACCDF /* SimpleLineLayoutResolver.h */,
</span><span class="cx">                                 582CB0541A78A2B200AFFCC4 /* SimpleLineLayoutTextFragmentIterator.cpp */,
</span><span class="lines">@@ -27988,6 +27994,7 @@
</span><span class="cx">                                 931CBD11161A44E900E4C874 /* ScrollingStateTree.h in Headers */,
</span><span class="cx">                                 1AF62F2614DAFEA10041556C /* ScrollingThread.h in Headers */,
</span><span class="cx">                                 1AAADDA414DB409F00AF64B3 /* ScrollingTree.h in Headers */,
</span><ins>+                                112B34D51E60B98300BB310A /* SimpleLineLayoutPagination.h in Headers */,
</ins><span class="cx">                                 93C38C03164473DD00091EB2 /* ScrollingTreeFixedNode.h in Headers */,
</span><span class="cx">                                 0FEA3E88191B3BD7000F1B55 /* ScrollingTreeFrameScrollingNode.h in Headers */,
</span><span class="cx">                                 0FC4E411187F82E10045882C /* ScrollingTreeFrameScrollingNodeIOS.h in Headers */,
</span><span class="lines">@@ -29526,6 +29533,7 @@
</span><span class="cx">                                 975CA28A130365F800E99AD9 /* Crypto.cpp in Sources */,
</span><span class="cx">                                 E172AF6D180F24C600FBADB9 /* CryptoAlgorithm.cpp in Sources */,
</span><span class="cx">                                 E125F8411824253A00D84CD9 /* CryptoAlgorithmAES_CBC.cpp in Sources */,
</span><ins>+                                112B34D21E60B8A700BB310A /* SimpleLineLayoutPagination.cpp in Sources */,
</ins><span class="cx">                                 E125F845182425C900D84CD9 /* CryptoAlgorithmAES_CBCMac.cpp in Sources */,
</span><span class="cx">                                 E1FE137A184D21BB00892F13 /* CryptoAlgorithmAES_KW.cpp in Sources */,
</span><span class="cx">                                 E1FE137E184D270200892F13 /* CryptoAlgorithmAES_KWMac.cpp in Sources */,
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit216SourceWebCorerenderingRenderBlockFlowcpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/RenderBlockFlow.cpp (213140 => 213141)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/RenderBlockFlow.cpp        2017-02-28 09:42:18 UTC (rev 213140)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/RenderBlockFlow.cpp        2017-02-28 09:46:51 UTC (rev 213141)
</span><span class="lines">@@ -51,6 +51,7 @@
</span><span class="cx"> #include &quot;RenderView.h&quot;
</span><span class="cx"> #include &quot;Settings.h&quot;
</span><span class="cx"> #include &quot;SimpleLineLayoutFunctions.h&quot;
</span><ins>+#include &quot;SimpleLineLayoutPagination.h&quot;
</ins><span class="cx"> #include &quot;VerticalPositionCache.h&quot;
</span><span class="cx"> #include &quot;VisiblePosition.h&quot;
</span><span class="cx"> 
</span><span class="lines">@@ -3671,6 +3672,10 @@
</span><span class="cx">         deleteLineBoxesBeforeSimpleLineLayout();
</span><span class="cx">         m_simpleLineLayout = SimpleLineLayout::create(*this);
</span><span class="cx">     }
</span><ins>+    if (view().layoutState() &amp;&amp; view().layoutState()-&gt;isPaginated()) {
+        m_simpleLineLayout-&gt;setIsPaginated();
+        SimpleLineLayout::adjustLinePositionsForPagination(*m_simpleLineLayout, *this);
+    }
</ins><span class="cx">     for (auto&amp; renderer : childrenOfType&lt;RenderObject&gt;(*this))
</span><span class="cx">         renderer.clearNeedsLayout();
</span><span class="cx">     ASSERT(!m_lineBoxes.firstLineBox());
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit216SourceWebCorerenderingRenderingAllInOnecpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/RenderingAllInOne.cpp (213140 => 213141)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/RenderingAllInOne.cpp        2017-02-28 09:42:18 UTC (rev 213140)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/RenderingAllInOne.cpp        2017-02-28 09:46:51 UTC (rev 213141)
</span><span class="lines">@@ -144,6 +144,7 @@
</span><span class="cx"> #include &quot;SimpleLineLayout.cpp&quot;
</span><span class="cx"> #include &quot;SimpleLineLayoutFlowContents.cpp&quot;
</span><span class="cx"> #include &quot;SimpleLineLayoutFunctions.cpp&quot;
</span><ins>+#include &quot;SimpleLineLayoutPagination.cpp&quot;
</ins><span class="cx"> #include &quot;SimpleLineLayoutResolver.cpp&quot;
</span><span class="cx"> #include &quot;SimpleLineLayoutTextFragmentIterator.cpp&quot;
</span><span class="cx"> #include &quot;TextDecorationPainter.cpp&quot;
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit216SourceWebCorerenderingSimpleLineLayoutcpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayout.cpp (213140 => 213141)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayout.cpp        2017-02-28 09:42:18 UTC (rev 213140)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayout.cpp        2017-02-28 09:46:51 UTC (rev 213141)
</span><span class="lines">@@ -907,121 +907,6 @@
</span><span class="cx">     ++lineCount;
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-struct PaginatedLine {
-    LayoutUnit top;
-    LayoutUnit bottom;
-    LayoutUnit height; // Same value for each lines atm.
-};
-using PaginatedLines = Vector&lt;PaginatedLine, 20&gt;;
-
-static PaginatedLine computeLineTopAndBottomWithOverflow(const RenderBlockFlow&amp; flow, unsigned lineIndex, Layout::SimpleLineStruts&amp; struts)
-{
-    // FIXME: Add visualOverflowForDecorations.
-    auto&amp; fontMetrics = flow.style().fontCascade().fontMetrics();
-    auto ascent = fontMetrics.floatAscent();
-    auto descent = fontMetrics.floatDescent();
-    auto lineHeight = lineHeightFromFlow(flow);
-    LayoutUnit offset = flow.borderAndPaddingBefore();
-    for (auto&amp; strut : struts) {
-        if (strut.lineBreak &gt; lineIndex)
-            break;
-        offset += strut.offset;
-    }
-    if (ascent + descent &lt;= lineHeight) {
-        auto topPosition = lineIndex * lineHeight + offset;
-        return { topPosition, topPosition + lineHeight, lineHeight };
-    }
-    auto baseline = baselineFromFlow(flow);
-    auto topPosition = lineIndex * lineHeight + offset + baseline - ascent;
-    auto bottomPosition = topPosition + ascent + descent;
-    return { topPosition, bottomPosition, bottomPosition - topPosition };
-}
-
-static unsigned computeLineBreakIndex(unsigned breakCandidate, unsigned lineCount, unsigned widows, const Layout::SimpleLineStruts&amp; struts)
-{
-    // First line does not fit the current page.
-    if (!breakCandidate)
-        return breakCandidate;
-    
-    auto remainingLineCount = lineCount - breakCandidate;
-    if (widows &lt;= remainingLineCount)
-        return breakCandidate;
-    
-    // Only break after the first line with widows.
-    auto lineBreak = std::max&lt;int&gt;(lineCount - widows, 1);
-    // Break on current page only.
-    if (struts.isEmpty())
-        return lineBreak;
-    ASSERT(struts.last().lineBreak + 1 &lt; lineCount);
-    return std::max&lt;unsigned&gt;(struts.last().lineBreak + 1, lineBreak);
-}
-
-static LayoutUnit computeOffsetAfterLineBreak(LayoutUnit lineBreakPosition, bool isFirstLine, bool atTheTopOfColumnOrPage, const RenderBlockFlow&amp; flow)
-{
-    // No offset for top of the page lines unless widows pushed the line break.
-    LayoutUnit offset = isFirstLine ? flow.borderAndPaddingBefore() : LayoutUnit();
-    if (atTheTopOfColumnOrPage)
-        return offset;
-    return offset + flow.pageRemainingLogicalHeightForOffset(lineBreakPosition, RenderBlockFlow::ExcludePageBoundary);
-}
-
-static void setPageBreakForLine(unsigned lineBreakIndex, PaginatedLines&amp; lines, RenderBlockFlow&amp; flow, Layout::SimpleLineStruts&amp; struts,
-    bool atTheTopOfColumnOrPage)
-{
-    if (!lineBreakIndex) {
-        // When the first line does not fit the current page, just add a page break in front and set the strut on the block.
-        auto line = lines.first();
-        auto remainingLogicalHeight = flow.pageRemainingLogicalHeightForOffset(line.top, RenderBlockFlow::ExcludePageBoundary);
-        flow.setPageBreak(line.top, line.height - remainingLogicalHeight);
-        flow.setPaginationStrut(remainingLogicalHeight);
-        return;
-    }
-    auto beforeLineBreak = lines.at(lineBreakIndex - 1);
-    auto spaceShortage = flow.pageRemainingLogicalHeightForOffset(beforeLineBreak.top, RenderBlockFlow::ExcludePageBoundary) - beforeLineBreak.height;
-    flow.setPageBreak(beforeLineBreak.bottom, spaceShortage);
-    struts.append({ lineBreakIndex, computeOffsetAfterLineBreak(lines[lineBreakIndex].top, !lineBreakIndex, atTheTopOfColumnOrPage, flow) });
-}
-
-static void updateMinimumPageHeight(RenderBlockFlow&amp; flow, unsigned lineCount)
-{
-    auto&amp; style = flow.style();
-    auto widows = style.hasAutoWidows() ? 1 : std::max&lt;int&gt;(style.widows(), 1);
-    auto orphans = style.hasAutoOrphans() ? 1 : std::max&lt;int&gt;(style.orphans(), 1);
-    auto minimumLineCount = std::min&lt;unsigned&gt;(std::max(widows, orphans), lineCount);
-    flow.updateMinimumPageHeight(0, minimumLineCount * lineHeightFromFlow(flow));
-}
-
-static void adjustLinePositionsForPagination(Layout::RunVector&amp; runs, Layout::SimpleLineStruts&amp; struts,
-    RenderBlockFlow&amp; flow, unsigned lineCount)
-{
-    updateMinimumPageHeight(flow, lineCount);
-    // First pass with no pagination offset?
-    if (!flow.pageLogicalHeightForOffset(0))
-        return;
-    unsigned lineIndex = 0;
-    auto widows = flow.style().hasAutoWidows() ? 1 : std::max&lt;int&gt;(flow.style().widows(), 1);
-    PaginatedLines lines;
-    for (auto&amp; run : runs) {
-        if (!run.isEndOfLine)
-            continue;
-
-        auto line = computeLineTopAndBottomWithOverflow(flow, lineIndex, struts);
-        lines.append(line);
-        auto remainingHeight = flow.pageRemainingLogicalHeightForOffset(line.top, RenderBlockFlow::ExcludePageBoundary);
-        auto atTheTopOfColumnOrPage = flow.pageLogicalHeightForOffset(line.top) == remainingHeight;
-        if (line.height &gt; remainingHeight || (atTheTopOfColumnOrPage &amp;&amp; lineIndex)) {
-            auto lineBreakIndex = computeLineBreakIndex(lineIndex, lineCount, widows, struts);
-            // Are we still at the top of the column/page?
-            atTheTopOfColumnOrPage = atTheTopOfColumnOrPage ? lineIndex == lineBreakIndex : false;
-            setPageBreakForLine(lineBreakIndex, lines, flow, struts, atTheTopOfColumnOrPage);
-            // Recompute line positions that we already visited but window break pushed them to a new page.
-            for (auto i = lineBreakIndex; i &lt; lines.size(); ++i)
-                lines.at(i) = computeLineTopAndBottomWithOverflow(flow, i, struts);
-        }
-        ++lineIndex;
-    }
-}
-
</del><span class="cx"> static void createTextRuns(Layout::RunVector&amp; runs, RenderBlockFlow&amp; flow, unsigned&amp; lineCount)
</span><span class="cx"> {
</span><span class="cx">     LayoutUnit borderAndPaddingBefore = flow.borderAndPaddingBefore();
</span><span class="lines">@@ -1047,24 +932,18 @@
</span><span class="cx">     unsigned lineCount = 0;
</span><span class="cx">     Layout::RunVector runs;
</span><span class="cx">     createTextRuns(runs, flow, lineCount);
</span><del>-    Layout::SimpleLineStruts struts;
-    auto isPaginated = flow.view().layoutState() &amp;&amp; flow.view().layoutState()-&gt;isPaginated();
-    if (isPaginated)
-        adjustLinePositionsForPagination(runs, struts, flow, lineCount);
-    return Layout::create(runs, struts, lineCount, isPaginated);
</del><ins>+    return Layout::create(runs, lineCount);
</ins><span class="cx"> }
</span><span class="cx"> 
</span><del>-std::unique_ptr&lt;Layout&gt; Layout::create(const RunVector&amp; runVector, SimpleLineStruts&amp; struts, unsigned lineCount, bool isPaginated)
</del><ins>+std::unique_ptr&lt;Layout&gt; Layout::create(const RunVector&amp; runVector, unsigned lineCount)
</ins><span class="cx"> {
</span><span class="cx">     void* slot = WTF::fastMalloc(sizeof(Layout) + sizeof(Run) * runVector.size());
</span><del>-    return std::unique_ptr&lt;Layout&gt;(new (NotNull, slot) Layout(runVector, struts, lineCount, isPaginated));
</del><ins>+    return std::unique_ptr&lt;Layout&gt;(new (NotNull, slot) Layout(runVector, lineCount));
</ins><span class="cx"> }
</span><span class="cx"> 
</span><del>-Layout::Layout(const RunVector&amp; runVector, SimpleLineStruts&amp; struts, unsigned lineCount, bool isPaginated)
</del><ins>+Layout::Layout(const RunVector&amp; runVector, unsigned lineCount)
</ins><span class="cx">     : m_lineCount(lineCount)
</span><span class="cx">     , m_runCount(runVector.size())
</span><del>-    , m_isPaginated(isPaginated)
-    , m_lineStruts(WTFMove(struts))
</del><span class="cx"> {
</span><span class="cx">     memcpy(m_runs, runVector.data(), m_runCount * sizeof(Run));
</span><span class="cx"> }
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit216SourceWebCorerenderingSimpleLineLayouth"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayout.h (213140 => 213141)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayout.h        2017-02-28 09:42:18 UTC (rev 213140)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayout.h        2017-02-28 09:46:51 UTC (rev 213141)
</span><span class="lines">@@ -76,7 +76,7 @@
</span><span class="cx"> public:
</span><span class="cx">     using RunVector = Vector&lt;Run, 10&gt;;
</span><span class="cx">     using SimpleLineStruts = Vector&lt;SimpleLineStrut, 4&gt;;
</span><del>-    static std::unique_ptr&lt;Layout&gt; create(const RunVector&amp;, SimpleLineStruts&amp;, unsigned lineCount, bool isPaginated);
</del><ins>+    static std::unique_ptr&lt;Layout&gt; create(const RunVector&amp;, unsigned lineCount);
</ins><span class="cx"> 
</span><span class="cx">     unsigned lineCount() const { return m_lineCount; }
</span><span class="cx"> 
</span><span class="lines">@@ -83,15 +83,17 @@
</span><span class="cx">     unsigned runCount() const { return m_runCount; }
</span><span class="cx">     const Run&amp; runAt(unsigned i) const { return m_runs[i]; }
</span><span class="cx"> 
</span><ins>+    void setIsPaginated() { m_isPaginated = true; }
</ins><span class="cx">     bool isPaginated() const { return m_isPaginated; }
</span><span class="cx">     bool hasLineStruts() const { return !m_lineStruts.isEmpty(); }
</span><ins>+    void setLineStruts(SimpleLineStruts&amp;&amp; lineStruts) { m_lineStruts = lineStruts; }
</ins><span class="cx">     const SimpleLineStruts&amp; struts() const { return m_lineStruts; }
</span><span class="cx"> private:
</span><del>-    Layout(const RunVector&amp;, SimpleLineStruts&amp;, unsigned lineCount, bool isPaginated);
</del><ins>+    Layout(const RunVector&amp;, unsigned lineCount);
</ins><span class="cx"> 
</span><span class="cx">     unsigned m_lineCount;
</span><span class="cx">     unsigned m_runCount;
</span><del>-    bool m_isPaginated;
</del><ins>+    bool m_isPaginated { false };
</ins><span class="cx">     SimpleLineStruts m_lineStruts;
</span><span class="cx">     Run m_runs[0];
</span><span class="cx"> };
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit216SourceWebCorerenderingSimpleLineLayoutPaginationcpp"></a>
<div class="addfile"><h4>Added: releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayoutPagination.cpp (0 => 213141)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayoutPagination.cpp                                (rev 0)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayoutPagination.cpp        2017-02-28 09:46:51 UTC (rev 213141)
</span><span class="lines">@@ -0,0 +1,155 @@
</span><ins>+/*
+ * Copyright (C) 2017 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include &quot;config.h&quot;
+#include &quot;SimpleLineLayoutPagination.h&quot;
+
+#include &quot;RenderBlockFlow.h&quot;
+#include &quot;SimpleLineLayout.h&quot;
+#include &quot;SimpleLineLayoutFunctions.h&quot;
+
+namespace WebCore {
+namespace SimpleLineLayout {
+
+struct PaginatedLine {
+    LayoutUnit top;
+    LayoutUnit bottom;
+    LayoutUnit height; // Same value for each lines atm.
+};
+using PaginatedLines = Vector&lt;PaginatedLine, 20&gt;;
+
+static PaginatedLine computeLineTopAndBottomWithOverflow(const RenderBlockFlow&amp; flow, unsigned lineIndex, Layout::SimpleLineStruts&amp; struts)
+{
+    // FIXME: Add visualOverflowForDecorations.
+    auto&amp; fontMetrics = flow.style().fontCascade().fontMetrics();
+    auto ascent = fontMetrics.floatAscent();
+    auto descent = fontMetrics.floatDescent();
+    auto lineHeight = lineHeightFromFlow(flow);
+    LayoutUnit offset = flow.borderAndPaddingBefore();
+    for (auto&amp; strut : struts) {
+        if (strut.lineBreak &gt; lineIndex)
+            break;
+        offset += strut.offset;
+    }
+    if (ascent + descent &lt;= lineHeight) {
+        auto topPosition = lineIndex * lineHeight + offset;
+        return { topPosition, topPosition + lineHeight, lineHeight };
+    }
+    auto baseline = baselineFromFlow(flow);
+    auto topPosition = lineIndex * lineHeight + offset + baseline - ascent;
+    auto bottomPosition = topPosition + ascent + descent;
+    return { topPosition, bottomPosition, bottomPosition - topPosition };
+}
+
+static unsigned computeLineBreakIndex(unsigned breakCandidate, unsigned lineCount, unsigned widows, const Layout::SimpleLineStruts&amp; struts)
+{
+    // First line does not fit the current page.
+    if (!breakCandidate)
+        return breakCandidate;
+    
+    auto remainingLineCount = lineCount - breakCandidate;
+    if (widows &lt;= remainingLineCount)
+        return breakCandidate;
+    
+    // Only break after the first line with widows.
+    auto lineBreak = std::max&lt;int&gt;(lineCount - widows, 1);
+    // Break on current page only.
+    if (struts.isEmpty())
+        return lineBreak;
+    ASSERT(struts.last().lineBreak + 1 &lt; lineCount);
+    return std::max&lt;unsigned&gt;(struts.last().lineBreak + 1, lineBreak);
+}
+
+static LayoutUnit computeOffsetAfterLineBreak(LayoutUnit lineBreakPosition, bool isFirstLine, bool atTheTopOfColumnOrPage, const RenderBlockFlow&amp; flow)
+{
+    // No offset for top of the page lines unless widows pushed the line break.
+    LayoutUnit offset = isFirstLine ? flow.borderAndPaddingBefore() : LayoutUnit();
+    if (atTheTopOfColumnOrPage)
+        return offset;
+    return offset + flow.pageRemainingLogicalHeightForOffset(lineBreakPosition, RenderBlockFlow::ExcludePageBoundary);
+}
+
+static void setPageBreakForLine(unsigned lineBreakIndex, PaginatedLines&amp; lines, RenderBlockFlow&amp; flow, Layout::SimpleLineStruts&amp; struts,
+    bool atTheTopOfColumnOrPage)
+{
+    if (!lineBreakIndex) {
+        // When the first line does not fit the current page, just add a page break in front and set the strut on the block.
+        auto line = lines.first();
+        auto remainingLogicalHeight = flow.pageRemainingLogicalHeightForOffset(line.top, RenderBlockFlow::ExcludePageBoundary);
+        flow.setPageBreak(line.top, line.height - remainingLogicalHeight);
+        flow.setPaginationStrut(remainingLogicalHeight);
+        return;
+    }
+    auto beforeLineBreak = lines.at(lineBreakIndex - 1);
+    auto spaceShortage = flow.pageRemainingLogicalHeightForOffset(beforeLineBreak.top, RenderBlockFlow::ExcludePageBoundary) - beforeLineBreak.height;
+    flow.setPageBreak(beforeLineBreak.bottom, spaceShortage);
+    struts.append({ lineBreakIndex, computeOffsetAfterLineBreak(lines[lineBreakIndex].top, !lineBreakIndex, atTheTopOfColumnOrPage, flow) });
+}
+
+static void updateMinimumPageHeight(RenderBlockFlow&amp; flow, unsigned lineCount)
+{
+    auto&amp; style = flow.style();
+    auto widows = style.hasAutoWidows() ? 1 : std::max&lt;int&gt;(style.widows(), 1);
+    auto orphans = style.hasAutoOrphans() ? 1 : std::max&lt;int&gt;(style.orphans(), 1);
+    auto minimumLineCount = std::min&lt;unsigned&gt;(std::max(widows, orphans), lineCount);
+    flow.updateMinimumPageHeight(0, minimumLineCount * lineHeightFromFlow(flow));
+}
+
+void adjustLinePositionsForPagination(SimpleLineLayout::Layout&amp; simpleLines, RenderBlockFlow&amp; flow)
+{
+    Layout::SimpleLineStruts struts;
+    auto lineCount = simpleLines.lineCount();
+    updateMinimumPageHeight(flow, lineCount);
+    // First pass with no pagination offset?
+    if (!flow.pageLogicalHeightForOffset(0))
+        return;
+    unsigned lineIndex = 0;
+    auto widows = flow.style().hasAutoWidows() ? 1 : std::max&lt;int&gt;(flow.style().widows(), 1);
+    PaginatedLines lines;
+    for (unsigned runIndex = 0; runIndex &lt; simpleLines.runCount(); ++runIndex) {
+        auto&amp; run = simpleLines.runAt(runIndex);
+        if (!run.isEndOfLine)
+            continue;
+
+        auto line = computeLineTopAndBottomWithOverflow(flow, lineIndex, struts);
+        lines.append(line);
+        auto remainingHeight = flow.pageRemainingLogicalHeightForOffset(line.top, RenderBlockFlow::ExcludePageBoundary);
+        auto atTheTopOfColumnOrPage = flow.pageLogicalHeightForOffset(line.top) == remainingHeight;
+        if (line.height &gt; remainingHeight || (atTheTopOfColumnOrPage &amp;&amp; lineIndex)) {
+            auto lineBreakIndex = computeLineBreakIndex(lineIndex, lineCount, widows, struts);
+            // Are we still at the top of the column/page?
+            atTheTopOfColumnOrPage = atTheTopOfColumnOrPage ? lineIndex == lineBreakIndex : false;
+            setPageBreakForLine(lineBreakIndex, lines, flow, struts, atTheTopOfColumnOrPage);
+            // Recompute line positions that we already visited but window break pushed them to a new page.
+            for (auto i = lineBreakIndex; i &lt; lines.size(); ++i)
+                lines.at(i) = computeLineTopAndBottomWithOverflow(flow, i, struts);
+        }
+        ++lineIndex;
+    }
+    simpleLines.setLineStruts(WTFMove(struts));
+}
+
+}
+}
</ins></span></pre></div>
<a id="releasesWebKitGTKwebkit216SourceWebCorerenderingSimpleLineLayoutPaginationh"></a>
<div class="addfile"><h4>Added: releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayoutPagination.h (0 => 213141)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayoutPagination.h                                (rev 0)
+++ releases/WebKitGTK/webkit-2.16/Source/WebCore/rendering/SimpleLineLayoutPagination.h        2017-02-28 09:46:51 UTC (rev 213141)
</span><span class="lines">@@ -0,0 +1,39 @@
</span><ins>+/*
+ * Copyright (C) 2017 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#pragma once
+
+namespace WebCore {
+
+class RenderBlockFlow;
+
+namespace SimpleLineLayout {
+
+class Layout;
+    
+void adjustLinePositionsForPagination(Layout&amp;, RenderBlockFlow&amp;);
+
+}
+}
</ins></span></pre>
</div>
</div>

</body>
</html>