[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

hyatt at apple.com hyatt at apple.com
Wed Dec 22 15:18:23 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 074b7584f0fc6d0f1c683d353482a8b1d1de808f
Author: hyatt at apple.com <hyatt at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Sat Oct 30 00:38:31 2010 +0000

    https://bugs.webkit.org/show_bug.cgi?id=48663
    
    Reviewed by Sam Weinig.
    
    Make repaint invalidation work with vertical lines.  Rewrite linesBoundingBox for RenderText and
    RenderInline to give the correct rectangle back for vertical lines.  Also patch linesVisibleOverflowBoundingBox
    to give back the correct rectangle for vertical lines.
    
    Fix bugs in the overflow accessors of InlineFlowBox when m_overflow was 0.
    
    Added fast/repaint/inline-vertical-lr-overflow.html
    
    WebCore:
    
    * rendering/InlineBox.cpp:
    (WebCore::InlineBox::adjustForFlippedBlocksWritingMode):
    * rendering/InlineFlowBox.h:
    (WebCore::InlineFlowBox::logicalLeftVisibleOverflow):
    (WebCore::InlineFlowBox::logicalRightVisibleOverflow):
    (WebCore::InlineFlowBox::bottomLayoutOverflow):
    (WebCore::InlineFlowBox::rightLayoutOverflow):
    (WebCore::InlineFlowBox::bottomVisualOverflow):
    (WebCore::InlineFlowBox::rightVisualOverflow):
    * rendering/RenderBox.cpp:
    (WebCore::RenderBox::adjustForFlippedBlocksWritingMode):
    * rendering/RenderBox.h:
    * rendering/RenderInline.cpp:
    (WebCore::RenderInline::linesBoundingBox):
    (WebCore::RenderInline::linesVisibleOverflowBoundingBox):
    (WebCore::RenderInline::clippedOverflowRectForRepaint):
    * rendering/RenderText.cpp:
    (WebCore::RenderText::linesBoundingBox):
    
    LayoutTests:
    
    * fast/repaint/inline-vertical-rl-overflow.html: Added.
    * platform/mac/fast/blockflow/background-vertical-lr-expected.txt:
    * platform/mac/fast/blockflow/background-vertical-rl-expected.txt:
    * platform/mac/fast/blockflow/basic-vertical-line-expected.txt:
    * platform/mac/fast/blockflow/border-image-vertical-lr-expected.txt:
    * platform/mac/fast/blockflow/border-image-vertical-rl-expected.txt:
    * platform/mac/fast/blockflow/border-radius-clipping-vertical-lr-expected.txt:
    * platform/mac/fast/blockflow/border-vertical-lr-expected.checksum:
    * platform/mac/fast/blockflow/border-vertical-lr-expected.png:
    * platform/mac/fast/blockflow/border-vertical-lr-expected.txt:
    * platform/mac/fast/blockflow/box-shadow-vertical-lr-expected.txt:
    * platform/mac/fast/blockflow/box-shadow-vertical-rl-expected.txt:
    * platform/mac/fast/blockflow/english-lr-text-expected.txt:
    * platform/mac/fast/blockflow/english-rl-text-expected.txt:
    * platform/mac/fast/blockflow/japanese-lr-text-expected.txt:
    * platform/mac/fast/blockflow/japanese-rl-text-expected.txt:
    * platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.checksum: Added.
    * platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.png: Added.
    * platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.txt: Added.
    * platform/mac/fast/text/international/vertical-text-glyph-test-expected.txt:
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@70959 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index b56c8e1..018e1af 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,38 @@
+2010-10-29  David Hyatt  <hyatt at apple.com>
+
+        Reviewed by Sam Weinig.
+
+        https://bugs.webkit.org/show_bug.cgi?id=48663
+
+        Make repaint invalidation work with vertical lines.  Rewrite linesBoundingBox for RenderText and
+        RenderInline to give the correct rectangle back for vertical lines.  Also patch linesVisibleOverflowBoundingBox
+        to give back the correct rectangle for vertical lines.
+        
+        Fix bugs in the overflow accessors of InlineFlowBox when m_overflow was 0.
+
+        Added fast/repaint/inline-vertical-lr-overflow.html
+
+        * fast/repaint/inline-vertical-rl-overflow.html: Added.
+        * platform/mac/fast/blockflow/background-vertical-lr-expected.txt:
+        * platform/mac/fast/blockflow/background-vertical-rl-expected.txt:
+        * platform/mac/fast/blockflow/basic-vertical-line-expected.txt:
+        * platform/mac/fast/blockflow/border-image-vertical-lr-expected.txt:
+        * platform/mac/fast/blockflow/border-image-vertical-rl-expected.txt:
+        * platform/mac/fast/blockflow/border-radius-clipping-vertical-lr-expected.txt:
+        * platform/mac/fast/blockflow/border-vertical-lr-expected.checksum:
+        * platform/mac/fast/blockflow/border-vertical-lr-expected.png:
+        * platform/mac/fast/blockflow/border-vertical-lr-expected.txt:
+        * platform/mac/fast/blockflow/box-shadow-vertical-lr-expected.txt:
+        * platform/mac/fast/blockflow/box-shadow-vertical-rl-expected.txt:
+        * platform/mac/fast/blockflow/english-lr-text-expected.txt:
+        * platform/mac/fast/blockflow/english-rl-text-expected.txt:
+        * platform/mac/fast/blockflow/japanese-lr-text-expected.txt:
+        * platform/mac/fast/blockflow/japanese-rl-text-expected.txt:
+        * platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.checksum: Added.
+        * platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.png: Added.
+        * platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.txt: Added.
+        * platform/mac/fast/text/international/vertical-text-glyph-test-expected.txt:
+
 2010-10-29  James Robinson  <jamesr at chromium.org>
 
         Update pixel expectations for Snow Leopard for tests in tables/mozilla/marvin.
diff --git a/LayoutTests/fast/repaint/inline-vertical-rl-overflow.html b/LayoutTests/fast/repaint/inline-vertical-rl-overflow.html
new file mode 100644
index 0000000..0ccdf31
--- /dev/null
+++ b/LayoutTests/fast/repaint/inline-vertical-rl-overflow.html
@@ -0,0 +1,10 @@
+<script src="resources/repaint.js"></script>
+<script>
+    function repaintTest()
+    {
+        document.getElementById("target").style.webkitTextStrokeColor = "green";
+    }
+</script>
+<body onload="runRepaintTest()" style="padding: 50px; -webkit-writing-mode:vertical-lr">
+    <div><span id="target" style="font-family: Ahem; font-size: 50px; -webkit-text-stroke: 50px red;">A&nbsp;&nbsp;B</span></div>
+</body>
diff --git a/LayoutTests/platform/mac/fast/blockflow/background-vertical-lr-expected.txt b/LayoutTests/platform/mac/fast/blockflow/background-vertical-lr-expected.txt
index c4ac399..89c81a8 100644
--- a/LayoutTests/platform/mac/fast/blockflow/background-vertical-lr-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/background-vertical-lr-expected.txt
@@ -3,8 +3,8 @@ layer at (0,0) size 800x600
 layer at (0,0) size 456x600
   RenderBlock {HTML} at (0,0) size 456x600
     RenderBody {BODY} at (8,8) size 440x584
-      RenderInline {SPAN} at (0,0) size 220x98
+      RenderInline {SPAN} at (0,0) size 268x50
         RenderBlock {DIV} at (71,50) size 0x50
-        RenderBR {BR} at (50,100) size 0x98
+        RenderBR {BR} at (50,100) size 98x0
         RenderBlock {DIV} at (241,50) size 0x50
       RenderText {#text} at (0,0) size 0x0
diff --git a/LayoutTests/platform/mac/fast/blockflow/background-vertical-rl-expected.txt b/LayoutTests/platform/mac/fast/blockflow/background-vertical-rl-expected.txt
index 581a404..e6d9ac5 100644
--- a/LayoutTests/platform/mac/fast/blockflow/background-vertical-rl-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/background-vertical-rl-expected.txt
@@ -3,8 +3,8 @@ layer at (0,0) size 800x600
 layer at (344,0) size 456x600
   RenderBlock {HTML} at (0,0) size 456x600
     RenderBody {BODY} at (8,8) size 440x584
-      RenderInline {SPAN} at (0,0) size 220x98
+      RenderInline {SPAN} at (0,0) size 268x50
         RenderBlock {DIV} at (163,50) size 0x50
-        RenderBR {BR} at (86,100) size 0x98
+        RenderBR {BR} at (86,100) size 98x0
         RenderBlock {DIV} at (333,50) size 0x50
       RenderText {#text} at (0,0) size 0x0
diff --git a/LayoutTests/platform/mac/fast/blockflow/basic-vertical-line-expected.txt b/LayoutTests/platform/mac/fast/blockflow/basic-vertical-line-expected.txt
index 48d996a..5a0e486 100644
--- a/LayoutTests/platform/mac/fast/blockflow/basic-vertical-line-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/basic-vertical-line-expected.txt
@@ -4,16 +4,16 @@ layer at (0,0) size 800x600
   RenderBlock {HTML} at (0,0) size 800x600
     RenderBody {BODY} at (8,8) size 784x584
       RenderBlock {DIV} at (0,0) size 316x304 [border: (2px solid #800000)]
-        RenderInline {SPAN} at (0,0) size 220x18 [border: (5px solid #000000) none (5px solid #000000) none]
+        RenderInline {SPAN} at (0,0) size 18x220 [border: (5px solid #000000) none (5px solid #000000) none]
           RenderImage {IMG} at (6,12) size 100x200 [bgcolor=#008000]
-        RenderText {#text} at (2,222) size 4x18
+        RenderText {#text} at (2,222) size 18x4
           text run at (2,222) width 4: " "
         RenderBR {BR} at (6,226) size 0x0
-        RenderInline {SPAN} at (0,0) size 220x18 [border: (5px solid #000000) none (5px solid #000000) none]
+        RenderInline {SPAN} at (0,0) size 18x220 [border: (5px solid #000000) none (5px solid #000000) none]
           RenderImage {IMG} at (110,12) size 100x200 [bgcolor=#008000]
-        RenderText {#text} at (106,222) size 4x18
+        RenderText {#text} at (106,222) size 18x4
           text run at (106,222) width 4: " "
         RenderBR {BR} at (110,226) size 0x0
-        RenderInline {SPAN} at (0,0) size 220x18 [border: (5px solid #000000) none (5px solid #000000) none]
+        RenderInline {SPAN} at (0,0) size 18x220 [border: (5px solid #000000) none (5px solid #000000) none]
           RenderImage {IMG} at (214,12) size 100x200 [bgcolor=#008000]
         RenderText {#text} at (0,0) size 0x0
diff --git a/LayoutTests/platform/mac/fast/blockflow/border-image-vertical-lr-expected.txt b/LayoutTests/platform/mac/fast/blockflow/border-image-vertical-lr-expected.txt
index 8e06d69..0d829c5 100644
--- a/LayoutTests/platform/mac/fast/blockflow/border-image-vertical-lr-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/border-image-vertical-lr-expected.txt
@@ -3,8 +3,8 @@ layer at (0,0) size 800x600
 layer at (0,0) size 460x600
   RenderBlock {HTML} at (0,0) size 460x600
     RenderBody {BODY} at (8,8) size 444x584
-      RenderInline {SPAN} at (0,0) size 252x121 [border: (21px none #000000) (30px none #000000) (21px none #000000)]
+      RenderInline {SPAN} at (0,0) size 323x80 [border: (21px none #000000) (30px none #000000) (21px none #000000)]
         RenderBlock {DIV} at (93,101) size 0x25
-        RenderBR {BR} at (71,126) size 0x100
+        RenderBR {BR} at (71,126) size 100x0
         RenderBlock {DIV} at (265,50) size 0x50
       RenderText {#text} at (0,0) size 0x0
diff --git a/LayoutTests/platform/mac/fast/blockflow/border-image-vertical-rl-expected.txt b/LayoutTests/platform/mac/fast/blockflow/border-image-vertical-rl-expected.txt
index 638a379..28519c2 100644
--- a/LayoutTests/platform/mac/fast/blockflow/border-image-vertical-rl-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/border-image-vertical-rl-expected.txt
@@ -3,8 +3,8 @@ layer at (0,0) size 800x600
 layer at (340,0) size 460x600
   RenderBlock {HTML} at (0,0) size 460x600
     RenderBody {BODY} at (8,8) size 444x584
-      RenderInline {SPAN} at (0,0) size 252x121 [border: (21px none #000000) (30px none #000000) (21px none #000000)]
+      RenderInline {SPAN} at (0,0) size 323x80 [border: (21px none #000000) (30px none #000000) (21px none #000000)]
         RenderBlock {DIV} at (164,101) size 0x25
-        RenderBR {BR} at (86,126) size 0x100
+        RenderBR {BR} at (86,126) size 100x0
         RenderBlock {DIV} at (336,50) size 0x50
       RenderText {#text} at (0,0) size 0x0
diff --git a/LayoutTests/platform/mac/fast/blockflow/border-radius-clipping-vertical-lr-expected.txt b/LayoutTests/platform/mac/fast/blockflow/border-radius-clipping-vertical-lr-expected.txt
index 88c346d..5a3715c 100644
--- a/LayoutTests/platform/mac/fast/blockflow/border-radius-clipping-vertical-lr-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/border-radius-clipping-vertical-lr-expected.txt
@@ -4,10 +4,10 @@ layer at (0,0) size 785x621
   RenderBlock {HTML} at (0,0) size 785x600
     RenderBody {BODY} at (8,8) size 727x584
       RenderBlock {DIV} at (0,0) size 144x600
-        RenderInline {SPAN} at (0,0) size 613x65 [bgcolor=#0000FF]
+        RenderInline {SPAN} at (0,0) size 137x613 [bgcolor=#0000FF]
           RenderText {#text} at (0,0) size 0x0
-          RenderInline {SPAN} at (0,0) size 598x50 [bgcolor=#FFFFE0] [border: (5px solid #008000)]
-            RenderText {#text} at (5,35) size 578x20
+          RenderInline {SPAN} at (0,0) size 137x613 [bgcolor=#FFFFE0] [border: (5px solid #008000)]
+            RenderText {#text} at (5,35) size 127x613
               text run at (5,35) width 578: "This sentence is too long to fit"
               text run at (77,0) width 302: "on a single line."
         RenderText {#text} at (0,0) size 0x0
diff --git a/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.checksum b/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.checksum
index 8307b9c..8ae7bbd 100644
--- a/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.checksum
+++ b/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.checksum
@@ -1 +1 @@
-30657bb8adbb3c333bf2920cae041ad0
\ No newline at end of file
+902397878764a7659f5b994fc8d5d02c
\ No newline at end of file
diff --git a/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.png b/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.png
index 4276b39..482aef0 100644
Binary files a/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.png and b/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.png differ
diff --git a/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.txt b/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.txt
index 360aec9..d074c62 100644
--- a/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/border-vertical-lr-expected.txt
@@ -1,25 +1,25 @@
-layer at (0,0) size 1181x585
-  RenderView at (0,0) size 800x585
-layer at (0,0) size 1181x585
-  RenderBlock {HTML} at (0,0) size 772x585
-    RenderBody {BODY} at (8,8) size 756x569
-      RenderInline {SPAN} at (0,0) size 676x29 [border: (2px solid #000000)]
-        RenderText {#text} at (4,4) size 676x17
-          text run at (4,4) width 529: "\x{305B}\x{3063}\x{304B}\x{304F}\x{898B}\x{3064}\x{3051}\x{305F}\x{3059}\x{3070}\x{3089}\x{3057}\x{3044}\x{8A18}\x{4E8B}\x{304C}\x{3069}\x{3053}\x{306B}\x{3042}\x{3063}\x{305F}\x{304B}\x{5FD8}\x{308C}"
-          text run at (67,0) width 529: "\x{3066}\x{3057}\x{307E}\x{3063}\x{305F}\x{7D4C}\x{9A13}\x{306F}\x{3042}\x{308A}\x{307E}\x{3059}\x{304B}\x{306A}\x{3089}\x{30BF}\x{30A4}\x{30C8}\x{30EB}\x{3068}\x{30A2}\x{30C9}\x{30EC}\x{30B9}\x{3060}"
-          text run at (130,0) width 550: "\x{3051}\x{3067}\x{306A}\x{304F}\x{3001}\x{8A2A}\x{554F}\x{3057}\x{305F}\x{30A6}\x{30A7}\x{30D6}\x{30DA}\x{30FC}\x{30B8}\x{306E}\x{30B3}\x{30F3}\x{30C6}\x{30F3}\x{30C4}\x{304B}\x{3089}\x{3082}\x{691C}\x{7D22}"
-          text run at (193,0) width 212: "\x{3059}\x{308B}\x{3053}\x{3068}\x{304C}\x{3067}\x{304D}\x{307E}\x{3059}\x{3002}"
-      RenderText {#text} at (193,216) size 7x21
-        text run at (193,216) width 7: " "
+layer at (0,0) size 800x600
+  RenderView at (0,0) size 800x600
+layer at (0,0) size 772x600
+  RenderBlock {HTML} at (0,0) size 772x600
+    RenderBody {BODY} at (8,8) size 756x584
+      RenderInline {SPAN} at (0,0) size 218x554 [border: (2px solid #000000)]
+        RenderText {#text} at (4,4) size 210x554
+          text run at (4,4) width 550: "\x{305B}\x{3063}\x{304B}\x{304F}\x{898B}\x{3064}\x{3051}\x{305F}\x{3059}\x{3070}\x{3089}\x{3057}\x{3044}\x{8A18}\x{4E8B}\x{304C}\x{3069}\x{3053}\x{306B}\x{3042}\x{3063}\x{305F}\x{304B}\x{5FD8}\x{308C}\x{3066}"
+          text run at (67,0) width 550: "\x{3057}\x{307E}\x{3063}\x{305F}\x{7D4C}\x{9A13}\x{306F}\x{3042}\x{308A}\x{307E}\x{3059}\x{304B}\x{306A}\x{3089}\x{30BF}\x{30A4}\x{30C8}\x{30EB}\x{3068}\x{30A2}\x{30C9}\x{30EC}\x{30B9}\x{3060}\x{3051}\x{3067}"
+          text run at (130,0) width 550: "\x{306A}\x{304F}\x{3001}\x{8A2A}\x{554F}\x{3057}\x{305F}\x{30A6}\x{30A7}\x{30D6}\x{30DA}\x{30FC}\x{30B8}\x{306E}\x{30B3}\x{30F3}\x{30C6}\x{30F3}\x{30C4}\x{304B}\x{3089}\x{3082}\x{691C}\x{7D22}\x{3059}\x{308B}"
+          text run at (193,0) width 170: "\x{3053}\x{3068}\x{304C}\x{3067}\x{304D}\x{307E}\x{3059}\x{3002}"
+      RenderText {#text} at (193,174) size 21x7
+        text run at (193,174) width 7: " "
       RenderBR {BR} at (0,0) size 0x0
-      RenderBR {BR} at (252,0) size 0x21
-      RenderInline {SPAN} at (0,0) size 858x35 [border: (5px solid #000000)]
-        RenderText {#text} at (322,7) size 851x14
-          text run at (322,7) width 529: "\x{305B}\x{3063}\x{304B}\x{304F}\x{898B}\x{3064}\x{3051}\x{305F}\x{3059}\x{3070}\x{3089}\x{3057}\x{3044}\x{8A18}\x{4E8B}\x{304C}\x{3069}\x{3053}\x{306B}\x{3042}\x{3063}\x{305F}\x{304B}\x{5FD8}\x{308C}"
-          text run at (385,0) width 536: "\x{3066}\x{3057}\x{307E}\x{3063}\x{305F}\x{7D4C}\x{9A13}\x{306F}\x{3042}\x{308A}\x{307E}\x{3059}\x{304B} \x{306A}\x{3089}\x{30BF}\x{30A4}\x{30C8}\x{30EB}\x{3068}\x{30A2}\x{30C9}\x{30EC}\x{30B9}\x{3060}"
-          text run at (448,0) width 550: "\x{3051}\x{3067}\x{306A}\x{304F}\x{3001}\x{8A2A}\x{554F}\x{3057}\x{305F}\x{30A6}\x{30A7}\x{30D6}\x{30DA}\x{30FC}\x{30B8}\x{306E}\x{30B3}\x{30F3}\x{30C6}\x{30F3}\x{30C4}\x{304B}\x{3089}\x{3082}\x{691C}\x{7D22}"
-          text run at (511,0) width 550: "\x{3059}\x{308B}\x{3053}\x{3068}\x{304C}\x{3067}\x{304D}\x{307E}\x{3059}\x{3002}\x{8A2A}\x{554F}\x{3057}\x{305F}\x{30A6}\x{30A7}\x{30D6}\x{30DA}\x{30FC}\x{30B8}\x{306E}\x{30B3}\x{30F3}\x{30C6}\x{30F3}\x{30C4}"
-          text run at (574,0) width 529: "\x{304B}\x{3089}\x{3082}\x{691C}\x{7D22}\x{3059}\x{308B}\x{3053}\x{3068}\x{304C}\x{3067}\x{304D}\x{307E}\x{3059}\x{3002}\x{305B}\x{3063}\x{304B}\x{304F}\x{898B}\x{3064}\x{3051}\x{305F}\x{3059}\x{3070}"
-          text run at (637,0) width 529: "\x{3089}\x{3057}\x{3044}\x{8A18}\x{4E8B}\x{304C}\x{3069}\x{3053}\x{306B}\x{3042}\x{3063}\x{305F}\x{304B}\x{5FD8}\x{308C}\x{3066}\x{3057}\x{307E}\x{3063}\x{305F}\x{7D4C}\x{9A13}\x{306F}\x{3042}\x{308A}"
-          text run at (700,0) width 473: "\x{307E}\x{3059}\x{304B} \x{306A}\x{3089}\x{30BF}\x{30A4}\x{30C8}\x{30EB}\x{3068}\x{30A2}\x{30C9}\x{30EC}\x{30B9}\x{3060}\x{3051}\x{3067}\x{306A}\x{304F}\x{3001}\x{8A2A}\x{554F}"
+      RenderBR {BR} at (252,0) size 21x0
+      RenderInline {SPAN} at (0,0) size 413x558 [border: (5px solid #000000)]
+        RenderText {#text} at (322,7) size 399x558
+          text run at (322,7) width 550: "\x{305B}\x{3063}\x{304B}\x{304F}\x{898B}\x{3064}\x{3051}\x{305F}\x{3059}\x{3070}\x{3089}\x{3057}\x{3044}\x{8A18}\x{4E8B}\x{304C}\x{3069}\x{3053}\x{306B}\x{3042}\x{3063}\x{305F}\x{304B}\x{5FD8}\x{308C}\x{3066}"
+          text run at (385,0) width 558: "\x{3057}\x{307E}\x{3063}\x{305F}\x{7D4C}\x{9A13}\x{306F}\x{3042}\x{308A}\x{307E}\x{3059}\x{304B} \x{306A}\x{3089}\x{30BF}\x{30A4}\x{30C8}\x{30EB}\x{3068}\x{30A2}\x{30C9}\x{30EC}\x{30B9}\x{3060}\x{3051}\x{3067}"
+          text run at (448,0) width 550: "\x{306A}\x{304F}\x{3001}\x{8A2A}\x{554F}\x{3057}\x{305F}\x{30A6}\x{30A7}\x{30D6}\x{30DA}\x{30FC}\x{30B8}\x{306E}\x{30B3}\x{30F3}\x{30C6}\x{30F3}\x{30C4}\x{304B}\x{3089}\x{3082}\x{691C}\x{7D22}\x{3059}\x{308B}"
+          text run at (511,0) width 550: "\x{3053}\x{3068}\x{304C}\x{3067}\x{304D}\x{307E}\x{3059}\x{3002}\x{8A2A}\x{554F}\x{3057}\x{305F}\x{30A6}\x{30A7}\x{30D6}\x{30DA}\x{30FC}\x{30B8}\x{306E}\x{30B3}\x{30F3}\x{30C6}\x{30F3}\x{30C4}\x{304B}\x{3089}"
+          text run at (574,0) width 550: "\x{3082}\x{691C}\x{7D22}\x{3059}\x{308B}\x{3053}\x{3068}\x{304C}\x{3067}\x{304D}\x{307E}\x{3059}\x{3002}\x{305B}\x{3063}\x{304B}\x{304F}\x{898B}\x{3064}\x{3051}\x{305F}\x{3059}\x{3070}\x{3089}\x{3057}\x{3044}"
+          text run at (637,0) width 558: "\x{8A18}\x{4E8B}\x{304C}\x{3069}\x{3053}\x{306B}\x{3042}\x{3063}\x{305F}\x{304B}\x{5FD8}\x{308C}\x{3066}\x{3057}\x{307E}\x{3063}\x{305F}\x{7D4C}\x{9A13}\x{306F}\x{3042}\x{308A}\x{307E}\x{3059}\x{304B} \x{306A}"
+          text run at (700,0) width 381: "\x{3089}\x{30BF}\x{30A4}\x{30C8}\x{30EB}\x{3068}\x{30A2}\x{30C9}\x{30EC}\x{30B9}\x{3060}\x{3051}\x{3067}\x{306A}\x{304F}\x{3001}\x{8A2A}\x{554F}"
       RenderText {#text} at (0,0) size 0x0
diff --git a/LayoutTests/platform/mac/fast/blockflow/box-shadow-vertical-lr-expected.txt b/LayoutTests/platform/mac/fast/blockflow/box-shadow-vertical-lr-expected.txt
index aaf2bc6..f47392c 100644
--- a/LayoutTests/platform/mac/fast/blockflow/box-shadow-vertical-lr-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/box-shadow-vertical-lr-expected.txt
@@ -4,14 +4,14 @@ layer at (0,0) size 785x608
   RenderBlock {HTML} at (0,0) size 785x600
     RenderBody {BODY} at (8,8) size 769x584
       RenderBlock {DIV} at (0,0) size 144x600
-        RenderInline {SPAN} at (0,0) size 598x203 [bgcolor=#FFFFE0] [border: (5px solid #008000)]
-          RenderText {#text} at (5,21) size 578x173
+        RenderInline {SPAN} at (0,0) size 137x598 [bgcolor=#FFFFE0] [border: (5px solid #008000)]
+          RenderText {#text} at (5,21) size 127x578
             text run at (5,21) width 578: "This sentence is too long to fit"
             text run at (77,139) width 302: "on a single line."
         RenderText {#text} at (0,0) size 0x0
       RenderBlock {DIV} at (194,0) size 144x600
-        RenderInline {SPAN} at (0,0) size 598x203 [bgcolor=#FFFFE0] [border: (5px solid #008000)]
-          RenderText {#text} at (5,21) size 578x173
+        RenderInline {SPAN} at (0,0) size 137x598 [bgcolor=#FFFFE0] [border: (5px solid #008000)]
+          RenderText {#text} at (5,21) size 127x578
             text run at (5,21) width 578: "This sentence is too long to fit"
             text run at (77,139) width 302: "on a single line."
         RenderText {#text} at (0,0) size 0x0
diff --git a/LayoutTests/platform/mac/fast/blockflow/box-shadow-vertical-rl-expected.txt b/LayoutTests/platform/mac/fast/blockflow/box-shadow-vertical-rl-expected.txt
index a44c1cf..9637dce 100644
--- a/LayoutTests/platform/mac/fast/blockflow/box-shadow-vertical-rl-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/box-shadow-vertical-rl-expected.txt
@@ -4,14 +4,14 @@ layer at (0,0) size 785x608
   RenderBlock {HTML} at (0,0) size 785x600
     RenderBody {BODY} at (8,8) size 769x584
       RenderBlock {DIV} at (0,0) size 144x600
-        RenderInline {SPAN} at (0,0) size 598x203 [bgcolor=#FFFFE0] [border: (5px solid #008000)]
-          RenderText {#text} at (8,21) size 578x173
+        RenderInline {SPAN} at (0,0) size 137x598 [bgcolor=#FFFFE0] [border: (5px solid #008000)]
+          RenderText {#text} at (8,21) size 127x578
             text run at (8,21) width 578: "This sentence is too long to fit"
             text run at (80,139) width 302: "on a single line."
         RenderText {#text} at (0,0) size 0x0
       RenderBlock {DIV} at (194,0) size 144x600
-        RenderInline {SPAN} at (0,0) size 598x203 [bgcolor=#FFFFE0] [border: (5px solid #008000)]
-          RenderText {#text} at (8,21) size 578x173
+        RenderInline {SPAN} at (0,0) size 137x598 [bgcolor=#FFFFE0] [border: (5px solid #008000)]
+          RenderText {#text} at (8,21) size 127x578
             text run at (8,21) width 578: "This sentence is too long to fit"
             text run at (80,139) width 302: "on a single line."
         RenderText {#text} at (0,0) size 0x0
diff --git a/LayoutTests/platform/mac/fast/blockflow/english-lr-text-expected.txt b/LayoutTests/platform/mac/fast/blockflow/english-lr-text-expected.txt
index 5b12a55..7604a6b 100644
--- a/LayoutTests/platform/mac/fast/blockflow/english-lr-text-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/english-lr-text-expected.txt
@@ -4,31 +4,31 @@ layer at (0,0) size 800x600
   RenderBlock {HTML} at (0,0) size 800x600
     RenderBody {BODY} at (8,8) size 784x584
       RenderBlock {DIV} at (0,0) size 132x500
-        RenderInline {SPAN} at (0,0) size 395x22
-          RenderText {#text} at (0,0) size 395x22
+        RenderInline {SPAN} at (0,0) size 22x395
+          RenderText {#text} at (0,0) size 22x395
             text run at (0,0) width 395: "This text should be rotated 90 degrees and underlined."
-        RenderText {#text} at (0,395) size 5x22
+        RenderText {#text} at (0,395) size 22x5
           text run at (0,395) width 5: " "
         RenderBR {BR} at (5,400) size 0x0
-        RenderInline {SPAN} at (0,0) size 386x22
-          RenderText {#text} at (22,0) size 386x22
+        RenderInline {SPAN} at (0,0) size 22x386
+          RenderText {#text} at (22,0) size 22x386
             text run at (22,0) width 386: "This text should be rotated 90 degrees and overlined."
-        RenderText {#text} at (22,386) size 5x22
+        RenderText {#text} at (22,386) size 22x5
           text run at (22,386) width 5: " "
         RenderBR {BR} at (27,391) size 0x0
-        RenderInline {SPAN} at (0,0) size 423x22
-          RenderText {#text} at (44,0) size 423x22
+        RenderInline {SPAN} at (0,0) size 22x423
+          RenderText {#text} at (44,0) size 22x423
             text run at (44,0) width 423: "This text should be rotated 90 degrees and struck through."
-        RenderText {#text} at (44,423) size 5x22
+        RenderText {#text} at (44,423) size 22x5
           text run at (44,423) width 5: " "
         RenderBR {BR} at (49,428) size 0x0
-        RenderInline {SPAN} at (0,0) size 449x22
-          RenderText {#text} at (66,0) size 449x22
+        RenderInline {SPAN} at (0,0) size 22x449
+          RenderText {#text} at (66,0) size 22x449
             text run at (66,0) width 449: "This text should have a red shadow that is offset horizontally."
-        RenderText {#text} at (66,449) size 5x22
+        RenderText {#text} at (66,449) size 22x5
           text run at (66,449) width 5: " "
         RenderBR {BR} at (71,454) size 0x0
-        RenderBR {BR} at (88,0) size 0x22
-        RenderInline {SPAN} at (0,0) size 460x22
-          RenderText {#text} at (110,0) size 460x22
+        RenderBR {BR} at (88,0) size 22x0
+        RenderInline {SPAN} at (0,0) size 22x460
+          RenderText {#text} at (110,0) size 22x460
             text run at (110,0) width 460: "This text should have an overline plus horizontal green shadow"
diff --git a/LayoutTests/platform/mac/fast/blockflow/english-rl-text-expected.txt b/LayoutTests/platform/mac/fast/blockflow/english-rl-text-expected.txt
index 66c514c..51069ca 100644
--- a/LayoutTests/platform/mac/fast/blockflow/english-rl-text-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/english-rl-text-expected.txt
@@ -5,10 +5,10 @@ layer at (0,0) size 800x600
     RenderBody {BODY} at (8,8) size 504x584 [border: (2px solid #000000)]
       RenderBlock {DIV} at (18,2) size 204x580 [border: (2px solid #800000)]
         RenderBlock (floating) {DIV} at (2,478) size 100x100 [bgcolor=#00FF00]
-        RenderText {#text} at (2,2) size 280x18
+        RenderText {#text} at (2,2) size 36x472
           text run at (2,2) width 280: "Here is some text in a vertical-rl block flow. "
           text run at (2,282) width 192: "The block direction is right-to-"
           text run at (20,2) width 24: "left."
         RenderBR {BR} at (34,26) size 0x0
-        RenderText {#text} at (38,2) size 203x18
+        RenderText {#text} at (38,2) size 18x203
           text run at (38,2) width 203: "This line should also be vertical."
diff --git a/LayoutTests/platform/mac/fast/blockflow/japanese-lr-text-expected.txt b/LayoutTests/platform/mac/fast/blockflow/japanese-lr-text-expected.txt
index ee39777..c60ae6d 100644
--- a/LayoutTests/platform/mac/fast/blockflow/japanese-lr-text-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/japanese-lr-text-expected.txt
@@ -3,7 +3,7 @@ layer at (0,0) size 800x600
 layer at (0,0) size 398x600
   RenderBlock {HTML} at (0,0) size 398x600 [border: (10px solid #800000)]
     RenderBody {BODY} at (18,18) size 362x564 [border: (5px solid #000000)]
-      RenderText {#text} at (5,5) size 803x21
+      RenderText {#text} at (5,5) size 341x529
         text run at (5,5) width 529: "\x{305B}\x{3063}\x{304B}\x{304F}\x{898B}\x{3064}\x{3051}\x{305F}\x{3059}\x{3070}\x{3089}\x{3057}\x{3044}\x{8A18}\x{4E8B}\x{304C}\x{3069}\x{3053}\x{306B}\x{3042}\x{3063}\x{305F}\x{304B}\x{5FD8}\x{308C}"
         text run at (37,5) width 529: "\x{3066}\x{3057}\x{307E}\x{3063}\x{305F}\x{7D4C}\x{9A13}\x{306F}\x{3042}\x{308A}\x{307E}\x{3059}\x{304B}\x{306A}\x{3089}\x{30BF}\x{30A4}\x{30C8}\x{30EB}\x{3068}\x{30A2}\x{30C9}\x{30EC}\x{30B9}\x{3060}"
         text run at (69,5) width 529: "\x{3051}\x{3067}\x{306A}\x{304F}\x{3001}\x{8A2A}\x{554F}\x{3057}\x{305F}\x{30A6}\x{30A7}\x{30D6}\x{30DA}\x{30FC}\x{30B8}\x{306E}\x{30B3}\x{30F3}\x{30C6}\x{30F3}\x{30C4}\x{304B}\x{3089}\x{3082}\x{691C}"
diff --git a/LayoutTests/platform/mac/fast/blockflow/japanese-rl-text-expected.txt b/LayoutTests/platform/mac/fast/blockflow/japanese-rl-text-expected.txt
index 652c284..7df9b27 100644
--- a/LayoutTests/platform/mac/fast/blockflow/japanese-rl-text-expected.txt
+++ b/LayoutTests/platform/mac/fast/blockflow/japanese-rl-text-expected.txt
@@ -3,7 +3,7 @@ layer at (0,0) size 800x600
 layer at (402,0) size 398x600
   RenderBlock {HTML} at (0,0) size 398x600 [border: (10px solid #800000)]
     RenderBody {BODY} at (18,18) size 362x564 [border: (5px solid #000000)]
-      RenderText {#text} at (10,5) size 803x21
+      RenderText {#text} at (10,5) size 341x529
         text run at (10,5) width 529: "\x{305B}\x{3063}\x{304B}\x{304F}\x{898B}\x{3064}\x{3051}\x{305F}\x{3059}\x{3070}\x{3089}\x{3057}\x{3044}\x{8A18}\x{4E8B}\x{304C}\x{3069}\x{3053}\x{306B}\x{3042}\x{3063}\x{305F}\x{304B}\x{5FD8}\x{308C}"
         text run at (42,5) width 529: "\x{3066}\x{3057}\x{307E}\x{3063}\x{305F}\x{7D4C}\x{9A13}\x{306F}\x{3042}\x{308A}\x{307E}\x{3059}\x{304B}\x{306A}\x{3089}\x{30BF}\x{30A4}\x{30C8}\x{30EB}\x{3068}\x{30A2}\x{30C9}\x{30EC}\x{30B9}\x{3060}"
         text run at (74,5) width 529: "\x{3051}\x{3067}\x{306A}\x{304F}\x{3001}\x{8A2A}\x{554F}\x{3057}\x{305F}\x{30A6}\x{30A7}\x{30D6}\x{30DA}\x{30FC}\x{30B8}\x{306E}\x{30B3}\x{30F3}\x{30C6}\x{30F3}\x{30C4}\x{304B}\x{3089}\x{3082}\x{691C}"
diff --git a/LayoutTests/platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.checksum b/LayoutTests/platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.checksum
new file mode 100644
index 0000000..dc753c9
--- /dev/null
+++ b/LayoutTests/platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.checksum
@@ -0,0 +1 @@
+001a25517f0a9d241227ced7a38aaf09
\ No newline at end of file
diff --git a/LayoutTests/platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.png b/LayoutTests/platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.png
new file mode 100644
index 0000000..9a981d7
Binary files /dev/null and b/LayoutTests/platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.png differ
diff --git a/LayoutTests/platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.txt b/LayoutTests/platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.txt
new file mode 100644
index 0000000..9f8abc2
--- /dev/null
+++ b/LayoutTests/platform/mac/fast/repaint/inline-vertical-rl-overflow-expected.txt
@@ -0,0 +1,9 @@
+layer at (0,0) size 800x600
+  RenderView at (0,0) size 800x600
+layer at (0,0) size 800x600
+  RenderBlock {HTML} at (0,0) size 800x600
+    RenderBody {BODY} at (8,8) size 784x584
+      RenderBlock {DIV} at (50,50) size 50x484
+        RenderInline {SPAN} at (0,0) size 50x200 [textStrokeColor=#008000] [textStrokeWidth=50.00]
+          RenderText {#text} at (0,0) size 50x200
+            text run at (0,0) width 200: "A  B"
diff --git a/LayoutTests/platform/mac/fast/text/international/vertical-text-glyph-test-expected.txt b/LayoutTests/platform/mac/fast/text/international/vertical-text-glyph-test-expected.txt
index f0dd87e..72e46bc 100644
--- a/LayoutTests/platform/mac/fast/text/international/vertical-text-glyph-test-expected.txt
+++ b/LayoutTests/platform/mac/fast/text/international/vertical-text-glyph-test-expected.txt
@@ -8,7 +8,7 @@ layer at (0,0) size 785x635
           text run at (0,5) width 161: "Simple text path"
       RenderBlock (anonymous) at (0,53) size 769x235
         RenderBlock {SPAN} at (0,0) size 32x226
-          RenderText {#text} at (5,0) size 226x21
+          RenderText {#text} at (5,0) size 21x226
             text run at (5,0) width 226: "string\x{300C}\x{3042}\x{3001}\x{5909}\x{3063}\x{FF01}\x{300D}\x{3002}"
         RenderText {#text} at (0,0) size 0x0
       RenderBlock {HR} at (0,298) size 769x2 [border: (1px inset #000000)]
@@ -17,6 +17,6 @@ layer at (0,0) size 785x635
           text run at (0,5) width 181: "Complex text path"
       RenderBlock (anonymous) at (0,374) size 769x232
         RenderBlock {SPAN} at (0,0) size 32x223
-          RenderText {#text} at (5,0) size 223x21
+          RenderText {#text} at (5,0) size 21x223
             text run at (5,0) width 223: "string\x{300C}\x{3042}\x{3001}\x{5909}\x{3063}\x{FF01}\x{300D}\x{3002}"
         RenderText {#text} at (0,0) size 0x0
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index bbe8c4a..b6fba8c 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,36 @@
+2010-10-29  David Hyatt  <hyatt at apple.com>
+
+        Reviewed by Sam Weinig.
+
+        https://bugs.webkit.org/show_bug.cgi?id=48663
+
+        Make repaint invalidation work with vertical lines.  Rewrite linesBoundingBox for RenderText and
+        RenderInline to give the correct rectangle back for vertical lines.  Also patch linesVisibleOverflowBoundingBox
+        to give back the correct rectangle for vertical lines.
+        
+        Fix bugs in the overflow accessors of InlineFlowBox when m_overflow was 0.
+
+        Added fast/repaint/inline-vertical-lr-overflow.html
+
+        * rendering/InlineBox.cpp:
+        (WebCore::InlineBox::adjustForFlippedBlocksWritingMode):
+        * rendering/InlineFlowBox.h:
+        (WebCore::InlineFlowBox::logicalLeftVisibleOverflow):
+        (WebCore::InlineFlowBox::logicalRightVisibleOverflow):
+        (WebCore::InlineFlowBox::bottomLayoutOverflow):
+        (WebCore::InlineFlowBox::rightLayoutOverflow):
+        (WebCore::InlineFlowBox::bottomVisualOverflow):
+        (WebCore::InlineFlowBox::rightVisualOverflow):
+        * rendering/RenderBox.cpp:
+        (WebCore::RenderBox::adjustForFlippedBlocksWritingMode):
+        * rendering/RenderBox.h:
+        * rendering/RenderInline.cpp:
+        (WebCore::RenderInline::linesBoundingBox):
+        (WebCore::RenderInline::linesVisibleOverflowBoundingBox):
+        (WebCore::RenderInline::clippedOverflowRectForRepaint):
+        * rendering/RenderText.cpp:
+        (WebCore::RenderText::linesBoundingBox):
+
 2010-10-29  Mike Lawther  <mikelawther at chromium.org>
 
         Reviewed by James Robinson.
diff --git a/WebCore/WebCore.xcodeproj/project.pbxproj b/WebCore/WebCore.xcodeproj/project.pbxproj
index 6bc2e36..02cb0d6 100644
--- a/WebCore/WebCore.xcodeproj/project.pbxproj
+++ b/WebCore/WebCore.xcodeproj/project.pbxproj
@@ -21301,6 +21301,7 @@
 			isa = PBXProject;
 			buildConfigurationList = 149C284308902B11008A9EFC /* Build configuration list for PBXProject "WebCore" */;
 			compatibilityVersion = "Xcode 2.4";
+			developmentRegion = English;
 			hasScannedForEncodings = 1;
 			knownRegions = (
 				English,
diff --git a/WebCore/rendering/InlineBox.cpp b/WebCore/rendering/InlineBox.cpp
index 1ce68f9..6191253 100644
--- a/WebCore/rendering/InlineBox.cpp
+++ b/WebCore/rendering/InlineBox.cpp
@@ -295,12 +295,7 @@ void InlineBox::adjustForFlippedBlocksWritingMode(IntRect& rect)
 {
     if (!renderer()->style()->isFlippedBlocksWritingMode())
         return;
-    
-    RenderBlock* block = root()->block();
-    if (block->style()->isHorizontalWritingMode())
-        rect.setY(block->height() - rect.bottom());
-    else
-        rect.setX(block->width() - rect.right());
+    return root()->block()->adjustForFlippedBlocksWritingMode(rect);
 }
 
 } // namespace WebCore
diff --git a/WebCore/rendering/InlineFlowBox.h b/WebCore/rendering/InlineFlowBox.h
index a168f98..ee11162 100644
--- a/WebCore/rendering/InlineFlowBox.h
+++ b/WebCore/rendering/InlineFlowBox.h
@@ -182,15 +182,17 @@ public:
     int bottomVisibleOverflow() const { return std::max(bottomLayoutOverflow(), bottomVisualOverflow()); }
     int leftVisibleOverflow() const { return std::min(leftLayoutOverflow(), leftVisualOverflow()); }
     int rightVisibleOverflow() const { return std::max(rightLayoutOverflow(), rightVisualOverflow()); }
+    int logicalLeftVisibleOverflow() const { return std::min(logicalLeftLayoutOverflow(), logicalLeftVisualOverflow()); }
+    int logicalRightVisibleOverflow() const { return std::max(logicalRightLayoutOverflow(), logicalRightVisualOverflow()); }
     int logicalTopVisibleOverflow() const { return std::min(logicalTopLayoutOverflow(), logicalTopVisualOverflow()); }
     int logicalBottomVisibleOverflow() const { return std::max(logicalBottomLayoutOverflow(), logicalBottomVisualOverflow()); }
 
     IntRect visibleOverflowRect() const { return m_overflow ? m_overflow->visibleOverflowRect() : IntRect(m_x, m_y, width(), height());  }
 
     int topLayoutOverflow() const { return m_overflow ? m_overflow->topLayoutOverflow() : m_y; }
-    int bottomLayoutOverflow() const { return m_overflow ? m_overflow->bottomLayoutOverflow() : m_y + logicalHeight(); }
+    int bottomLayoutOverflow() const { return m_overflow ? m_overflow->bottomLayoutOverflow() : m_y + height(); }
     int leftLayoutOverflow() const { return m_overflow ? m_overflow->leftLayoutOverflow() : m_x; }
-    int rightLayoutOverflow() const { return m_overflow ? m_overflow->rightLayoutOverflow() : m_x + m_logicalWidth; }
+    int rightLayoutOverflow() const { return m_overflow ? m_overflow->rightLayoutOverflow() : m_x + width(); }
     IntRect layoutOverflowRect() const { return m_overflow ? m_overflow->layoutOverflowRect() : IntRect(m_x, m_y, width(), height()); }
     int logicalLeftLayoutOverflow() const { return renderer()->style()->isHorizontalWritingMode() ? leftLayoutOverflow() : topLayoutOverflow(); }
     int logicalRightLayoutOverflow() const { return renderer()->style()->isHorizontalWritingMode() ? rightLayoutOverflow() : bottomLayoutOverflow(); }
@@ -198,9 +200,9 @@ public:
     int logicalBottomLayoutOverflow() const { return renderer()->style()->isHorizontalWritingMode() ? bottomLayoutOverflow() : rightLayoutOverflow(); }
 
     int topVisualOverflow() const { return m_overflow ? m_overflow->topVisualOverflow() : m_y; }
-    int bottomVisualOverflow() const { return m_overflow ? m_overflow->bottomVisualOverflow() : m_y + logicalHeight(); }
+    int bottomVisualOverflow() const { return m_overflow ? m_overflow->bottomVisualOverflow() : m_y + height(); }
     int leftVisualOverflow() const { return m_overflow ? m_overflow->leftVisualOverflow() : m_x; }
-    int rightVisualOverflow() const { return m_overflow ? m_overflow->rightVisualOverflow() : m_x + m_logicalWidth; }
+    int rightVisualOverflow() const { return m_overflow ? m_overflow->rightVisualOverflow() : m_x + width(); }
     IntRect visualOverflowRect() const { return m_overflow ? m_overflow->visualOverflowRect() : IntRect(m_x, m_y, width(), height()); }
     int logicalLeftVisualOverflow() const { return renderer()->style()->isHorizontalWritingMode() ? leftVisualOverflow() : topVisualOverflow(); }
     int logicalRightVisualOverflow() const { return renderer()->style()->isHorizontalWritingMode() ? rightVisualOverflow() : bottomVisualOverflow(); }
diff --git a/WebCore/rendering/RenderBox.cpp b/WebCore/rendering/RenderBox.cpp
index 35e597f..0642e41 100644
--- a/WebCore/rendering/RenderBox.cpp
+++ b/WebCore/rendering/RenderBox.cpp
@@ -3211,6 +3211,17 @@ void RenderBox::adjustForFlippedBlocksWritingMode(RenderBox* child, IntPoint& po
         point.move(width() - child->width() - child->x() - (adjustment == ParentToChildFlippingAdjustment ? child->x() : 0), 0);
 }
 
+void RenderBox::adjustForFlippedBlocksWritingMode(IntRect& rect)
+{
+    if (!style()->isFlippedBlocksWritingMode())
+        return;
+    
+    if (style()->isHorizontalWritingMode())
+        rect.setY(height() - rect.bottom());
+    else
+        rect.setX(width() - rect.right());
+}
+
 int RenderBox::convertFromFlippedWritingMode(int logicalPosition)
 {
     if (!style()->isFlippedBlocksWritingMode())
diff --git a/WebCore/rendering/RenderBox.h b/WebCore/rendering/RenderBox.h
index 7854116..348b2f7 100644
--- a/WebCore/rendering/RenderBox.h
+++ b/WebCore/rendering/RenderBox.h
@@ -379,6 +379,7 @@ public:
 
     enum FlippingAdjustment { ChildToParentFlippingAdjustment, ParentToChildFlippingAdjustment };
     void adjustForFlippedBlocksWritingMode(RenderBox* child, IntPoint&, FlippingAdjustment);
+    void adjustForFlippedBlocksWritingMode(IntRect&); // Unflips a rect in our coordinate space.
     int convertFromFlippedWritingMode(int position);
     IntSize locationOffsetIncludingFlipping();
 
diff --git a/WebCore/rendering/RenderInline.cpp b/WebCore/rendering/RenderInline.cpp
index 4b28268..4615784 100644
--- a/WebCore/rendering/RenderInline.cpp
+++ b/WebCore/rendering/RenderInline.cpp
@@ -559,18 +559,22 @@ IntRect RenderInline::linesBoundingBox() const
     ASSERT(!firstLineBox() == !lastLineBox());  // Either both are null or both exist.
     if (firstLineBox() && lastLineBox()) {
         // Return the width of the minimal left side and the maximal right side.
-        int leftSide = 0;
-        int rightSide = 0;
+        int logicalLeftSide = 0;
+        int logicalRightSide = 0;
         for (InlineFlowBox* curr = firstLineBox(); curr; curr = curr->nextLineBox()) {
-            if (curr == firstLineBox() || curr->x() < leftSide)
-                leftSide = curr->x();
-            if (curr == firstLineBox() || curr->x() + curr->logicalWidth() > rightSide)
-                rightSide = curr->x() + curr->logicalWidth();
+            if (curr == firstLineBox() || curr->logicalLeft() < logicalLeftSide)
+                logicalLeftSide = curr->logicalLeft();
+            if (curr == firstLineBox() || curr->logicalRight() > logicalRightSide)
+                logicalRightSide = curr->logicalRight();
         }
-        result.setWidth(rightSide - leftSide);
-        result.setX(leftSide);
-        result.setHeight(lastLineBox()->y() + lastLineBox()->logicalHeight() - firstLineBox()->y());
-        result.setY(firstLineBox()->y());
+        
+        bool isHorizontal = style()->isHorizontalWritingMode();
+        
+        int x = isHorizontal ? logicalLeftSide : firstLineBox()->x();
+        int y = isHorizontal ? firstLineBox()->y() : logicalLeftSide;
+        int width = isHorizontal ? logicalRightSide - logicalLeftSide : lastLineBox()->logicalBottom() - x;
+        int height = isHorizontal ? lastLineBox()->logicalBottom() - y : logicalRightSide - logicalLeftSide;
+        result = IntRect(x, y, width, height);
     }
 
     return result;
@@ -582,15 +586,20 @@ IntRect RenderInline::linesVisibleOverflowBoundingBox() const
         return IntRect();
 
     // Return the width of the minimal left side and the maximal right side.
-    int leftSide = numeric_limits<int>::max();
-    int rightSide = numeric_limits<int>::min();
+    int logicalLeftSide = numeric_limits<int>::max();
+    int logicalRightSide = numeric_limits<int>::min();
     for (InlineFlowBox* curr = firstLineBox(); curr; curr = curr->nextLineBox()) {
-        leftSide = min(leftSide, curr->leftVisibleOverflow());
-        rightSide = max(rightSide, curr->rightVisibleOverflow());
+        logicalLeftSide = min(logicalLeftSide, curr->logicalLeftVisibleOverflow());
+        logicalRightSide = max(logicalRightSide, curr->logicalRightVisibleOverflow());
     }
 
-    return IntRect(leftSide, firstLineBox()->topVisibleOverflow(), rightSide - leftSide,
-        lastLineBox()->bottomVisibleOverflow() - firstLineBox()->topVisibleOverflow());
+    bool isHorizontal = style()->isHorizontalWritingMode();
+        
+    int x = isHorizontal ? logicalLeftSide : firstLineBox()->topVisibleOverflow();
+    int y = isHorizontal ? firstLineBox()->leftVisibleOverflow() : logicalLeftSide;
+    int width = isHorizontal ? logicalRightSide - logicalLeftSide : lastLineBox()->rightVisibleOverflow() - firstLineBox()->leftVisibleOverflow();
+    int height = isHorizontal ? lastLineBox()->bottomVisibleOverflow() - firstLineBox()->topVisibleOverflow() : logicalRightSide - logicalLeftSide;
+    return IntRect(x, y, width, height);
 }
 
 IntRect RenderInline::clippedOverflowRectForRepaint(RenderBoxModelObject* repaintContainer)
@@ -619,6 +628,8 @@ IntRect RenderInline::clippedOverflowRectForRepaint(RenderBoxModelObject* repain
     }
 
     IntRect r(-ow + left, -ow + top, boundingBox.width() + ow * 2, boundingBox.height() + ow * 2);
+    cb->adjustForFlippedBlocksWritingMode(r);
+
     if (cb->hasColumns())
         cb->adjustRectForColumns(r);
 
diff --git a/WebCore/rendering/RenderText.cpp b/WebCore/rendering/RenderText.cpp
index 510d830..f08e8fb 100644
--- a/WebCore/rendering/RenderText.cpp
+++ b/WebCore/rendering/RenderText.cpp
@@ -1237,18 +1237,22 @@ IntRect RenderText::linesBoundingBox() const
     ASSERT(!firstTextBox() == !lastTextBox());  // Either both are null or both exist.
     if (firstTextBox() && lastTextBox()) {
         // Return the width of the minimal left side and the maximal right side.
-        int leftSide = 0;
-        int rightSide = 0;
+        int logicalLeftSide = 0;
+        int logicalRightSide = 0;
         for (InlineTextBox* curr = firstTextBox(); curr; curr = curr->nextTextBox()) {
-            if (curr == firstTextBox() || curr->x() < leftSide)
-                leftSide = curr->x();
-            if (curr == firstTextBox() || curr->x() + curr->logicalWidth() > rightSide)
-                rightSide = curr->x() + curr->logicalWidth();
+            if (curr == firstTextBox() || curr->logicalLeft() < logicalLeftSide)
+                logicalLeftSide = curr->logicalLeft();
+            if (curr == firstTextBox() || curr->logicalRight() > logicalRightSide)
+                logicalRightSide = curr->logicalRight();
         }
-        result.setWidth(rightSide - leftSide);
-        result.setX(leftSide);
-        result.setHeight(lastTextBox()->y() + lastTextBox()->logicalHeight() - firstTextBox()->y());
-        result.setY(firstTextBox()->y());
+        
+        bool isHorizontal = style()->isHorizontalWritingMode();
+        
+        int x = isHorizontal ? logicalLeftSide : firstTextBox()->x();
+        int y = isHorizontal ? firstTextBox()->y() : logicalLeftSide;
+        int width = isHorizontal ? logicalRightSide - logicalLeftSide : lastTextBox()->logicalBottom() - x;
+        int height = isHorizontal ? lastTextBox()->logicalBottom() - y : logicalRightSide - logicalLeftSide;
+        result = IntRect(x, y, width, height);
     }
 
     return result;

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list