Title: [195201] releases/WebKitGTK/webkit-2.10
Revision
195201
Author
[email protected]
Date
2016-01-18 03:55:26 -0800 (Mon, 18 Jan 2016)

Log Message

Merge r194462 - Simple line layout: Text with stroke width is not positioned correctly.
https://bugs.webkit.org/show_bug.cgi?id=152614

Reviewed by Simon Fraser.

Visual overflow should not affect text position.

Source/WebCore:

Test: fast/text/simple-line-layout-text-position-with-stroke.html

* rendering/SimpleLineLayoutFunctions.cpp:
(WebCore::SimpleLineLayout::paintFlow):

LayoutTests:

* fast/text/simple-line-layout-text-position-with-stroke-expected.html: Added.
* fast/text/simple-line-layout-text-position-with-stroke.html: Added.

Modified Paths

Added Paths

Diff

Modified: releases/WebKitGTK/webkit-2.10/LayoutTests/ChangeLog (195200 => 195201)


--- releases/WebKitGTK/webkit-2.10/LayoutTests/ChangeLog	2016-01-18 11:55:07 UTC (rev 195200)
+++ releases/WebKitGTK/webkit-2.10/LayoutTests/ChangeLog	2016-01-18 11:55:26 UTC (rev 195201)
@@ -1,3 +1,15 @@
+2015-12-31  Zalan Bujtas  <[email protected]>
+
+        Simple line layout: Text with stroke width is not positioned correctly.
+        https://bugs.webkit.org/show_bug.cgi?id=152614
+
+        Reviewed by Simon Fraser.
+
+        Visual overflow should not affect text position.
+
+        * fast/text/simple-line-layout-text-position-with-stroke-expected.html: Added.
+        * fast/text/simple-line-layout-text-position-with-stroke.html: Added.
+
 2015-11-17  Zalan Bujtas  <[email protected]>
 
         Simple line layout: Add letter-spacing support.

Added: releases/WebKitGTK/webkit-2.10/LayoutTests/fast/text/simple-line-layout-text-position-with-stroke-expected.html (0 => 195201)


--- releases/WebKitGTK/webkit-2.10/LayoutTests/fast/text/simple-line-layout-text-position-with-stroke-expected.html	                        (rev 0)
+++ releases/WebKitGTK/webkit-2.10/LayoutTests/fast/text/simple-line-layout-text-position-with-stroke-expected.html	2016-01-18 11:55:26 UTC (rev 195201)
@@ -0,0 +1,18 @@
+<!DOCTYPE html>
+<html>
+<head>
+<title>This tests that we position text with stroke width correctly.</title>
+<style>
+    div {
+        -webkit-text-stroke-width: 2px;
+    }
+</style>
+<script>
+    if (window.internals)
+        internals.settings.setSimpleLineLayoutEnabled(false);
+</script>
+</head>
+<body>
+<div>foobar</div>
+</body>
+</html>

Added: releases/WebKitGTK/webkit-2.10/LayoutTests/fast/text/simple-line-layout-text-position-with-stroke.html (0 => 195201)


--- releases/WebKitGTK/webkit-2.10/LayoutTests/fast/text/simple-line-layout-text-position-with-stroke.html	                        (rev 0)
+++ releases/WebKitGTK/webkit-2.10/LayoutTests/fast/text/simple-line-layout-text-position-with-stroke.html	2016-01-18 11:55:26 UTC (rev 195201)
@@ -0,0 +1,14 @@
+<!DOCTYPE html>
+<html>
+<head>
+<title>This tests that we position text with stroke width correctly.</title>
+<style>
+    div {
+        -webkit-text-stroke-width: 2px;
+    }
+</style>
+</head>
+<body>
+<div>foobar</div>
+</body>
+</html>

Modified: releases/WebKitGTK/webkit-2.10/Source/WebCore/ChangeLog (195200 => 195201)


--- releases/WebKitGTK/webkit-2.10/Source/WebCore/ChangeLog	2016-01-18 11:55:07 UTC (rev 195200)
+++ releases/WebKitGTK/webkit-2.10/Source/WebCore/ChangeLog	2016-01-18 11:55:26 UTC (rev 195201)
@@ -1,3 +1,17 @@
+2015-12-31  Zalan Bujtas  <[email protected]>
+
+        Simple line layout: Text with stroke width is not positioned correctly.
+        https://bugs.webkit.org/show_bug.cgi?id=152614
+
+        Reviewed by Simon Fraser.
+
+        Visual overflow should not affect text position.
+
+        Test: fast/text/simple-line-layout-text-position-with-stroke.html
+
+        * rendering/SimpleLineLayoutFunctions.cpp:
+        (WebCore::SimpleLineLayout::paintFlow):
+
 2015-11-17  Zalan Bujtas  <[email protected]>
 
         Simple line layout: Add letter-spacing support.

Modified: releases/WebKitGTK/webkit-2.10/Source/WebCore/rendering/SimpleLineLayoutFunctions.cpp (195200 => 195201)


--- releases/WebKitGTK/webkit-2.10/Source/WebCore/rendering/SimpleLineLayoutFunctions.cpp	2016-01-18 11:55:07 UTC (rev 195200)
+++ releases/WebKitGTK/webkit-2.10/Source/WebCore/rendering/SimpleLineLayoutFunctions.cpp	2016-01-18 11:55:26 UTC (rev 195201)
@@ -86,8 +86,9 @@
             continue;
 
         FloatRect rect = run.rect();
-        rect.inflate(strokeOverflow);
-        if (paintRect.y() > rect.maxY() || paintRect.maxY() < rect.y())
+        FloatRect visualOverflowRect = rect;
+        visualOverflowRect.inflate(strokeOverflow);
+        if (paintRect.y() > visualOverflowRect.maxY() || paintRect.maxY() < visualOverflowRect.y())
             continue;
 
         TextRun textRun(run.text());
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to