[SCM] WebKit Debian packaging branch, webkit-1.3, updated. upstream/1.3.7-4207-g178b198

ossy at webkit.org ossy at webkit.org
Sun Feb 20 23:43:35 UTC 2011


The following commit has been merged in the webkit-1.3 branch:
commit da81509d48caa3fdb3368eb164b3dd7d7fd51da5
Author: ossy at webkit.org <ossy at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Mon Jan 24 16:37:56 2011 +0000

    Unreviewed.
    
    Add Qt specific expected results for passing editing/selections tests.
    Compared to Mac png files and Mac expected files. (part 1)
    
    * platform/qt/editing/selection/ [...]:
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@76521 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 4ec0407..f2fbcbf 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -2,6 +2,15 @@
 
         Unreviewed.
 
+        Add Qt specific expected results for passing editing/selections tests.
+        Compared to Mac png files and Mac expected files. (part 1)
+
+        * platform/qt/editing/selection/ [...]:
+
+2011-01-24  Csaba Osztrogonác  <ossy at webkit.org>
+
+        Unreviewed.
+
         RTL: selection.modify("move", "forward", "line") when cursor is at start of a line does not move down a line
         https://bugs.webkit.org/show_bug.cgi?id=51517
 
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-character-005-expected.txt b/LayoutTests/platform/qt/editing/selection/extend-by-character-005-expected.txt
index ded7e24..2ab7815 100644
--- a/LayoutTests/platform/qt/editing/selection/extend-by-character-005-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/extend-by-character-005-expected.txt
@@ -323,25 +323,26 @@ layer 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 (0,0) size 784x125 [border: (2px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 732x95
-          RenderInline {I} at (0,0) size 131x32
-            RenderText {#text} at (14,14) size 131x32
+      RenderBlock {DIV} at (0,0) size 784x121 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 698x94
+          RenderInline {I} at (0,0) size 120x31
+            RenderText {#text} at (14,14) size 120x31
               text run at (14,14) width 22: "F "
-              text run at (36,14) width 109: "and seven"
-          RenderText {#text} at (145,15) size 72x31
-            text run at (145,15) width 72: " years "
-          RenderInline {B} at (0,0) size 33x33
-            RenderText {#text} at (217,14) size 33x33
-              text run at (217,14) width 33: "as "
-          RenderText {#text} at (250,15) size 732x63
-            text run at (250,15) width 121: "our fathers "
-            text run at (371,15) width 375: "f upon this continent, a new nation, "
-            text run at (14,47) width 244: "conceived    in Liberty, "
-            text run at (258,47) width 421: "and dedicated to the proposition that all "
+              text run at (36,14) width 98: "and seven"
+          RenderText {#text} at (134,14) size 67x32
+            text run at (134,14) width 67: " years "
+          RenderInline {B} at (0,0) size 27x32
+            RenderText {#text} at (201,14) size 27x32
+              text run at (201,14) width 27: "as "
+          RenderText {#text} at (228,14) size 698x63
+            text run at (228,14) width 120: "our fathers "
+            text run at (348,14) width 358: "f upon this continent, a new nation,"
+            text run at (706,14) width 6: " "
+            text run at (14,45) width 241: "conceived    in Liberty, "
+            text run at (255,45) width 415: "and dedicated to the proposition that all "
           RenderBR {BR} at (0,0) size 0x0
-          RenderText {#text} at (14,79) size 244x31
-            text run at (14,79) width 244: "men are created equal."
+          RenderText {#text} at (14,76) size 235x32
+            text run at (14,76) width 235: "men are created equal."
         RenderText {#text} at (0,0) size 0x0
 selection start: position 0 of child 0 {#text} of child 0 {I} of child 1 {SPAN} of child 1 {DIV} of body
 selection end:   position 1 of child 0 {#text} of child 0 {I} of child 1 {SPAN} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-character-006-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-by-character-006-expected.checksum
new file mode 100644
index 0000000..08bc0a4
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-by-character-006-expected.checksum
@@ -0,0 +1 @@
+2cf5e3a26d756464a90b4139d6dda4fb
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-character-006-expected.png b/LayoutTests/platform/qt/editing/selection/extend-by-character-006-expected.png
new file mode 100644
index 0000000..8bef9ad
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-by-character-006-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-character-006-expected.txt b/LayoutTests/platform/qt/editing/selection/extend-by-character-006-expected.txt
index 0202178..d4dc53e 100644
--- a/LayoutTests/platform/qt/editing/selection/extend-by-character-006-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/extend-by-character-006-expected.txt
@@ -9,12 +9,10 @@ layer 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 (0,0) size 784x60 [border: (2px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 33x31
-          RenderText {#text} at (14,14) size 33x31
-            text run at (14,14) width 33: "foo"
-        RenderText {#text} at (0,0) size 0x0
-        RenderText {#text} at (0,0) size 0x0
+      RenderBlock {DIV} at (0,0) size 784x59 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 32x32
+          RenderText {#text} at (14,14) size 32x32
+            text run at (14,14) width 32: "foo"
         RenderText {#text} at (0,0) size 0x0
         RenderText {#text} at (0,0) size 0x0
 selection start: position 1 of child 0 {#text} of child 1 {SPAN} of child 3 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-line-anonymous-content-crash-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-by-line-anonymous-content-crash-expected.checksum
new file mode 100644
index 0000000..f991d7a
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-by-line-anonymous-content-crash-expected.checksum
@@ -0,0 +1 @@
+06298182b492a9015e13f290eb217b07
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-line-anonymous-content-crash-expected.png b/LayoutTests/platform/qt/editing/selection/extend-by-line-anonymous-content-crash-expected.png
new file mode 100644
index 0000000..0fb0185
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-by-line-anonymous-content-crash-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-sentence-001-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-by-sentence-001-expected.checksum
new file mode 100644
index 0000000..4bcefcc
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-by-sentence-001-expected.checksum
@@ -0,0 +1 @@
+1de2e63f32ac3b5d014746c08c6505bb
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-sentence-001-expected.png b/LayoutTests/platform/qt/editing/selection/extend-by-sentence-001-expected.png
new file mode 100644
index 0000000..c85cdb5
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-by-sentence-001-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-sentence-001-expected.txt b/LayoutTests/platform/qt/editing/selection/extend-by-sentence-001-expected.txt
index 89f7fa5..14aa2bf 100644
--- a/LayoutTests/platform/qt/editing/selection/extend-by-sentence-001-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/extend-by-sentence-001-expected.txt
@@ -10,18 +10,18 @@ layer 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 (0,0) size 784x92 [border: (2px solid #FF0000)]
-        RenderBlock {FRIJOLE} at (14,14) size 756x64
-          RenderBlock (anonymous) at (0,0) size 756x32
-            RenderText {#text} at (0,0) size 144x31
-              text run at (0,0) width 144: "one two three"
+      RenderBlock {DIV} at (0,0) size 784x90 [border: (2px solid #FF0000)]
+        RenderBlock {FRIJOLE} at (14,14) size 756x62
+          RenderBlock (anonymous) at (0,0) size 756x31
+            RenderText {#text} at (0,0) size 139x32
+              text run at (0,0) width 139: "one two three"
             RenderInline {FRIJOLE} at (0,0) size 0x0
               RenderText {#text} at (0,0) size 0x0
-          RenderBlock (anonymous) at (0,32) size 756x32
-            RenderBlock {DOODAD} at (0,0) size 756x32
-              RenderText {#text} at (0,0) size 121x31
-                text run at (0,0) width 121: "four five six"
-          RenderBlock (anonymous) at (0,64) size 756x0
+          RenderBlock (anonymous) at (0,31) size 756x31
+            RenderBlock {DOODAD} at (0,0) size 756x31
+              RenderText {#text} at (0,0) size 122x32
+                text run at (0,0) width 122: "four five six"
+          RenderBlock (anonymous) at (0,62) size 756x0
             RenderInline {FRIJOLE} at (0,0) size 0x0
 selection start: position 0 of child 0 {#text} of child 1 {DOODAD} of child 1 {FRIJOLE} of child 1 {FRIJOLE} of child 1 {DIV} of body
 selection end:   position 13 of child 0 {#text} of child 1 {DOODAD} of child 1 {FRIJOLE} of child 1 {FRIJOLE} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-sentence-002-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-by-sentence-002-expected.checksum
new file mode 100644
index 0000000..9cee133
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-by-sentence-002-expected.checksum
@@ -0,0 +1 @@
+c8b85eceff5b3b573db0ea4eba5d07bc
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-sentence-002-expected.png b/LayoutTests/platform/qt/editing/selection/extend-by-sentence-002-expected.png
new file mode 100644
index 0000000..2800c85
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-by-sentence-002-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-word-001-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-by-word-001-expected.checksum
new file mode 100644
index 0000000..e8a4e1a
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-by-word-001-expected.checksum
@@ -0,0 +1 @@
+b69c29bef0c86c6394e838b1f2511605
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-word-001-expected.png b/LayoutTests/platform/qt/editing/selection/extend-by-word-001-expected.png
new file mode 100644
index 0000000..a73940e
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-by-word-001-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-word-001-expected.txt b/LayoutTests/platform/qt/editing/selection/extend-by-word-001-expected.txt
index 0ab6436..4b2d3c7 100644
--- a/LayoutTests/platform/qt/editing/selection/extend-by-word-001-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/extend-by-word-001-expected.txt
@@ -11,14 +11,14 @@ layer 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 (0,0) size 784x60 [border: (2px solid #FF0000)]
-        RenderBlock {DIV} at (14,14) size 756x32
-          RenderText {#text} at (0,0) size 33x31
-            text run at (0,0) width 33: "foo"
-          RenderInline {SPAN} at (0,0) size 7x31
-            RenderText {#text} at (33,0) size 7x31
-              text run at (33,0) width 7: "\x{9}"
-          RenderText {#text} at (40,0) size 34x31
-            text run at (40,0) width 34: "bar"
+      RenderBlock {DIV} at (0,0) size 784x59 [border: (2px solid #FF0000)]
+        RenderBlock {DIV} at (14,14) size 756x31
+          RenderText {#text} at (0,0) size 32x32
+            text run at (0,0) width 32: "foo"
+          RenderInline {SPAN} at (0,0) size 6x32
+            RenderText {#text} at (32,0) size 6x32
+              text run at (32,0) width 6: "\x{9}"
+          RenderText {#text} at (38,0) size 36x32
+            text run at (38,0) width 36: "bar"
 selection start: position 0 of child 2 {#text} of child 1 {DIV} of child 1 {DIV} of body
 selection end:   position 3 of child 2 {#text} of child 1 {DIV} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-word-002-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-by-word-002-expected.checksum
new file mode 100644
index 0000000..8788386
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-by-word-002-expected.checksum
@@ -0,0 +1 @@
+fae9c7332a10d03c3e8ca9f2d7e52ec4
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-word-002-expected.png b/LayoutTests/platform/qt/editing/selection/extend-by-word-002-expected.png
new file mode 100644
index 0000000..38e56d8
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-by-word-002-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-by-word-002-expected.txt b/LayoutTests/platform/qt/editing/selection/extend-by-word-002-expected.txt
index f4e9567..cafc96f 100644
--- a/LayoutTests/platform/qt/editing/selection/extend-by-word-002-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/extend-by-word-002-expected.txt
@@ -12,62 +12,63 @@ layer 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 (0,0) size 148x174 [border: (2px solid #FF0000)]
-        RenderBlock {UL} at (14,14) size 120x146
-          RenderListItem {LI} at (0,0) size 120x22
-            RenderListMarker at (-14,5) size 5x14: bullet
-            RenderInline (generated) at (0,0) size 12x27
-              RenderText {#text} at (5,-5) size 12x27
-                text run at (5,-5) width 12: "\x{B7} "
+      RenderBlock {DIV} at (0,0) size 148x166 [border: (2px solid #FF0000)]
+        RenderBlock {UL} at (14,14) size 120x138
+          RenderListItem {LI} at (0,0) size 120x21
+            RenderListMarker at (-14,6) size 5x12: bullet
+            RenderInline (generated) at (0,0) size 12x25
+              RenderText {#text} at (5,-4) size 12x25
+                text run at (5,-4) width 12: "\x{B7} "
             RenderText {#text} at (0,0) size 0x0
-            RenderInline {A} at (0,0) size 49x14 [color=#0000EE]
-              RenderText {#text} at (17,5) size 49x14
-                text run at (17,5) width 49: "Appetizers"
-          RenderListItem {LI} at (0,22) size 120x22
-            RenderListMarker at (-14,5) size 5x14: bullet
-            RenderInline (generated) at (0,0) size 12x27
-              RenderText {#text} at (5,-5) size 12x27
-                text run at (5,-5) width 12: "\x{B7} "
+            RenderInline {A} at (0,0) size 49x12 [color=#0000EE]
+              RenderText {#text} at (17,6) size 49x12
+                text run at (17,6) width 49: "Appetizers"
+          RenderListItem {LI} at (0,21) size 120x21
+            RenderListMarker at (-14,6) size 5x12: bullet
+            RenderInline (generated) at (0,0) size 12x25
+              RenderText {#text} at (5,-4) size 12x25
+                text run at (5,-4) width 12: "\x{B7} "
             RenderText {#text} at (0,0) size 0x0
-            RenderInline {A} at (0,0) size 75x14 [color=#0000EE]
-              RenderText {#text} at (17,5) size 75x14
-                text run at (17,5) width 75: "Soups & Salads"
-          RenderListItem {LI} at (0,44) size 120x36
-            RenderListMarker at (-14,5) size 5x14: bullet
-            RenderInline (generated) at (0,0) size 12x27
-              RenderText {#text} at (5,-5) size 12x27
-                text run at (5,-5) width 12: "\x{B7} "
+            RenderInline {A} at (0,0) size 75x12 [color=#0000EE]
+              RenderText {#text} at (17,6) size 75x12
+                text run at (17,6) width 75: "Soups & Salads"
+          RenderListItem {LI} at (0,42) size 120x33
+            RenderListMarker at (-14,6) size 5x12: bullet
+            RenderInline (generated) at (0,0) size 12x25
+              RenderText {#text} at (5,-4) size 12x25
+                text run at (5,-4) width 12: "\x{B7} "
             RenderText {#text} at (0,0) size 0x0
-            RenderInline {A} at (0,0) size 70x28 [color=#0000EE]
-              RenderText {#text} at (17,5) size 70x28
-                text run at (17,5) width 69: "Sandwiches & "
-                text run at (16,19) width 36: "Burgers"
-          RenderListItem {LI} at (0,80) size 120x22
-            RenderListMarker at (-14,5) size 5x14: bullet
-            RenderInline (generated) at (0,0) size 12x27
-              RenderText {#text} at (5,-5) size 12x27
-                text run at (5,-5) width 12: "\x{B7} "
+            RenderInline {A} at (0,0) size 70x24 [color=#0000EE]
+              RenderText {#text} at (17,6) size 70x24
+                text run at (17,6) width 66: "Sandwiches &"
+                text run at (83,6) width 3: " "
+                text run at (16,18) width 36: "Burgers"
+          RenderListItem {LI} at (0,75) size 120x21
+            RenderListMarker at (-14,6) size 5x12: bullet
+            RenderInline (generated) at (0,0) size 12x25
+              RenderText {#text} at (5,-4) size 12x25
+                text run at (5,-4) width 12: "\x{B7} "
             RenderText {#text} at (0,0) size 0x0
-            RenderInline {A} at (0,0) size 60x14 [color=#0000EE]
-              RenderText {#text} at (17,5) size 60x14
-                text run at (17,5) width 60: "Steak & Ribs"
-          RenderListItem {LI} at (0,102) size 120x22
-            RenderListMarker at (-14,5) size 5x14: bullet
-            RenderInline (generated) at (0,0) size 12x27
-              RenderText {#text} at (5,-5) size 12x27
-                text run at (5,-5) width 12: "\x{B7} "
+            RenderInline {A} at (0,0) size 60x12 [color=#0000EE]
+              RenderText {#text} at (17,6) size 60x12
+                text run at (17,6) width 60: "Steak & Ribs"
+          RenderListItem {LI} at (0,96) size 120x21
+            RenderListMarker at (-14,6) size 5x12: bullet
+            RenderInline (generated) at (0,0) size 12x25
+              RenderText {#text} at (5,-4) size 12x25
+                text run at (5,-4) width 12: "\x{B7} "
             RenderText {#text} at (0,0) size 0x0
-            RenderInline {A} at (0,0) size 40x14 [color=#0000EE]
-              RenderText {#text} at (17,5) size 40x14
-                text run at (17,5) width 40: "Seafood"
-          RenderListItem {LI} at (0,124) size 120x22
-            RenderListMarker at (-14,5) size 5x14: bullet
-            RenderInline (generated) at (0,0) size 12x27
-              RenderText {#text} at (5,-5) size 12x27
-                text run at (5,-5) width 12: "\x{B7} "
+            RenderInline {A} at (0,0) size 40x12 [color=#0000EE]
+              RenderText {#text} at (17,6) size 40x12
+                text run at (17,6) width 40: "Seafood"
+          RenderListItem {LI} at (0,117) size 120x21
+            RenderListMarker at (-14,6) size 5x12: bullet
+            RenderInline (generated) at (0,0) size 12x25
+              RenderText {#text} at (5,-4) size 12x25
+                text run at (5,-4) width 12: "\x{B7} "
             RenderText {#text} at (0,0) size 0x0
-            RenderInline {A} at (0,0) size 38x14 [color=#0000EE]
-              RenderText {#text} at (17,5) size 38x14
-                text run at (17,5) width 38: "Combos"
+            RenderInline {A} at (0,0) size 38x12 [color=#0000EE]
+              RenderText {#text} at (17,6) size 38x12
+                text run at (17,6) width 38: "Combos"
 selection start: position 0 of child 0 {#text} of child 1 {A} of child 1 {LI} of child 1 {UL} of child 1 {DIV} of body
 selection end:   position 5 of child 0 {#text} of child 1 {A} of child 7 {LI} of child 1 {UL} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/extend-byline-withfloat-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-byline-withfloat-expected.checksum
new file mode 100644
index 0000000..2e93e46
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-byline-withfloat-expected.checksum
@@ -0,0 +1 @@
+d356d9e212f9ef394f4c242b356ccf4a
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-byline-withfloat-expected.png b/LayoutTests/platform/qt/editing/selection/extend-byline-withfloat-expected.png
new file mode 100644
index 0000000..943ce53
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-byline-withfloat-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-expected.checksum
new file mode 100644
index 0000000..04fde4e
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-expected.checksum
@@ -0,0 +1 @@
+733d3e128fe95ebc02c9ae6eda87b111
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-expected.png b/LayoutTests/platform/qt/editing/selection/extend-expected.png
new file mode 100644
index 0000000..9cc5ed5
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-forward-after-set-base-and-extent-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-forward-after-set-base-and-extent-expected.checksum
new file mode 100644
index 0000000..504d517
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-forward-after-set-base-and-extent-expected.checksum
@@ -0,0 +1 @@
+18b228d422b47a74fc2bb281aef08221
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-forward-after-set-base-and-extent-expected.png b/LayoutTests/platform/qt/editing/selection/extend-forward-after-set-base-and-extent-expected.png
new file mode 100644
index 0000000..e044939
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-forward-after-set-base-and-extent-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-selection-character-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-selection-character-expected.checksum
new file mode 100644
index 0000000..ed3c185
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-selection-character-expected.checksum
@@ -0,0 +1 @@
+1fc66e69eb983ff7954a09be6d7e2520
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-selection-character-expected.png b/LayoutTests/platform/qt/editing/selection/extend-selection-character-expected.png
new file mode 100644
index 0000000..8e4578f
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-selection-character-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-selection-enclosing-block-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-selection-enclosing-block-expected.checksum
new file mode 100644
index 0000000..bfb8c28
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-selection-enclosing-block-expected.checksum
@@ -0,0 +1 @@
+5c40d0a33362f59f50acb5ad7f54dfcc
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-selection-enclosing-block-expected.png b/LayoutTests/platform/qt/editing/selection/extend-selection-enclosing-block-expected.png
new file mode 100644
index 0000000..83bf6dc
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-selection-enclosing-block-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-selection-home-end-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-selection-home-end-expected.checksum
new file mode 100644
index 0000000..7e31b7e
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-selection-home-end-expected.checksum
@@ -0,0 +1 @@
+d36bf1ab4010fee7a6ff7193f665e8aa
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-selection-home-end-expected.png b/LayoutTests/platform/qt/editing/selection/extend-selection-home-end-expected.png
new file mode 100644
index 0000000..deed242
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-selection-home-end-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-selection-word-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-selection-word-expected.checksum
new file mode 100644
index 0000000..b51884c
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-selection-word-expected.checksum
@@ -0,0 +1 @@
+c05bfdce638dfead2a20ee46e5672e67
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-selection-word-expected.png b/LayoutTests/platform/qt/editing/selection/extend-selection-word-expected.png
new file mode 100644
index 0000000..afd5236
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-selection-word-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/extend-to-line-boundary-expected.checksum b/LayoutTests/platform/qt/editing/selection/extend-to-line-boundary-expected.checksum
new file mode 100644
index 0000000..86eb944
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/extend-to-line-boundary-expected.checksum
@@ -0,0 +1 @@
+95544f8e782dcec0c17d6df1c524875d
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/extend-to-line-boundary-expected.png b/LayoutTests/platform/qt/editing/selection/extend-to-line-boundary-expected.png
new file mode 100644
index 0000000..182d300
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/extend-to-line-boundary-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/fake-doubleclick-expected.checksum b/LayoutTests/platform/qt/editing/selection/fake-doubleclick-expected.checksum
new file mode 100644
index 0000000..4e3ad30
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/fake-doubleclick-expected.checksum
@@ -0,0 +1 @@
+ae9bb1ad897b84203f4b2573fc498033
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/fake-doubleclick-expected.png b/LayoutTests/platform/qt/editing/selection/fake-doubleclick-expected.png
new file mode 100644
index 0000000..3290c50
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/fake-doubleclick-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/fake-doubleclick-expected.txt b/LayoutTests/platform/qt/editing/selection/fake-doubleclick-expected.txt
new file mode 100644
index 0000000..a9861a9
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/fake-doubleclick-expected.txt
@@ -0,0 +1,16 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 1 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 1 of #text > DIV > BODY > HTML > #document to 1 of #text > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 1 of #text > DIV > BODY > HTML > #document to 1 of #text > DIV > BODY > HTML > #document toDOMRange:range from 0 of #text > DIV > BODY > HTML > #document to 6 of #text > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+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 (0,0) size 800x600
+      RenderBlock {DIV} at (0,0) size 800x21
+        RenderText {#text} at (0,0) size 199x21
+          text run at (0,0) width 199: "Select me, select me, select me"
+selection start: position 0 of child 0 {#text} of child 1 {DIV} of body
+selection end:   position 6 of child 0 {#text} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/find-in-text-control-expected.checksum b/LayoutTests/platform/qt/editing/selection/find-in-text-control-expected.checksum
new file mode 100644
index 0000000..a0f92e9
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/find-in-text-control-expected.checksum
@@ -0,0 +1 @@
+5b9a4d5574298c392f7ac655b30bea4f
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/find-in-text-control-expected.png b/LayoutTests/platform/qt/editing/selection/find-in-text-control-expected.png
new file mode 100644
index 0000000..6408fa5
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/find-in-text-control-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-expected.checksum b/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-expected.checksum
new file mode 100644
index 0000000..790f347
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-expected.checksum
@@ -0,0 +1 @@
+f61c5da4c0b9bd7e6d2c19d3ecd0aca2
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-expected.png b/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-expected.png
new file mode 100644
index 0000000..55c7b47
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-with-japanese-fonts-expected.checksum b/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-with-japanese-fonts-expected.checksum
new file mode 100644
index 0000000..ccc07d4
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-with-japanese-fonts-expected.checksum
@@ -0,0 +1 @@
+e3819a1a0faaa1de30cd91550052eced
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-with-japanese-fonts-expected.png b/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-with-japanese-fonts-expected.png
new file mode 100644
index 0000000..6b5ae1e
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/find-yensign-and-backslash-with-japanese-fonts-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/firstRect-crash-expected.checksum b/LayoutTests/platform/qt/editing/selection/firstRect-crash-expected.checksum
new file mode 100644
index 0000000..bf0e456
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/firstRect-crash-expected.checksum
@@ -0,0 +1 @@
+9e6b78317015ae0240395767c916e423
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/firstRect-crash-expected.png b/LayoutTests/platform/qt/editing/selection/firstRect-crash-expected.png
new file mode 100644
index 0000000..4f91ee7
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/firstRect-crash-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/focus-and-display-none-expected.checksum b/LayoutTests/platform/qt/editing/selection/focus-and-display-none-expected.checksum
new file mode 100644
index 0000000..cac49dd
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/focus-and-display-none-expected.checksum
@@ -0,0 +1 @@
+eb742b02f99efe36e2a451a0f9c2da73
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/focus-and-display-none-expected.png b/LayoutTests/platform/qt/editing/selection/focus-and-display-none-expected.png
new file mode 100644
index 0000000..c3e80c3
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/focus-and-display-none-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/focus-body-expected.checksum b/LayoutTests/platform/qt/editing/selection/focus-body-expected.checksum
new file mode 100644
index 0000000..dd78b61
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/focus-body-expected.checksum
@@ -0,0 +1 @@
+6db9ccd481f8d0281413fa584e179c62
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/focus-body-expected.png b/LayoutTests/platform/qt/editing/selection/focus-body-expected.png
new file mode 100644
index 0000000..ec0c620
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/focus-body-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/focus-body-expected.txt b/LayoutTests/platform/qt/editing/selection/focus-body-expected.txt
index 5b743ca..2989c19 100644
--- a/LayoutTests/platform/qt/editing/selection/focus-body-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/focus-body-expected.txt
@@ -7,8 +7,8 @@ layer 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
-      RenderText {#text} at (0,0) size 448x19
-        text run at (0,0) width 224: "This test focuses an editable body. "
-        text run at (224,0) width 224: "Its contents should not be selected."
+      RenderText {#text} at (0,0) size 465x21
+        text run at (0,0) width 233: "This test focuses an editable body. "
+        text run at (233,0) width 232: "Its contents should not be selected."
       RenderText {#text} at (0,0) size 0x0
 caret: position 0 of child 0 {#text} of body
diff --git a/LayoutTests/platform/qt/editing/selection/focus-contenteditable-iframe-expected.checksum b/LayoutTests/platform/qt/editing/selection/focus-contenteditable-iframe-expected.checksum
new file mode 100644
index 0000000..d9b8bb9
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/focus-contenteditable-iframe-expected.checksum
@@ -0,0 +1 @@
+4048491b18694184c67625a5b363eaa6
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/focus-contenteditable-iframe-expected.png b/LayoutTests/platform/qt/editing/selection/focus-contenteditable-iframe-expected.png
new file mode 100644
index 0000000..d8f648a
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/focus-contenteditable-iframe-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/focus-crash-expected.checksum b/LayoutTests/platform/qt/editing/selection/focus-crash-expected.checksum
new file mode 100644
index 0000000..dc5a97b
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/focus-crash-expected.checksum
@@ -0,0 +1 @@
+ac9925a91f91953653115c936416432d
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/focus-crash-expected.png b/LayoutTests/platform/qt/editing/selection/focus-crash-expected.png
new file mode 100644
index 0000000..47bbfb4
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/focus-crash-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/focus_editable_html-expected.checksum b/LayoutTests/platform/qt/editing/selection/focus_editable_html-expected.checksum
new file mode 100644
index 0000000..47b9aff
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/focus_editable_html-expected.checksum
@@ -0,0 +1 @@
+9298be3778ea91664661d140da57f047
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/focus_editable_html-expected.png b/LayoutTests/platform/qt/editing/selection/focus_editable_html-expected.png
new file mode 100644
index 0000000..3660e02
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/focus_editable_html-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/focus_editable_html-expected.txt b/LayoutTests/platform/qt/editing/selection/focus_editable_html-expected.txt
index 0555766..10081dd 100644
--- a/LayoutTests/platform/qt/editing/selection/focus_editable_html-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/focus_editable_html-expected.txt
@@ -6,25 +6,24 @@ EDITING DELEGATE: webViewDidEndEditing:WebViewDidEndEditingNotification
 EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of BODY > HTML > #document to 9 of BODY > HTML > #document
 EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
-layer at (0,0) size 2008x2093
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 2008x2093
-  RenderBlock {HTML} at (0,0) size 800x2093
-    RenderBody {BODY} at (8,8) size 784x2077
-      RenderBlock (anonymous) at (0,0) size 784x58
-        RenderText {#text} at (0,0) size 585x19
-          text run at (0,0) width 585: "This test makes sure that we don't scroll unnecessarily to reveal an editable HTML Element. "
-        RenderBR {BR} at (585,14) size 0x0
-        RenderText {#text} at (0,19) size 270x19
-          text run at (0,19) width 270: "If the document doesn't scroll, test passes."
-        RenderBR {BR} at (270,33) size 0x0
-        RenderInline {B} at (0,0) size 549x20
-          RenderText {#text} at (0,38) size 549x20
-            text run at (0,38) width 549: "This demonstrates a bug: normally, focusing an element will select its contents."
-        RenderText {#text} at (0,0) size 0x0
-      RenderBlock {DIV} at (0,58) size 2000x2000
-      RenderBlock (anonymous) at (0,2058) size 784x19
-        RenderText {#text} at (0,0) size 240x19
-          text run at (0,0) width 240: "If the document scrolls here, test fails."
+layer at (0,0) size 2008x2100
+  RenderView at (0,0) size 784x584
+layer at (0,0) size 784x2100
+  RenderBlock {HTML} at (0,0) size 784x2100
+    RenderBody {BODY} at (8,8) size 768x2084
+      RenderBlock (anonymous) at (0,0) size 768x63
+        RenderText {#text} at (0,0) size 626x21
+          text run at (0,0) width 626: "This test makes sure that we don't scroll unnecessarily to reveal an editable HTML Element. "
+        RenderBR {BR} at (626,16) size 0x0
+        RenderText {#text} at (0,21) size 280x21
+          text run at (0,21) width 280: "If the document doesn't scroll, test passes."
+        RenderBR {BR} at (280,37) size 0x0
+        RenderInline {B} at (0,0) size 528x21
+          RenderText {#text} at (0,42) size 528x21
+            text run at (0,42) width 528: "This demonstrates a bug: normally, focusing an element will select its contents."
         RenderText {#text} at (0,0) size 0x0
+      RenderBlock {DIV} at (0,63) size 2000x2000
+      RenderBlock (anonymous) at (0,2063) size 768x21
+        RenderText {#text} at (0,0) size 253x21
+          text run at (0,0) width 253: "If the document scrolls here, test fails."
 caret: position 1 of child 0 {#text} of body
diff --git a/LayoutTests/platform/qt/editing/selection/getRangeAt-expected.checksum b/LayoutTests/platform/qt/editing/selection/getRangeAt-expected.checksum
new file mode 100644
index 0000000..0648e8c
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/getRangeAt-expected.checksum
@@ -0,0 +1 @@
+5e01f8ebd136f6bd606c1f46e0d7fc47
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/getRangeAt-expected.png b/LayoutTests/platform/qt/editing/selection/getRangeAt-expected.png
new file mode 100644
index 0000000..1314649
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/getRangeAt-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/home-end-expected.checksum b/LayoutTests/platform/qt/editing/selection/home-end-expected.checksum
new file mode 100644
index 0000000..2c530ba
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/home-end-expected.checksum
@@ -0,0 +1 @@
+ff9e8d9365ba492eb568459b91c559b3
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/home-end-expected.png b/LayoutTests/platform/qt/editing/selection/home-end-expected.png
new file mode 100644
index 0000000..5435a06
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/home-end-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/home-inside-noneditable-table-expected.checksum b/LayoutTests/platform/qt/editing/selection/home-inside-noneditable-table-expected.checksum
new file mode 100644
index 0000000..1c5e840
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/home-inside-noneditable-table-expected.checksum
@@ -0,0 +1 @@
+bdd31e0c9ba9fb4de147d6c437548c78
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/home-inside-noneditable-table-expected.png b/LayoutTests/platform/qt/editing/selection/home-inside-noneditable-table-expected.png
new file mode 100644
index 0000000..d187f7c
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/home-inside-noneditable-table-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/iframe-expected.checksum b/LayoutTests/platform/qt/editing/selection/iframe-expected.checksum
new file mode 100644
index 0000000..d070801
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/iframe-expected.checksum
@@ -0,0 +1 @@
+67abbd1b717f08e1978b82363614d056
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/iframe-expected.png b/LayoutTests/platform/qt/editing/selection/iframe-expected.png
new file mode 100644
index 0000000..67b8079
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/iframe-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/inactive-selection-expected.checksum b/LayoutTests/platform/qt/editing/selection/inactive-selection-expected.checksum
new file mode 100644
index 0000000..5296df0
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/inactive-selection-expected.checksum
@@ -0,0 +1 @@
+f23a6c4284cb82c7fe752ab5f231a478
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/inactive-selection-expected.png b/LayoutTests/platform/qt/editing/selection/inactive-selection-expected.png
new file mode 100644
index 0000000..ba6af4c
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/inactive-selection-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/inline-table-expected.checksum b/LayoutTests/platform/qt/editing/selection/inline-table-expected.checksum
new file mode 100644
index 0000000..759ce8c
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/inline-table-expected.checksum
@@ -0,0 +1 @@
+9bf6e83ff8dd41909d0798f020990435
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/inline-table-expected.png b/LayoutTests/platform/qt/editing/selection/inline-table-expected.png
new file mode 100644
index 0000000..b062002
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/inline-table-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/inline-table-expected.txt b/LayoutTests/platform/qt/editing/selection/inline-table-expected.txt
index d153cd9..571432c 100644
--- a/LayoutTests/platform/qt/editing/selection/inline-table-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/inline-table-expected.txt
@@ -144,49 +144,49 @@ layer 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 {P} at (0,0) size 784x57
-        RenderText {#text} at (0,0) size 775x57
-          text run at (0,0) width 321: "This tests caret movement through an inline table. "
-          text run at (321,0) width 451: "There should be visual positions before and after the inline table, as if it"
-          text run at (0,19) width 102: "were an image. "
-          text run at (102,19) width 673: "The caret shouldn't skip across the table, but should enter it (unless we later decide that we don't want this"
-          text run at (0,38) width 64: "behavior)."
-      RenderBlock {DIV} at (0,71) size 784x84
-        RenderBlock {DIV} at (0,0) size 784x84
-          RenderText {#text} at (0,65) size 78x19
-            text run at (0,65) width 78: "Inline Table:"
-          RenderTable {TABLE} at (78,0) size 132x79 [border: (1px outset #808080)]
-            RenderTableSection {TBODY} at (1,1) size 130x77
-              RenderTableRow {TR} at (0,2) size 130x23
-                RenderTableCell {TD} at (2,2) size 44x23 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
-                  RenderText {#text} at (2,2) size 27x19
-                    text run at (2,2) width 27: "One"
-                RenderTableCell {TD} at (48,2) size 36x23 [border: (1px inset #808080)] [r=0 c=1 rs=1 cs=1]
-                  RenderText {#text} at (2,2) size 27x19
-                    text run at (2,2) width 27: "Two"
-                RenderTableCell {TD} at (86,2) size 42x23 [border: (1px inset #808080)] [r=0 c=2 rs=1 cs=1]
-                  RenderText {#text} at (2,2) size 38x19
-                    text run at (2,2) width 38: "Three"
-              RenderTableRow {TR} at (0,27) size 130x23
-                RenderTableCell {TD} at (2,27) size 44x23 [border: (1px inset #808080)] [r=1 c=0 rs=1 cs=1]
-                  RenderText {#text} at (2,2) size 30x19
-                    text run at (2,2) width 30: "Four"
-                RenderTableCell {TD} at (48,27) size 36x23 [border: (1px inset #808080)] [r=1 c=1 rs=1 cs=1]
-                  RenderText {#text} at (2,2) size 27x19
-                    text run at (2,2) width 27: "Five"
-                RenderTableCell {TD} at (86,27) size 42x23 [border: (1px inset #808080)] [r=1 c=2 rs=1 cs=1]
-                  RenderText {#text} at (2,2) size 19x19
-                    text run at (2,2) width 19: "Six"
-              RenderTableRow {TR} at (0,52) size 130x23
-                RenderTableCell {TD} at (2,52) size 44x23 [border: (1px inset #808080)] [r=2 c=0 rs=1 cs=1]
-                  RenderText {#text} at (2,2) size 40x19
+      RenderBlock {P} at (0,0) size 784x63
+        RenderText {#text} at (0,0) size 777x63
+          text run at (0,0) width 341: "This tests caret movement through an inline table. "
+          text run at (341,0) width 436: "There should be visual positions before and after the inline table,"
+          text run at (0,21) width 150: "as if it were an image. "
+          text run at (150,21) width 613: "The caret shouldn't skip across the table, but should enter it (unless we later decide that we"
+          text run at (0,42) width 174: "don't want this behavior)."
+      RenderBlock {DIV} at (0,79) size 784x90
+        RenderBlock {DIV} at (0,0) size 784x90
+          RenderText {#text} at (0,69) size 87x21
+            text run at (0,69) width 87: "Inline Table:"
+          RenderTable {TABLE} at (87,0) size 140x85 [border: (1px outset #808080)]
+            RenderTableSection {TBODY} at (1,1) size 138x83
+              RenderTableRow {TR} at (0,2) size 138x25
+                RenderTableCell {TD} at (2,2) size 44x25 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
+                  RenderText {#text} at (2,2) size 28x21
+                    text run at (2,2) width 28: "One"
+                RenderTableCell {TD} at (48,2) size 41x25 [border: (1px inset #808080)] [r=0 c=1 rs=1 cs=1]
+                  RenderText {#text} at (2,2) size 31x21
+                    text run at (2,2) width 31: "Two"
+                RenderTableCell {TD} at (91,2) size 45x25 [border: (1px inset #808080)] [r=0 c=2 rs=1 cs=1]
+                  RenderText {#text} at (2,2) size 41x21
+                    text run at (2,2) width 41: "Three"
+              RenderTableRow {TR} at (0,29) size 138x25
+                RenderTableCell {TD} at (2,29) size 44x25 [border: (1px inset #808080)] [r=1 c=0 rs=1 cs=1]
+                  RenderText {#text} at (2,2) size 34x21
+                    text run at (2,2) width 34: "Four"
+                RenderTableCell {TD} at (48,29) size 41x25 [border: (1px inset #808080)] [r=1 c=1 rs=1 cs=1]
+                  RenderText {#text} at (2,2) size 29x21
+                    text run at (2,2) width 29: "Five"
+                RenderTableCell {TD} at (91,29) size 45x25 [border: (1px inset #808080)] [r=1 c=2 rs=1 cs=1]
+                  RenderText {#text} at (2,2) size 21x21
+                    text run at (2,2) width 21: "Six"
+              RenderTableRow {TR} at (0,56) size 138x25
+                RenderTableCell {TD} at (2,56) size 44x25 [border: (1px inset #808080)] [r=2 c=0 rs=1 cs=1]
+                  RenderText {#text} at (2,2) size 40x21
                     text run at (2,2) width 40: "Seven"
-                RenderTableCell {TD} at (48,52) size 36x23 [border: (1px inset #808080)] [r=2 c=1 rs=1 cs=1]
-                  RenderText {#text} at (2,2) size 32x19
-                    text run at (2,2) width 32: "Eight"
-                RenderTableCell {TD} at (86,52) size 42x23 [border: (1px inset #808080)] [r=2 c=2 rs=1 cs=1]
-                  RenderText {#text} at (2,2) size 29x19
-                    text run at (2,2) width 29: "Nine"
-          RenderText {#text} at (210,65) size 66x19
-            text run at (210,65) width 66: "The End..."
+                RenderTableCell {TD} at (48,56) size 41x25 [border: (1px inset #808080)] [r=2 c=1 rs=1 cs=1]
+                  RenderText {#text} at (2,2) size 37x21
+                    text run at (2,2) width 37: "Eight"
+                RenderTableCell {TD} at (91,56) size 45x25 [border: (1px inset #808080)] [r=2 c=2 rs=1 cs=1]
+                  RenderText {#text} at (2,2) size 32x21
+                    text run at (2,2) width 32: "Nine"
+          RenderText {#text} at (227,69) size 72x21
+            text run at (227,69) width 72: "The End..."
 caret: position 1 of child 0 {#text} of child 1 {DIV} of child 3 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/last-empty-inline-expected.checksum b/LayoutTests/platform/qt/editing/selection/last-empty-inline-expected.checksum
new file mode 100644
index 0000000..3761d5a
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/last-empty-inline-expected.checksum
@@ -0,0 +1 @@
+e9f3b489fb12b01f9a9af80f7ac336b1
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/last-empty-inline-expected.png b/LayoutTests/platform/qt/editing/selection/last-empty-inline-expected.png
new file mode 100644
index 0000000..df4c2c7
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/last-empty-inline-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/leave-requested-block-expected.checksum b/LayoutTests/platform/qt/editing/selection/leave-requested-block-expected.checksum
new file mode 100644
index 0000000..6305e18
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/leave-requested-block-expected.checksum
@@ -0,0 +1 @@
+cfc245ea633348afb9f1830ee8f1f4f7
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/leave-requested-block-expected.png b/LayoutTests/platform/qt/editing/selection/leave-requested-block-expected.png
new file mode 100644
index 0000000..a4d9fed
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/leave-requested-block-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/leave-requested-block-expected.txt b/LayoutTests/platform/qt/editing/selection/leave-requested-block-expected.txt
index 70bcdcb..96a9d8b 100644
--- a/LayoutTests/platform/qt/editing/selection/leave-requested-block-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/leave-requested-block-expected.txt
@@ -6,27 +6,27 @@ 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 784x578
-      RenderBlock {P} at (0,0) size 784x19
-        RenderText {#text} at (0,0) size 126x19
-          text run at (0,0) width 126: "Test case for fix for "
-        RenderInline {A} at (0,0) size 337x19 [color=#0000EE]
-          RenderText {#text} at (126,0) size 337x19
-            text run at (126,0) width 337: "http://bugzilla.opendarwin.org/show_bug.cgi?id=5354"
-        RenderText {#text} at (463,0) size 4x19
-          text run at (463,0) width 4: "."
-      RenderBlock {P} at (0,33) size 784x38
-        RenderText {#text} at (0,0) size 774x38
-          text run at (0,0) width 774: "Changes were made to VisiblePosition's so that init() will not leave the block containing the requested position unless there"
-          text run at (0,19) width 227: "are no VisiblePositions in that block."
-      RenderBlock {P} at (0,85) size 784x0
-      RenderBlock {DIV} at (0,85) size 784x51 [border: (2px solid #AAAAFF)]
-        RenderBlock {P} at (2,16) size 780x19
-          RenderText {#text} at (0,0) size 681x19
-            text run at (0,0) width 681: "Select All while inside this editable block should create a selection that does not extend outside of this block."
-layer at (8,158) size 784x19
-  RenderBlock {P} at (0,150) size 784x19
-    RenderText {#text} at (0,0) size 421x19
-      text run at (0,0) width 421: "This is a paragraph outside the editable block with overflow:hidden"
+    RenderBody {BODY} at (8,8) size 784x576
+      RenderBlock {P} at (0,0) size 784x21
+        RenderText {#text} at (0,0) size 134x21
+          text run at (0,0) width 134: "Test case for fix for "
+        RenderInline {A} at (0,0) size 365x21 [color=#0000EE]
+          RenderText {#text} at (134,0) size 365x21
+            text run at (134,0) width 365: "http://bugzilla.opendarwin.org/show_bug.cgi?id=5354"
+        RenderText {#text} at (499,0) size 4x21
+          text run at (499,0) width 4: "."
+      RenderBlock {P} at (0,37) size 784x42
+        RenderText {#text} at (0,0) size 783x42
+          text run at (0,0) width 783: "Changes were made to VisiblePosition's so that init() will not leave the block containing the requested position unless"
+          text run at (0,21) width 285: "there are no VisiblePositions in that block."
+      RenderBlock {P} at (0,95) size 784x0
+      RenderBlock {DIV} at (0,95) size 784x57 [border: (2px solid #AAAAFF)]
+        RenderBlock {P} at (2,18) size 780x21
+          RenderText {#text} at (0,0) size 721x21
+            text run at (0,0) width 721: "Select All while inside this editable block should create a selection that does not extend outside of this block."
+layer at (8,176) size 784x21
+  RenderBlock {P} at (0,168) size 784x21
+    RenderText {#text} at (0,0) size 457x21
+      text run at (0,0) width 457: "This is a paragraph outside the editable block with overflow:hidden"
 selection start: position 0 of child 0 {#text} of child 1 {P} of child 5 {DIV} of body
 selection end:   position 113 of child 0 {#text} of child 1 {P} of child 5 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/legal-positions-expected.checksum b/LayoutTests/platform/qt/editing/selection/legal-positions-expected.checksum
new file mode 100644
index 0000000..4f2bcdf
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/legal-positions-expected.checksum
@@ -0,0 +1 @@
+031a3167c893d30c1c32d242d999039d
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/legal-positions-expected.png b/LayoutTests/platform/qt/editing/selection/legal-positions-expected.png
new file mode 100644
index 0000000..7e403c6
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/legal-positions-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/line-wrap-1-expected.checksum b/LayoutTests/platform/qt/editing/selection/line-wrap-1-expected.checksum
new file mode 100644
index 0000000..e470b2d
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/line-wrap-1-expected.checksum
@@ -0,0 +1 @@
+f5d4a7f4f552a1c313622b1ec72fa032
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/line-wrap-1-expected.png b/LayoutTests/platform/qt/editing/selection/line-wrap-1-expected.png
new file mode 100644
index 0000000..9d89e68
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/line-wrap-1-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/line-wrap-1-expected.txt b/LayoutTests/platform/qt/editing/selection/line-wrap-1-expected.txt
index ceef49d..7f2a8a7 100644
--- a/LayoutTests/platform/qt/editing/selection/line-wrap-1-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/line-wrap-1-expected.txt
@@ -4,12 +4,12 @@ layer 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 {P} at (0,0) size 784x19
-        RenderText {#text} at (0,0) size 187x19
-          text run at (0,0) width 187: "Only 'bar' should be selected."
-      RenderBlock {DIV} at (0,33) size 52x40 [border: (1px solid #000000)]
-        RenderText {#text} at (1,1) size 47x38
-          text run at (1,1) width 45: "foo bar"
-          text run at (1,20) width 47: "baz foo"
+      RenderBlock {P} at (0,0) size 784x21
+        RenderText {#text} at (0,0) size 198x21
+          text run at (0,0) width 198: "Only 'bar' should be selected."
+      RenderBlock {DIV} at (0,37) size 52x44 [border: (1px solid #000000)]
+        RenderText {#text} at (1,1) size 49x42
+          text run at (1,1) width 49: "foo bar"
+          text run at (1,22) width 49: "baz foo"
 selection start: position 4 of child 0 {#text} of child 2 {DIV} of body
 selection end:   position 7 of child 0 {#text} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/line-wrap-2-expected.checksum b/LayoutTests/platform/qt/editing/selection/line-wrap-2-expected.checksum
new file mode 100644
index 0000000..49db952
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/line-wrap-2-expected.checksum
@@ -0,0 +1 @@
+8b3312b6557ad56d20375eeb34b2d540
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/line-wrap-2-expected.png b/LayoutTests/platform/qt/editing/selection/line-wrap-2-expected.png
new file mode 100644
index 0000000..f7f9b65
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/line-wrap-2-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/line-wrap-2-expected.txt b/LayoutTests/platform/qt/editing/selection/line-wrap-2-expected.txt
index dd3efc0..13a9b52 100644
--- a/LayoutTests/platform/qt/editing/selection/line-wrap-2-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/line-wrap-2-expected.txt
@@ -4,14 +4,14 @@ layer 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 {P} at (0,0) size 784x19
-        RenderText {#text} at (0,0) size 230x19
-          text run at (0,0) width 230: "Only 'baz' should be selected below."
-      RenderBlock {DIV} at (50,33) size 52x40 [border: (1px solid #000000)]
-        RenderText {#text} at (1,1) size 45x19
-          text run at (1,1) width 45: "foo bar"
-        RenderInline {A} at (0,0) size 23x19 [color=#0000EE]
-          RenderText {#text} at (1,20) size 23x19
-            text run at (1,20) width 23: "baz"
+      RenderBlock {P} at (0,0) size 784x21
+        RenderText {#text} at (0,0) size 242x21
+          text run at (0,0) width 242: "Only 'baz' should be selected below."
+      RenderBlock {DIV} at (50,37) size 52x44 [border: (1px solid #000000)]
+        RenderText {#text} at (1,1) size 49x21
+          text run at (1,1) width 49: "foo bar"
+        RenderInline {A} at (0,0) size 24x21 [color=#0000EE]
+          RenderText {#text} at (1,22) size 24x21
+            text run at (1,22) width 24: "baz"
 selection start: position 0 of child 0 {#text} of child 1 {A} of child 2 {DIV} of body
 selection end:   position 3 of child 0 {#text} of child 1 {A} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-10-expected.checksum b/LayoutTests/platform/qt/editing/selection/mixed-editability-10-expected.checksum
new file mode 100644
index 0000000..e41983c
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-10-expected.checksum
@@ -0,0 +1 @@
+0916a244d06627d6b4a4025e1bb6ed97
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-10-expected.png b/LayoutTests/platform/qt/editing/selection/mixed-editability-10-expected.png
new file mode 100644
index 0000000..2bcd829
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/mixed-editability-10-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-11-expected.checksum b/LayoutTests/platform/qt/editing/selection/mixed-editability-11-expected.checksum
new file mode 100644
index 0000000..54c3561
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-11-expected.checksum
@@ -0,0 +1 @@
+f3f84088326ce3ab26516c7b09fb7cc0
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-11-expected.png b/LayoutTests/platform/qt/editing/selection/mixed-editability-11-expected.png
new file mode 100644
index 0000000..a889d51
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/mixed-editability-11-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-12-expected.checksum b/LayoutTests/platform/qt/editing/selection/mixed-editability-12-expected.checksum
new file mode 100644
index 0000000..f304b91
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-12-expected.checksum
@@ -0,0 +1 @@
+4edf46631180820b3842a1016873fb62
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-12-expected.png b/LayoutTests/platform/qt/editing/selection/mixed-editability-12-expected.png
new file mode 100644
index 0000000..bad41d0
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/mixed-editability-12-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-2-expected.checksum b/LayoutTests/platform/qt/editing/selection/mixed-editability-2-expected.checksum
new file mode 100644
index 0000000..c6ae207
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-2-expected.checksum
@@ -0,0 +1 @@
+b8b48a607a7ef5a8735aa01a0de7a5ee
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-2-expected.png b/LayoutTests/platform/qt/editing/selection/mixed-editability-2-expected.png
new file mode 100644
index 0000000..3ef1bba
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/mixed-editability-2-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-3-expected.checksum b/LayoutTests/platform/qt/editing/selection/mixed-editability-3-expected.checksum
new file mode 100644
index 0000000..26b6f92
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-3-expected.checksum
@@ -0,0 +1 @@
+e16f52abca57ce835d150896879204b6
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-3-expected.png b/LayoutTests/platform/qt/editing/selection/mixed-editability-3-expected.png
new file mode 100644
index 0000000..3e33ff7
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/mixed-editability-3-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-3-expected.txt b/LayoutTests/platform/qt/editing/selection/mixed-editability-3-expected.txt
index ba75a5c..ec11aca 100644
--- a/LayoutTests/platform/qt/editing/selection/mixed-editability-3-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-3-expected.txt
@@ -11,22 +11,22 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 751x38
-          text run at (0,0) width 456: "This tests moving the caret forward through content of mixed editability. "
-          text run at (456,0) width 295: "The caret should move down one line from the"
-          text run at (0,19) width 482: "editable piece to the editable piece that's embedded in a non-editable piece."
-      RenderBlock {DIV} at (0,52) size 784x67
-        RenderBlock (anonymous) at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 50x19
-            text run at (0,0) width 50: "editable"
-        RenderTable {TABLE} at (0,19) size 60x29 [border: (1px outset #808080)]
-          RenderTableSection {TBODY} at (1,1) size 58x27
-            RenderTableRow {TR} at (0,2) size 58x23
-              RenderTableCell {TD} at (2,2) size 54x23 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 50x19
-                  text run at (2,2) width 50: "editable"
-        RenderBlock (anonymous) at (0,48) size 784x19
-          RenderText {#text} at (0,0) size 50x19
-            text run at (0,0) width 50: "editable"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 783x42
+          text run at (0,0) width 494: "This tests moving the caret forward through content of mixed editability. "
+          text run at (494,0) width 289: "The caret should move down one line from"
+          text run at (0,21) width 527: "the editable piece to the editable piece that's embedded in a non-editable piece."
+      RenderBlock {DIV} at (0,58) size 784x73
+        RenderBlock (anonymous) at (0,0) size 784x21
+          RenderText {#text} at (0,0) size 53x21
+            text run at (0,0) width 53: "editable"
+        RenderTable {TABLE} at (0,21) size 63x31 [border: (1px outset #808080)]
+          RenderTableSection {TBODY} at (1,1) size 61x29
+            RenderTableRow {TR} at (0,2) size 61x25
+              RenderTableCell {TD} at (2,2) size 57x25 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 53x21
+                  text run at (2,2) width 53: "editable"
+        RenderBlock (anonymous) at (0,52) size 784x21
+          RenderText {#text} at (0,0) size 53x21
+            text run at (0,0) width 53: "editable"
 caret: position 0 of child 0 {#text} of child 0 {TD} of child 0 {TR} of child 0 {TBODY} of child 1 {TABLE} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-4-expected.checksum b/LayoutTests/platform/qt/editing/selection/mixed-editability-4-expected.checksum
new file mode 100644
index 0000000..a9cb1e8
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-4-expected.checksum
@@ -0,0 +1 @@
+928329ca9a79a2b25fec7f81b3cbdf88
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-4-expected.png b/LayoutTests/platform/qt/editing/selection/mixed-editability-4-expected.png
new file mode 100644
index 0000000..10e9a20
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/mixed-editability-4-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-4-expected.txt b/LayoutTests/platform/qt/editing/selection/mixed-editability-4-expected.txt
index d6e1cd6..d73f94e 100644
--- a/LayoutTests/platform/qt/editing/selection/mixed-editability-4-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-4-expected.txt
@@ -11,22 +11,22 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 751x38
-          text run at (0,0) width 456: "This tests moving the caret forward through content of mixed editability. "
-          text run at (456,0) width 295: "The caret should move down one line from the"
-          text run at (0,19) width 482: "editable piece to the editable piece that's embedded in a non-editable piece."
-      RenderBlock {DIV} at (0,52) size 784x67
-        RenderBlock (anonymous) at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 50x19
-            text run at (0,0) width 50: "editable"
-        RenderTable {TABLE} at (0,19) size 60x29 [border: (1px outset #808080)]
-          RenderTableSection {TBODY} at (1,1) size 58x27
-            RenderTableRow {TR} at (0,2) size 58x23
-              RenderTableCell {TD} at (2,2) size 54x23 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 50x19
-                  text run at (2,2) width 50: "editable"
-        RenderBlock (anonymous) at (0,48) size 784x19
-          RenderText {#text} at (0,0) size 50x19
-            text run at (0,0) width 50: "editable"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 783x42
+          text run at (0,0) width 494: "This tests moving the caret forward through content of mixed editability. "
+          text run at (494,0) width 289: "The caret should move down one line from"
+          text run at (0,21) width 527: "the editable piece to the editable piece that's embedded in a non-editable piece."
+      RenderBlock {DIV} at (0,58) size 784x73
+        RenderBlock (anonymous) at (0,0) size 784x21
+          RenderText {#text} at (0,0) size 53x21
+            text run at (0,0) width 53: "editable"
+        RenderTable {TABLE} at (0,21) size 63x31 [border: (1px outset #808080)]
+          RenderTableSection {TBODY} at (1,1) size 61x29
+            RenderTableRow {TR} at (0,2) size 61x25
+              RenderTableCell {TD} at (2,2) size 57x25 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 53x21
+                  text run at (2,2) width 53: "editable"
+        RenderBlock (anonymous) at (0,52) size 784x21
+          RenderText {#text} at (0,0) size 53x21
+            text run at (0,0) width 53: "editable"
 caret: position 2 of child 0 {#text} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-5-expected.checksum b/LayoutTests/platform/qt/editing/selection/mixed-editability-5-expected.checksum
new file mode 100644
index 0000000..0c103e6
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-5-expected.checksum
@@ -0,0 +1 @@
+23841e9c28c0dfbae57caf1fad91ad78
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-5-expected.png b/LayoutTests/platform/qt/editing/selection/mixed-editability-5-expected.png
new file mode 100644
index 0000000..ae3a5b4
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/mixed-editability-5-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-5-expected.txt b/LayoutTests/platform/qt/editing/selection/mixed-editability-5-expected.txt
index 531e573..077d3e1 100644
--- a/LayoutTests/platform/qt/editing/selection/mixed-editability-5-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-5-expected.txt
@@ -11,22 +11,22 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 751x38
-          text run at (0,0) width 456: "This tests moving the caret forward through content of mixed editability. "
-          text run at (456,0) width 295: "The caret should move down one line from the"
-          text run at (0,19) width 482: "editable piece to the editable piece that's embedded in a non-editable piece."
-      RenderBlock {DIV} at (0,52) size 784x67
-        RenderBlock (anonymous) at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 50x19
-            text run at (0,0) width 50: "editable"
-        RenderTable {TABLE} at (0,19) size 60x29 [border: (1px outset #808080)]
-          RenderTableSection {TBODY} at (1,1) size 58x27
-            RenderTableRow {TR} at (0,2) size 58x23
-              RenderTableCell {TD} at (2,2) size 54x23 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 50x19
-                  text run at (2,2) width 50: "editable"
-        RenderBlock (anonymous) at (0,48) size 784x19
-          RenderText {#text} at (0,0) size 50x19
-            text run at (0,0) width 50: "editable"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 783x42
+          text run at (0,0) width 494: "This tests moving the caret forward through content of mixed editability. "
+          text run at (494,0) width 289: "The caret should move down one line from"
+          text run at (0,21) width 527: "the editable piece to the editable piece that's embedded in a non-editable piece."
+      RenderBlock {DIV} at (0,58) size 784x73
+        RenderBlock (anonymous) at (0,0) size 784x21
+          RenderText {#text} at (0,0) size 53x21
+            text run at (0,0) width 53: "editable"
+        RenderTable {TABLE} at (0,21) size 63x31 [border: (1px outset #808080)]
+          RenderTableSection {TBODY} at (1,1) size 61x29
+            RenderTableRow {TR} at (0,2) size 61x25
+              RenderTableCell {TD} at (2,2) size 57x25 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 53x21
+                  text run at (2,2) width 53: "editable"
+        RenderBlock (anonymous) at (0,52) size 784x21
+          RenderText {#text} at (0,0) size 53x21
+            text run at (0,0) width 53: "editable"
 caret: position 9 of child 2 {#text} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-6-expected.checksum b/LayoutTests/platform/qt/editing/selection/mixed-editability-6-expected.checksum
new file mode 100644
index 0000000..aaec4ba
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-6-expected.checksum
@@ -0,0 +1 @@
+17880f783a91f47975f0e0318585a20d
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-6-expected.png b/LayoutTests/platform/qt/editing/selection/mixed-editability-6-expected.png
new file mode 100644
index 0000000..2db1c90
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/mixed-editability-6-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-6-expected.txt b/LayoutTests/platform/qt/editing/selection/mixed-editability-6-expected.txt
index ff42584..62e102e 100644
--- a/LayoutTests/platform/qt/editing/selection/mixed-editability-6-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-6-expected.txt
@@ -3,26 +3,26 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 772x38
-          text run at (0,0) width 623: "This tests Select All when the caret is inside an editable region that is inside a non editable region. "
-          text run at (623,0) width 149: "Whenever the selection"
-          text run at (0,19) width 555: "is in an editable region, Select All should select the contents of the highest editable root."
-      RenderBlock {DIV} at (0,52) size 784x57
-        RenderBlock {DIV} at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 27x19
-            text run at (0,0) width 27: "One"
-        RenderBlock {DIV} at (0,19) size 784x19
-          RenderInline {SPAN} at (0,0) size 27x19
-            RenderText {#text} at (0,0) size 27x19
-              text run at (0,0) width 27: "Two"
-          RenderText {#text} at (27,0) size 4x19
-            text run at (27,0) width 4: " "
-          RenderInline {SPAN} at (0,0) size 38x19
-            RenderText {#text} at (31,0) size 38x19
-              text run at (31,0) width 38: "Three"
-        RenderBlock {DIV} at (0,38) size 784x19
-          RenderText {#text} at (0,0) size 30x19
-            text run at (0,0) width 30: "Four"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 753x42
+          text run at (0,0) width 658: "This tests Select All when the caret is inside an editable region that is inside a non editable region. "
+          text run at (658,0) width 95: "Whenever the"
+          text run at (0,21) width 645: "selection is in an editable region, Select All should select the contents of the highest editable root."
+      RenderBlock {DIV} at (0,58) size 784x63
+        RenderBlock {DIV} at (0,0) size 784x21
+          RenderText {#text} at (0,0) size 28x21
+            text run at (0,0) width 28: "One"
+        RenderBlock {DIV} at (0,21) size 784x21
+          RenderInline {SPAN} at (0,0) size 31x21
+            RenderText {#text} at (0,0) size 31x21
+              text run at (0,0) width 31: "Two"
+          RenderText {#text} at (31,0) size 4x21
+            text run at (31,0) width 4: " "
+          RenderInline {SPAN} at (0,0) size 41x21
+            RenderText {#text} at (35,0) size 41x21
+              text run at (35,0) width 41: "Three"
+        RenderBlock {DIV} at (0,42) size 784x21
+          RenderText {#text} at (0,0) size 34x21
+            text run at (0,0) width 34: "Four"
 selection start: position 0 of child 0 {#text} of child 1 {DIV} of child 2 {DIV} of body
 selection end:   position 4 of child 0 {#text} of child 5 {DIV} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-7-expected.checksum b/LayoutTests/platform/qt/editing/selection/mixed-editability-7-expected.checksum
new file mode 100644
index 0000000..29d7a73
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-7-expected.checksum
@@ -0,0 +1 @@
+27dabadd02c6b8bb84a300a5f98065e0
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-7-expected.png b/LayoutTests/platform/qt/editing/selection/mixed-editability-7-expected.png
new file mode 100644
index 0000000..c9df682
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/mixed-editability-7-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-7-expected.txt b/LayoutTests/platform/qt/editing/selection/mixed-editability-7-expected.txt
index 4593168..bbbc85c 100644
--- a/LayoutTests/platform/qt/editing/selection/mixed-editability-7-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-7-expected.txt
@@ -3,26 +3,26 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 763x38
-          text run at (0,0) width 763: "This tests creating a selection based inside a nested editable region that extends out to editable content that is inside the"
-          text run at (0,19) width 176: "same highest editable root. "
-          text run at (176,19) width 261: "'One' through 'Three' should be selected."
-      RenderBlock {DIV} at (0,52) size 784x57
-        RenderBlock {DIV} at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 27x19
-            text run at (0,0) width 27: "One"
-        RenderBlock {DIV} at (0,19) size 784x19
-          RenderInline {SPAN} at (0,0) size 27x19
-            RenderText {#text} at (0,0) size 27x19
-              text run at (0,0) width 27: "Two"
-          RenderText {#text} at (27,0) size 4x19
-            text run at (27,0) width 4: " "
-          RenderInline {SPAN} at (0,0) size 38x19
-            RenderText {#text} at (31,0) size 38x19
-              text run at (31,0) width 38: "Three"
-        RenderBlock {DIV} at (0,38) size 784x19
-          RenderText {#text} at (0,0) size 30x19
-            text run at (0,0) width 30: "Four"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 772x42
+          text run at (0,0) width 772: "This tests creating a selection based inside a nested editable region that extends out to editable content that is inside"
+          text run at (0,21) width 208: "the same highest editable root. "
+          text run at (208,21) width 277: "'One' through 'Three' should be selected."
+      RenderBlock {DIV} at (0,58) size 784x63
+        RenderBlock {DIV} at (0,0) size 784x21
+          RenderText {#text} at (0,0) size 28x21
+            text run at (0,0) width 28: "One"
+        RenderBlock {DIV} at (0,21) size 784x21
+          RenderInline {SPAN} at (0,0) size 31x21
+            RenderText {#text} at (0,0) size 31x21
+              text run at (0,0) width 31: "Two"
+          RenderText {#text} at (31,0) size 4x21
+            text run at (31,0) width 4: " "
+          RenderInline {SPAN} at (0,0) size 41x21
+            RenderText {#text} at (35,0) size 41x21
+              text run at (35,0) width 41: "Three"
+        RenderBlock {DIV} at (0,42) size 784x21
+          RenderText {#text} at (0,0) size 34x21
+            text run at (0,0) width 34: "Four"
 selection start: position 0 of child 0 {#text} of child 1 {DIV} of child 2 {DIV} of body
 selection end:   position 5 of child 0 {#text} of child 2 {SPAN} of child 3 {DIV} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-8-expected.checksum b/LayoutTests/platform/qt/editing/selection/mixed-editability-8-expected.checksum
new file mode 100644
index 0000000..1277764
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-8-expected.checksum
@@ -0,0 +1 @@
+94b2126280930a80e7187cb6efbea9bd
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-8-expected.png b/LayoutTests/platform/qt/editing/selection/mixed-editability-8-expected.png
new file mode 100644
index 0000000..ca44ef6
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/mixed-editability-8-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-8-expected.txt b/LayoutTests/platform/qt/editing/selection/mixed-editability-8-expected.txt
index 03dcab6..bf32a4a 100644
--- a/LayoutTests/platform/qt/editing/selection/mixed-editability-8-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-8-expected.txt
@@ -8,26 +8,26 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 770x38
-          text run at (0,0) width 770: "This tests moving the caret backward through content of mixed editability. The caret should end up back at the start of the"
-          text run at (0,19) width 181: "editable text inside the table."
-      RenderBlock {DIV} at (0,52) size 784x67
-        RenderBlock (anonymous) at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 50x19
-            text run at (0,0) width 50: "editable"
-        RenderTable {TABLE} at (0,19) size 93x29 [border: (1px outset #808080)]
-          RenderTableSection {TBODY} at (1,1) size 91x27
-            RenderTableRow {TR} at (0,2) size 91x23
-              RenderTableCell {TD} at (2,2) size 87x23 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
-                RenderBlock {DIV} at (2,2) size 83x19
-                  RenderInline {SPAN} at (0,0) size 33x19
-                    RenderText {#text} at (0,0) size 33x19
-                      text run at (0,0) width 33: "static"
-                  RenderInline {SPAN} at (0,0) size 50x19
-                    RenderText {#text} at (33,0) size 50x19
-                      text run at (33,0) width 50: "editable"
-        RenderBlock (anonymous) at (0,48) size 784x19
-          RenderText {#text} at (0,0) size 50x19
-            text run at (0,0) width 50: "editable"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 751x42
+          text run at (0,0) width 751: "This tests moving the caret backward through content of mixed editability. The caret should end up back at the"
+          text run at (0,21) width 268: "start of the editable text inside the table."
+      RenderBlock {DIV} at (0,58) size 784x73
+        RenderBlock (anonymous) at (0,0) size 784x21
+          RenderText {#text} at (0,0) size 53x21
+            text run at (0,0) width 53: "editable"
+        RenderTable {TABLE} at (0,21) size 98x31 [border: (1px outset #808080)]
+          RenderTableSection {TBODY} at (1,1) size 96x29
+            RenderTableRow {TR} at (0,2) size 96x25
+              RenderTableCell {TD} at (2,2) size 92x25 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
+                RenderBlock {DIV} at (2,2) size 88x21
+                  RenderInline {SPAN} at (0,0) size 35x21
+                    RenderText {#text} at (0,0) size 35x21
+                      text run at (0,0) width 35: "static"
+                  RenderInline {SPAN} at (0,0) size 53x21
+                    RenderText {#text} at (35,0) size 53x21
+                      text run at (35,0) width 53: "editable"
+        RenderBlock (anonymous) at (0,52) size 784x21
+          RenderText {#text} at (0,0) size 53x21
+            text run at (0,0) width 53: "editable"
 caret: position 0 of child 0 {#text} of child 1 {SPAN} of child 0 {DIV} of child 0 {TD} of child 0 {TR} of child 0 {TBODY} of child 1 {TABLE} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-9-expected.checksum b/LayoutTests/platform/qt/editing/selection/mixed-editability-9-expected.checksum
new file mode 100644
index 0000000..51a4cf2
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-9-expected.checksum
@@ -0,0 +1 @@
+eb61643e487fcb5f733df7788ee5baf9
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-9-expected.png b/LayoutTests/platform/qt/editing/selection/mixed-editability-9-expected.png
new file mode 100644
index 0000000..ff8ae20
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/mixed-editability-9-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/mixed-editability-9-expected.txt b/LayoutTests/platform/qt/editing/selection/mixed-editability-9-expected.txt
index 150ed54..5077943 100644
--- a/LayoutTests/platform/qt/editing/selection/mixed-editability-9-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/mixed-editability-9-expected.txt
@@ -12,26 +12,26 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 775x38
-          text run at (0,0) width 775: "This tests moving the caret backward through content of mixed editability. The caret should back to just before the outlined"
-          text run at (0,19) width 35: "table."
-      RenderBlock {DIV} at (0,52) size 784x67
-        RenderBlock (anonymous) at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 50x19
-            text run at (0,0) width 50: "editable"
-        RenderTable {TABLE} at (0,19) size 93x29 [border: (1px outset #808080)]
-          RenderTableSection {TBODY} at (1,1) size 91x27
-            RenderTableRow {TR} at (0,2) size 91x23
-              RenderTableCell {TD} at (2,2) size 87x23 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
-                RenderBlock {DIV} at (2,2) size 83x19
-                  RenderInline {SPAN} at (0,0) size 33x19
-                    RenderText {#text} at (0,0) size 33x19
-                      text run at (0,0) width 33: "static"
-                  RenderInline {SPAN} at (0,0) size 50x19
-                    RenderText {#text} at (33,0) size 50x19
-                      text run at (33,0) width 50: "editable"
-        RenderBlock (anonymous) at (0,48) size 784x19
-          RenderText {#text} at (0,0) size 50x19
-            text run at (0,0) width 50: "editable"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 776x42
+          text run at (0,0) width 776: "This tests moving the caret backward through content of mixed editability. The caret should back to just before the"
+          text run at (0,21) width 96: "outlined table."
+      RenderBlock {DIV} at (0,58) size 784x73
+        RenderBlock (anonymous) at (0,0) size 784x21
+          RenderText {#text} at (0,0) size 53x21
+            text run at (0,0) width 53: "editable"
+        RenderTable {TABLE} at (0,21) size 98x31 [border: (1px outset #808080)]
+          RenderTableSection {TBODY} at (1,1) size 96x29
+            RenderTableRow {TR} at (0,2) size 96x25
+              RenderTableCell {TD} at (2,2) size 92x25 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
+                RenderBlock {DIV} at (2,2) size 88x21
+                  RenderInline {SPAN} at (0,0) size 35x21
+                    RenderText {#text} at (0,0) size 35x21
+                      text run at (0,0) width 35: "static"
+                  RenderInline {SPAN} at (0,0) size 53x21
+                    RenderText {#text} at (35,0) size 53x21
+                      text run at (35,0) width 53: "editable"
+        RenderBlock (anonymous) at (0,52) size 784x21
+          RenderText {#text} at (0,0) size 53x21
+            text run at (0,0) width 53: "editable"
 caret: position 0 of child 1 {TABLE} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-3875618-fix-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-3875618-fix-expected.checksum
new file mode 100644
index 0000000..9e459df
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-3875618-fix-expected.checksum
@@ -0,0 +1 @@
+0e4b85ae5d895436ae223dec2bbc5203
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-3875618-fix-expected.png b/LayoutTests/platform/qt/editing/selection/move-3875618-fix-expected.png
new file mode 100644
index 0000000..e17e754
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-3875618-fix-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-3875618-fix-expected.txt b/LayoutTests/platform/qt/editing/selection/move-3875618-fix-expected.txt
index 6576ccc..c24b169 100644
--- a/LayoutTests/platform/qt/editing/selection/move-3875618-fix-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-3875618-fix-expected.txt
@@ -8,13 +8,13 @@ layer 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 [border: (2px solid #FF0000)]
-      RenderBlock {DIV} at (14,14) size 756x64
-        RenderText {#text} at (0,0) size 151x31
-          text run at (0,0) width 151: "There is a tide"
-        RenderBR {BR} at (151,23) size 0x0
-        RenderText {#text} at (0,32) size 210x31
-          text run at (0,32) width 210: "in the affairs of men"
-      RenderBlock {DIV} at (14,78) size 756x32
-        RenderText {#text} at (0,0) size 256x31
-          text run at (0,0) width 256: "Which taken at the flood"
+      RenderBlock {DIV} at (14,14) size 756x62
+        RenderText {#text} at (0,0) size 147x32
+          text run at (0,0) width 147: "There is a tide"
+        RenderBR {BR} at (147,24) size 0x0
+        RenderText {#text} at (0,31) size 207x32
+          text run at (0,31) width 207: "in the affairs of men"
+      RenderBlock {DIV} at (14,76) size 756x31
+        RenderText {#text} at (0,0) size 253x32
+          text run at (0,0) width 253: "Which taken at the flood"
 caret: position 0 of child 2 {#text} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-3875641-fix-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-3875641-fix-expected.checksum
new file mode 100644
index 0000000..cf33f61
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-3875641-fix-expected.checksum
@@ -0,0 +1 @@
+03bd672da4bebfcabc8b9288b36241ab
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-3875641-fix-expected.png b/LayoutTests/platform/qt/editing/selection/move-3875641-fix-expected.png
new file mode 100644
index 0000000..e973a9d
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-3875641-fix-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-3875641-fix-expected.txt b/LayoutTests/platform/qt/editing/selection/move-3875641-fix-expected.txt
index 86ceb80..7c0ffa2 100644
--- a/LayoutTests/platform/qt/editing/selection/move-3875641-fix-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-3875641-fix-expected.txt
@@ -8,13 +8,13 @@ layer 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 [border: (2px solid #FF0000)]
-      RenderBlock {DIV} at (14,14) size 756x32
-        RenderText {#text} at (0,0) size 151x31
-          text run at (0,0) width 151: "There is a tide"
-      RenderBlock {DIV} at (14,46) size 756x32
-        RenderText {#text} at (0,0) size 210x31
-          text run at (0,0) width 210: "in the affairs of men"
-      RenderBlock {DIV} at (14,78) size 756x32
-        RenderText {#text} at (0,0) size 256x31
-          text run at (0,0) width 256: "Which taken at the flood"
+      RenderBlock {DIV} at (14,14) size 756x31
+        RenderText {#text} at (0,0) size 147x32
+          text run at (0,0) width 147: "There is a tide"
+      RenderBlock {DIV} at (14,45) size 756x31
+        RenderText {#text} at (0,0) size 207x32
+          text run at (0,0) width 207: "in the affairs of men"
+      RenderBlock {DIV} at (14,76) size 756x31
+        RenderText {#text} at (0,0) size 253x32
+          text run at (0,0) width 253: "Which taken at the flood"
 caret: position 0 of child 0 {#text} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-backwords-by-word-001-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-backwords-by-word-001-expected.checksum
new file mode 100644
index 0000000..ad7b93f
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-backwords-by-word-001-expected.checksum
@@ -0,0 +1 @@
+f97af8bc6558205272bc25aed994a10d
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-backwords-by-word-001-expected.png b/LayoutTests/platform/qt/editing/selection/move-backwords-by-word-001-expected.png
new file mode 100644
index 0000000..d9bae6f
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-backwords-by-word-001-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-backwords-by-word-001-expected.txt b/LayoutTests/platform/qt/editing/selection/move-backwords-by-word-001-expected.txt
index d77b3d8..389b354 100644
--- a/LayoutTests/platform/qt/editing/selection/move-backwords-by-word-001-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-backwords-by-word-001-expected.txt
@@ -18,12 +18,12 @@ layer 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 (0,0) size 784x92 [border: (2px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 79x63
-          RenderText {#text} at (14,14) size 33x31
-            text run at (14,14) width 33: "foo"
-          RenderBR {BR} at (47,37) size 0x0
-          RenderText {#text} at (14,46) size 79x31
-            text run at (14,46) width 79: "bar baz"
+      RenderBlock {DIV} at (0,0) size 784x90 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 78x63
+          RenderText {#text} at (14,14) size 32x32
+            text run at (14,14) width 32: "foo"
+          RenderBR {BR} at (46,38) size 0x0
+          RenderText {#text} at (14,45) size 78x32
+            text run at (14,45) width 78: "bar baz"
         RenderText {#text} at (0,0) size 0x0
 caret: position 0 of child 2 {#text} of child 1 {SPAN} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-begin-end-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-begin-end-expected.checksum
new file mode 100644
index 0000000..8c44fff
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-begin-end-expected.checksum
@@ -0,0 +1 @@
+cc476d8c1ea7650a170c370a52483f20
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-begin-end-expected.png b/LayoutTests/platform/qt/editing/selection/move-begin-end-expected.png
new file mode 100644
index 0000000..7daa8ad
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-begin-end-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-between-blocks-yes-001-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-between-blocks-yes-001-expected.checksum
new file mode 100644
index 0000000..877e805
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-between-blocks-yes-001-expected.checksum
@@ -0,0 +1 @@
+0bfd4589b09a9a618d4d48dff11065a9
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-between-blocks-yes-001-expected.png b/LayoutTests/platform/qt/editing/selection/move-between-blocks-yes-001-expected.png
new file mode 100644
index 0000000..93c8024
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-between-blocks-yes-001-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-between-blocks-yes-001-expected.txt b/LayoutTests/platform/qt/editing/selection/move-between-blocks-yes-001-expected.txt
index eadab07..a7c8a12 100644
--- a/LayoutTests/platform/qt/editing/selection/move-between-blocks-yes-001-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-between-blocks-yes-001-expected.txt
@@ -56,12 +56,12 @@ layer 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 (0,0) size 784x60 [border: (2px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 414x31
-          RenderText {#text} at (14,14) size 414x31
-            text run at (14,14) width 414: "We hold these truths to be self-evident,"
+      RenderBlock {DIV} at (0,0) size 784x59 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 398x32
+          RenderText {#text} at (14,14) size 398x32
+            text run at (14,14) width 398: "We hold these truths to be self-evident,"
         RenderText {#text} at (0,0) size 0x0
-      RenderBlock {DIV} at (0,60) size 784x60 [border: (2px solid #FF0000)]
-        RenderText {#text} at (14,14) size 349x31
-          text run at (14,14) width 349: "that all men are created equal, ..."
+      RenderBlock {DIV} at (0,59) size 784x59 [border: (2px solid #FF0000)]
+        RenderText {#text} at (14,14) size 338x32
+          text run at (14,14) width 338: "that all men are created equal, ..."
 caret: position 10 of child 0 {#text} of child 5 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-001-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-character-001-expected.checksum
new file mode 100644
index 0000000..09e3809
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-character-001-expected.checksum
@@ -0,0 +1 @@
+aee6417dcfaa7ad106bfa4487f8eb77b
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-001-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-character-001-expected.png
new file mode 100644
index 0000000..50d2e1a
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-character-001-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-001-expected.txt b/LayoutTests/platform/qt/editing/selection/move-by-character-001-expected.txt
index c76f2c7..94dc5fc 100644
--- a/LayoutTests/platform/qt/editing/selection/move-by-character-001-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-by-character-001-expected.txt
@@ -17,11 +17,11 @@ layer 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 (0,0) size 784x60 [border: (2px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 119x31
-          RenderText {#text} at (14,14) size 119x31
-            text run at (14,14) width 40: "foo "
-            text run at (54,14) width 41: "bar "
-            text run at (95,14) width 38: "baz"
+      RenderBlock {DIV} at (0,0) size 784x59 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 116x32
+          RenderText {#text} at (14,14) size 116x32
+            text run at (14,14) width 38: "foo "
+            text run at (52,14) width 42: "bar "
+            text run at (94,14) width 36: "baz"
         RenderText {#text} at (0,0) size 0x0
 caret: position 16 of child 0 {#text} of child 1 {SPAN} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-002-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-character-002-expected.checksum
new file mode 100644
index 0000000..9dcddb7
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-character-002-expected.checksum
@@ -0,0 +1 @@
+e47e8b0ad53e8bcde3cbb9b841878802
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-002-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-character-002-expected.png
new file mode 100644
index 0000000..c0b2f74
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-character-002-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-002-expected.txt b/LayoutTests/platform/qt/editing/selection/move-by-character-002-expected.txt
index a0bac23..77c301b 100644
--- a/LayoutTests/platform/qt/editing/selection/move-by-character-002-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-by-character-002-expected.txt
@@ -39,25 +39,25 @@ layer 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 (0,0) size 784x364 [border: (2px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 267x255
-          RenderText {#text} at (14,94) size 13x31
-            text run at (14,94) width 13: "a"
-          RenderImage {IMG} at (27,14) size 76x103
-          RenderText {#text} at (103,94) size 50x31
-            text run at (103,94) width 50: "new "
+      RenderBlock {DIV} at (0,0) size 784x358 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 260x252
+          RenderText {#text} at (14,93) size 12x32
+            text run at (14,93) width 12: "a"
+          RenderImage {IMG} at (26,14) size 76x103
+          RenderText {#text} at (102,93) size 47x32
+            text run at (102,93) width 47: "new "
           RenderBR {BR} at (0,0) size 0x0
-          RenderText {#text} at (14,206) size 71x31
-            text run at (14,206) width 71: "nation "
+          RenderText {#text} at (14,203) size 71x32
+            text run at (14,203) width 71: "nation "
           RenderInline {I} at (0,0) size 0x0
             RenderText {#text} at (0,0) size 0x0
           RenderText {#text} at (0,0) size 0x0
-          RenderImage {IMG} at (85,126) size 76x103
-          RenderText {#text} at (161,206) size 120x31
-            text run at (161,206) width 120: " conceived "
-          RenderBR {BR} at (281,229) size 0x0
-          RenderText {#text} at (14,318) size 64x31
-            text run at (14,318) width 64: "nation"
-          RenderImage {IMG} at (78,238) size 76x103
+          RenderImage {IMG} at (85,124) size 76x103
+          RenderText {#text} at (161,203) size 113x32
+            text run at (161,203) width 113: " conceived "
+          RenderBR {BR} at (274,227) size 0x0
+          RenderText {#text} at (14,313) size 65x32
+            text run at (14,313) width 65: "nation"
+          RenderImage {IMG} at (79,234) size 76x103
         RenderText {#text} at (0,0) size 0x0
 caret: position 6 of child 10 {#text} of child 1 {SPAN} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-003-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-character-003-expected.checksum
new file mode 100644
index 0000000..926e09a
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-character-003-expected.checksum
@@ -0,0 +1 @@
+23571fba078bbd066a5b9482ca923d78
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-003-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-character-003-expected.png
new file mode 100644
index 0000000..f2eac13
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-character-003-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-003-expected.txt b/LayoutTests/platform/qt/editing/selection/move-by-character-003-expected.txt
index 7e43929..9598012 100644
--- a/LayoutTests/platform/qt/editing/selection/move-by-character-003-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-by-character-003-expected.txt
@@ -165,24 +165,25 @@ layer 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 (0,0) size 784x125 [border: (2px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 732x95
-          RenderInline {I} at (0,0) size 131x32
-            RenderText {#text} at (14,14) size 131x32
+      RenderBlock {DIV} at (0,0) size 784x121 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 698x94
+          RenderInline {I} at (0,0) size 120x31
+            RenderText {#text} at (14,14) size 120x31
               text run at (14,14) width 22: "F "
-              text run at (36,14) width 109: "and seven"
-          RenderText {#text} at (145,15) size 72x31
-            text run at (145,15) width 72: " years "
-          RenderInline {B} at (0,0) size 33x33
-            RenderText {#text} at (217,14) size 33x33
-              text run at (217,14) width 33: "as "
-          RenderText {#text} at (250,15) size 732x63
-            text run at (250,15) width 121: "our fathers "
-            text run at (371,15) width 375: "f upon this continent, a new nation, "
-            text run at (14,47) width 244: "conceived    in Liberty, "
-            text run at (258,47) width 421: "and dedicated to the proposition that all "
+              text run at (36,14) width 98: "and seven"
+          RenderText {#text} at (134,14) size 67x32
+            text run at (134,14) width 67: " years "
+          RenderInline {B} at (0,0) size 27x32
+            RenderText {#text} at (201,14) size 27x32
+              text run at (201,14) width 27: "as "
+          RenderText {#text} at (228,14) size 698x63
+            text run at (228,14) width 120: "our fathers "
+            text run at (348,14) width 358: "f upon this continent, a new nation,"
+            text run at (706,14) width 6: " "
+            text run at (14,45) width 241: "conceived    in Liberty, "
+            text run at (255,45) width 415: "and dedicated to the proposition that all "
           RenderBR {BR} at (0,0) size 0x0
-          RenderText {#text} at (14,79) size 244x31
-            text run at (14,79) width 244: "men are created equal."
+          RenderText {#text} at (14,76) size 235x32
+            text run at (14,76) width 235: "men are created equal."
         RenderText {#text} at (0,0) size 0x0
 caret: position 21 of child 5 {#text} of child 1 {SPAN} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-004-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-character-004-expected.checksum
new file mode 100644
index 0000000..144c3a5
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-character-004-expected.checksum
@@ -0,0 +1 @@
+2be083473dea14c4bd59230d6ae309a9
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-004-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-character-004-expected.png
new file mode 100644
index 0000000..ddae183
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-character-004-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-004-expected.txt b/LayoutTests/platform/qt/editing/selection/move-by-character-004-expected.txt
index 02ffd7e..e3f745e 100644
--- a/LayoutTests/platform/qt/editing/selection/move-by-character-004-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-by-character-004-expected.txt
@@ -71,25 +71,25 @@ layer 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 (0,0) size 784x364 [border: (2px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 267x255
-          RenderText {#text} at (14,94) size 13x31
-            text run at (14,94) width 13: "a"
-          RenderImage {IMG} at (27,14) size 76x103
-          RenderText {#text} at (103,94) size 50x31
-            text run at (103,94) width 50: "new "
+      RenderBlock {DIV} at (0,0) size 784x358 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 260x252
+          RenderText {#text} at (14,93) size 12x32
+            text run at (14,93) width 12: "a"
+          RenderImage {IMG} at (26,14) size 76x103
+          RenderText {#text} at (102,93) size 47x32
+            text run at (102,93) width 47: "new "
           RenderBR {BR} at (0,0) size 0x0
-          RenderText {#text} at (14,206) size 71x31
-            text run at (14,206) width 71: "nation "
+          RenderText {#text} at (14,203) size 71x32
+            text run at (14,203) width 71: "nation "
           RenderInline {I} at (0,0) size 0x0
             RenderText {#text} at (0,0) size 0x0
           RenderText {#text} at (0,0) size 0x0
-          RenderImage {IMG} at (85,126) size 76x103
-          RenderText {#text} at (161,206) size 120x31
-            text run at (161,206) width 120: " conceived "
-          RenderBR {BR} at (281,229) size 0x0
-          RenderText {#text} at (14,318) size 64x31
-            text run at (14,318) width 64: "nation"
-          RenderImage {IMG} at (78,238) size 76x103
+          RenderImage {IMG} at (85,124) size 76x103
+          RenderText {#text} at (161,203) size 113x32
+            text run at (161,203) width 113: " conceived "
+          RenderBR {BR} at (274,227) size 0x0
+          RenderText {#text} at (14,313) size 65x32
+            text run at (14,313) width 65: "nation"
+          RenderImage {IMG} at (79,234) size 76x103
         RenderText {#text} at (0,0) size 0x0
 caret: position 1 of child 0 {#text} of child 1 {SPAN} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-005-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-character-005-expected.checksum
new file mode 100644
index 0000000..5f8132a
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-character-005-expected.checksum
@@ -0,0 +1 @@
+4b62b161cd9980e6871918a427afd067
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-005-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-character-005-expected.png
new file mode 100644
index 0000000..1d251d7
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-character-005-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-character-005-expected.txt b/LayoutTests/platform/qt/editing/selection/move-by-character-005-expected.txt
index c2a4d11..237babc 100644
--- a/LayoutTests/platform/qt/editing/selection/move-by-character-005-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-by-character-005-expected.txt
@@ -323,24 +323,25 @@ layer 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 (0,0) size 784x125 [border: (2px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 732x95
-          RenderInline {I} at (0,0) size 131x32
-            RenderText {#text} at (14,14) size 131x32
+      RenderBlock {DIV} at (0,0) size 784x121 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 698x94
+          RenderInline {I} at (0,0) size 120x31
+            RenderText {#text} at (14,14) size 120x31
               text run at (14,14) width 22: "F "
-              text run at (36,14) width 109: "and seven"
-          RenderText {#text} at (145,15) size 72x31
-            text run at (145,15) width 72: " years "
-          RenderInline {B} at (0,0) size 33x33
-            RenderText {#text} at (217,14) size 33x33
-              text run at (217,14) width 33: "as "
-          RenderText {#text} at (250,15) size 732x63
-            text run at (250,15) width 121: "our fathers "
-            text run at (371,15) width 375: "f upon this continent, a new nation, "
-            text run at (14,47) width 244: "conceived    in Liberty, "
-            text run at (258,47) width 421: "and dedicated to the proposition that all "
+              text run at (36,14) width 98: "and seven"
+          RenderText {#text} at (134,14) size 67x32
+            text run at (134,14) width 67: " years "
+          RenderInline {B} at (0,0) size 27x32
+            RenderText {#text} at (201,14) size 27x32
+              text run at (201,14) width 27: "as "
+          RenderText {#text} at (228,14) size 698x63
+            text run at (228,14) width 120: "our fathers "
+            text run at (348,14) width 358: "f upon this continent, a new nation,"
+            text run at (706,14) width 6: " "
+            text run at (14,45) width 241: "conceived    in Liberty, "
+            text run at (255,45) width 415: "and dedicated to the proposition that all "
           RenderBR {BR} at (0,0) size 0x0
-          RenderText {#text} at (14,79) size 244x31
-            text run at (14,79) width 244: "men are created equal."
+          RenderText {#text} at (14,76) size 235x32
+            text run at (14,76) width 235: "men are created equal."
         RenderText {#text} at (0,0) size 0x0
 caret: position 1 of child 0 {#text} of child 0 {I} of child 1 {SPAN} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-001-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-line-001-expected.checksum
new file mode 100644
index 0000000..bada3ae
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-line-001-expected.checksum
@@ -0,0 +1 @@
+decd4dc26a632746114759bd038d03d4
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-001-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-line-001-expected.png
new file mode 100644
index 0000000..114d57d
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-line-001-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-001-expected.txt b/LayoutTests/platform/qt/editing/selection/move-by-line-001-expected.txt
index 504fbeb..d750798 100644
--- a/LayoutTests/platform/qt/editing/selection/move-by-line-001-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-by-line-001-expected.txt
@@ -10,18 +10,18 @@ layer 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 (0,0) size 784x202 [border: (2px solid #FF0000)]
-        RenderBlock {DIV} at (14,14) size 756x174
-          RenderTable {TABLE} at (0,0) size 66x174 [border: (1px outset #808080)]
-            RenderTableSection {TBODY} at (1,1) size 64x172
-              RenderTableRow {TR} at (0,2) size 64x58
-                RenderTableCell {TD} at (2,2) size 60x58 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
-                  RenderText {#text} at (13,13) size 33x31
-                    text run at (13,13) width 33: "foo"
-              RenderTableRow {TR} at (0,62) size 64x48
-                RenderTableCell {TD} at (2,73) size 60x26 [border: (1px inset #808080)] [r=1 c=0 rs=1 cs=1]
-              RenderTableRow {TR} at (0,112) size 64x58
-                RenderTableCell {TD} at (2,112) size 60x58 [border: (1px inset #808080)] [r=2 c=0 rs=1 cs=1]
-                  RenderText {#text} at (13,13) size 34x31
-                    text run at (13,13) width 34: "bar"
+      RenderBlock {DIV} at (0,0) size 784x200 [border: (2px solid #FF0000)]
+        RenderBlock {DIV} at (14,14) size 756x172
+          RenderTable {TABLE} at (0,0) size 68x172 [border: (1px outset #808080)]
+            RenderTableSection {TBODY} at (1,1) size 66x170
+              RenderTableRow {TR} at (0,2) size 66x57
+                RenderTableCell {TD} at (2,2) size 62x57 [border: (1px inset #808080)] [r=0 c=0 rs=1 cs=1]
+                  RenderText {#text} at (13,13) size 32x32
+                    text run at (13,13) width 32: "foo"
+              RenderTableRow {TR} at (0,61) size 66x48
+                RenderTableCell {TD} at (2,72) size 62x26 [border: (1px inset #808080)] [r=1 c=0 rs=1 cs=1]
+              RenderTableRow {TR} at (0,111) size 66x57
+                RenderTableCell {TD} at (2,111) size 62x57 [border: (1px inset #808080)] [r=2 c=0 rs=1 cs=1]
+                  RenderText {#text} at (13,13) size 36x32
+                    text run at (13,13) width 36: "bar"
 caret: position 2 of child 1 {TABLE} of child 1 {DIV} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-002-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-line-002-expected.checksum
new file mode 100644
index 0000000..091589f
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-line-002-expected.checksum
@@ -0,0 +1 @@
+7f740057c2db973336da159af2279dc3
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-002-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-line-002-expected.png
new file mode 100644
index 0000000..67ec716
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-line-002-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-002-expected.txt b/LayoutTests/platform/qt/editing/selection/move-by-line-002-expected.txt
index 7ec4fc1..a88a759 100644
--- a/LayoutTests/platform/qt/editing/selection/move-by-line-002-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-by-line-002-expected.txt
@@ -8,26 +8,26 @@ layer 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 (0,0) size 784x236 [border: (2px solid #FF0000)]
-        RenderBlock {DIV} at (14,38) size 756x160
-          RenderBlock {OL} at (0,0) size 756x160
-            RenderListItem {LI} at (40,0) size 716x32
-              RenderListMarker at (-34,0) size 27x31: "1"
-              RenderText {#text} at (0,0) size 39x31
-                text run at (0,0) width 39: "one"
-            RenderListItem {LI} at (40,32) size 716x32
-              RenderListMarker at (-34,0) size 27x31: "2"
-              RenderText {#text} at (0,0) size 37x31
+      RenderBlock {DIV} at (0,0) size 784x231 [border: (2px solid #FF0000)]
+        RenderBlock {DIV} at (14,38) size 756x155
+          RenderBlock {OL} at (0,0) size 756x155
+            RenderListItem {LI} at (40,0) size 716x31
+              RenderListMarker at (-32,0) size 24x32: "1"
+              RenderText {#text} at (0,0) size 36x32
+                text run at (0,0) width 36: "one"
+            RenderListItem {LI} at (40,31) size 716x31
+              RenderListMarker at (-32,0) size 24x32: "2"
+              RenderText {#text} at (0,0) size 37x32
                 text run at (0,0) width 37: "two"
-            RenderListItem {LI} at (40,64) size 716x32
-              RenderListMarker at (-34,0) size 27x31: "3"
-              RenderBR {BR} at (0,0) size 0x31
-            RenderListItem {LI} at (40,96) size 716x32
-              RenderListMarker at (-34,0) size 27x31: "4"
-              RenderText {#text} at (0,0) size 41x31
-                text run at (0,0) width 41: "four"
-            RenderListItem {LI} at (40,128) size 716x32
-              RenderListMarker at (-34,0) size 27x31: "5"
-              RenderText {#text} at (0,0) size 37x31
-                text run at (0,0) width 37: "five"
+            RenderListItem {LI} at (40,62) size 716x31
+              RenderListMarker at (-32,0) size 24x32: "3"
+              RenderBR {BR} at (0,0) size 0x32
+            RenderListItem {LI} at (40,93) size 716x31
+              RenderListMarker at (-32,0) size 24x32: "4"
+              RenderText {#text} at (0,0) size 44x32
+                text run at (0,0) width 44: "four"
+            RenderListItem {LI} at (40,124) size 716x31
+              RenderListMarker at (-32,0) size 24x32: "5"
+              RenderText {#text} at (0,0) size 38x32
+                text run at (0,0) width 38: "five"
 caret: position 0 of child 0 {BR} of child 2 {LI} of child 1 {OL} of child 1 {DIV} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-003-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-line-003-expected.checksum
new file mode 100644
index 0000000..f2f0223
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-line-003-expected.checksum
@@ -0,0 +1 @@
+29406a4361afba747b42e83c95511c89
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-003-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-line-003-expected.png
new file mode 100644
index 0000000..2962c85
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-line-003-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-004-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-line-004-expected.checksum
new file mode 100644
index 0000000..05949b7
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-line-004-expected.checksum
@@ -0,0 +1 @@
+4301aa36b978ffd513118e6dfabb2b2a
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-004-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-line-004-expected.png
new file mode 100644
index 0000000..1e1cd5b
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-line-004-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-005-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-line-005-expected.checksum
new file mode 100644
index 0000000..868edae
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-line-005-expected.checksum
@@ -0,0 +1 @@
+d573a1afc902ed1024a09dd5fbe3d99e
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-line-005-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-line-005-expected.png
new file mode 100644
index 0000000..0cd7a0d
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-line-005-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-sentence-001-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-sentence-001-expected.checksum
new file mode 100644
index 0000000..0fc4d7b
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-sentence-001-expected.checksum
@@ -0,0 +1 @@
+4e33ab27dceb8a5872093458effe3651
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-sentence-001-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-sentence-001-expected.png
new file mode 100644
index 0000000..857a1ec
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-sentence-001-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-sentence-001-expected.txt b/LayoutTests/platform/qt/editing/selection/move-by-sentence-001-expected.txt
index cb0ff78..df127dd 100644
--- a/LayoutTests/platform/qt/editing/selection/move-by-sentence-001-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-by-sentence-001-expected.txt
@@ -22,13 +22,12 @@ layer 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 (0,0) size 784x61 [border: (2px solid #FF0000)]
-        RenderText {#text} at (14,15) size 15x31
-          text run at (14,15) width 15: "\x{2022} "
-        RenderInline {B} at (0,0) size 272x33
-          RenderText {#text} at (29,14) size 272x33
-            text run at (29,14) width 272: "This is some linked text"
-        RenderText {#text} at (0,0) size 0x0
+      RenderBlock {DIV} at (0,0) size 784x59 [border: (2px solid #FF0000)]
+        RenderText {#text} at (14,14) size 14x32
+          text run at (14,14) width 14: "\x{2022} "
+        RenderInline {B} at (0,0) size 240x32
+          RenderText {#text} at (28,14) size 240x32
+            text run at (28,14) width 240: "This is some linked text"
         RenderText {#text} at (0,0) size 0x0
         RenderText {#text} at (0,0) size 0x0
 caret: position 1 of child 0 {#text} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-sentence-linebreak-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-sentence-linebreak-expected.checksum
new file mode 100644
index 0000000..71b9a74
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-sentence-linebreak-expected.checksum
@@ -0,0 +1 @@
+34a0a3d09229add5fbc94bded41e2f27
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-sentence-linebreak-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-sentence-linebreak-expected.png
new file mode 100644
index 0000000..f2a80f3
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-sentence-linebreak-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-sentence-linebreak-expected.txt b/LayoutTests/platform/qt/editing/selection/move-by-sentence-linebreak-expected.txt
index 5330d01..2b6e8d8 100644
--- a/LayoutTests/platform/qt/editing/selection/move-by-sentence-linebreak-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-by-sentence-linebreak-expected.txt
@@ -3,28 +3,28 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 562x19
-          text run at (0,0) width 562: "This tests for sentence boundary when there are empty line breaks between lines of text."
-        RenderBR {BR} at (562,14) size 0x0
-        RenderText {#text} at (0,19) size 495x19
-          text run at (0,19) width 495: "The result insertion point should be at the end of the sentence \"How are you?\""
-      RenderBlock {DIV} at (0,52) size 784x114
-        RenderBlock (anonymous) at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 30x19
-            text run at (0,0) width 30: "hello"
-        RenderBlock {DIV} at (0,19) size 784x19
-          RenderBR {BR} at (0,0) size 0x19
-        RenderBlock {DIV} at (0,38) size 784x19
-          RenderText {#text} at (0,0) size 34x19
-            text run at (0,0) width 34: "world"
-        RenderBlock {DIV} at (0,57) size 784x19
-          RenderBR {BR} at (0,0) size 0x19
-        RenderBlock {DIV} at (0,76) size 784x19
-          RenderBR {BR} at (0,0) size 0x19
-        RenderBlock {DIV} at (0,95) size 784x19
-          RenderText {#text} at (0,0) size 262x19
-            text run at (0,0) width 88: "This is a test. "
-            text run at (88,0) width 92: "How are you? "
-            text run at (180,0) width 82: "Life is sweet!"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 593x21
+          text run at (0,0) width 593: "This tests for sentence boundary when there are empty line breaks between lines of text."
+        RenderBR {BR} at (593,16) size 0x0
+        RenderText {#text} at (0,21) size 531x21
+          text run at (0,21) width 531: "The result insertion point should be at the end of the sentence \"How are you?\""
+      RenderBlock {DIV} at (0,58) size 784x126
+        RenderBlock (anonymous) at (0,0) size 784x21
+          RenderText {#text} at (0,0) size 32x21
+            text run at (0,0) width 32: "hello"
+        RenderBlock {DIV} at (0,21) size 784x21
+          RenderBR {BR} at (0,0) size 0x21
+        RenderBlock {DIV} at (0,42) size 784x21
+          RenderText {#text} at (0,0) size 40x21
+            text run at (0,0) width 40: "world"
+        RenderBlock {DIV} at (0,63) size 784x21
+          RenderBR {BR} at (0,0) size 0x21
+        RenderBlock {DIV} at (0,84) size 784x21
+          RenderBR {BR} at (0,0) size 0x21
+        RenderBlock {DIV} at (0,105) size 784x21
+          RenderText {#text} at (0,0) size 277x21
+            text run at (0,0) width 91: "This is a test. "
+            text run at (91,0) width 99: "How are you? "
+            text run at (190,0) width 87: "Life is sweet!"
 caret: position 30 of child 0 {#text} of child 9 {DIV} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-word-001-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-by-word-001-expected.checksum
new file mode 100644
index 0000000..21d0a57
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-by-word-001-expected.checksum
@@ -0,0 +1 @@
+341e929df684c8cf3e219d502d093f36
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-word-001-expected.png b/LayoutTests/platform/qt/editing/selection/move-by-word-001-expected.png
new file mode 100644
index 0000000..bbdf901
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-by-word-001-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/move-by-word-001-expected.txt b/LayoutTests/platform/qt/editing/selection/move-by-word-001-expected.txt
index 4db9be7..8b75a90 100644
--- a/LayoutTests/platform/qt/editing/selection/move-by-word-001-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/move-by-word-001-expected.txt
@@ -9,12 +9,12 @@ layer 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 (0,0) size 784x92 [border: (2px solid #FF0000)]
-        RenderBlock {DIV} at (14,14) size 756x32
-          RenderText {#text} at (0,0) size 33x31
-            text run at (0,0) width 33: "foo"
-        RenderBlock (anonymous) at (14,46) size 756x32
-          RenderText {#text} at (0,0) size 34x31
-            text run at (0,0) width 34: "bar"
+      RenderBlock {DIV} at (0,0) size 784x90 [border: (2px solid #FF0000)]
+        RenderBlock {DIV} at (14,14) size 756x31
+          RenderText {#text} at (0,0) size 32x32
+            text run at (0,0) width 32: "foo"
+        RenderBlock (anonymous) at (14,45) size 756x31
+          RenderText {#text} at (0,0) size 36x32
+            text run at (0,0) width 36: "bar"
 selection start: position 0 of child 2 {#text} of child 1 {DIV} of body
 selection end:   position 3 of child 2 {#text} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/move-paragraph-document-edges-expected.checksum b/LayoutTests/platform/qt/editing/selection/move-paragraph-document-edges-expected.checksum
new file mode 100644
index 0000000..5d04ecf
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/move-paragraph-document-edges-expected.checksum
@@ -0,0 +1 @@
+8b050f1e661aa0f20af7bfd4fc7db91c
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/move-paragraph-document-edges-expected.png b/LayoutTests/platform/qt/editing/selection/move-paragraph-document-edges-expected.png
new file mode 100644
index 0000000..50dc22b
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/move-paragraph-document-edges-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/node-removal-1-expected.checksum b/LayoutTests/platform/qt/editing/selection/node-removal-1-expected.checksum
new file mode 100644
index 0000000..77cabb4
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/node-removal-1-expected.checksum
@@ -0,0 +1 @@
+12383773e08f94a97df443a979d39db6
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/node-removal-1-expected.png b/LayoutTests/platform/qt/editing/selection/node-removal-1-expected.png
new file mode 100644
index 0000000..13d03e8
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/node-removal-1-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/node-removal-1-expected.txt b/LayoutTests/platform/qt/editing/selection/node-removal-1-expected.txt
index 71f8aba..39696b4 100644
--- a/LayoutTests/platform/qt/editing/selection/node-removal-1-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/node-removal-1-expected.txt
@@ -5,19 +5,19 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 761x38
-          text run at (0,0) width 694: "This tests behavior when a node that serves as the start or end of a selection is removed from the document. "
-          text run at (694,0) width 67: "Ideally, we"
-          text run at (0,19) width 645: "would just adjust the selection when an endpoint is removed, for now, we just blow away the selection."
-      RenderBlock {P} at (0,52) size 784x38
-        RenderText {#text} at (0,0) size 783x38
-          text run at (0,0) width 484: "This test creates a selection that ends inside of a node that will be removed. "
-          text run at (484,0) width 175: "Then the node is removed. "
-          text run at (659,0) width 124: "There should be no"
-          text run at (0,19) width 124: "selection afterward."
-      RenderBlock {DIV} at (0,104) size 784x19
-        RenderText {#text} at (0,0) size 34x19
-          text run at (0,0) width 34: "hello "
-        RenderText {#text} at (34,0) size 38x19
-          text run at (34,0) width 38: "world!"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 777x42
+          text run at (0,0) width 727: "This tests behavior when a node that serves as the start or end of a selection is removed from the document. "
+          text run at (727,0) width 50: "Ideally,"
+          text run at (0,21) width 713: "we would just adjust the selection when an endpoint is removed, for now, we just blow away the selection."
+      RenderBlock {P} at (0,58) size 784x42
+        RenderText {#text} at (0,0) size 779x42
+          text run at (0,0) width 506: "This test creates a selection that ends inside of a node that will be removed. "
+          text run at (506,0) width 183: "Then the node is removed. "
+          text run at (689,0) width 90: "There should"
+          text run at (0,21) width 174: "be no selection afterward."
+      RenderBlock {DIV} at (0,116) size 784x21
+        RenderText {#text} at (0,0) size 36x21
+          text run at (0,0) width 36: "hello "
+        RenderText {#text} at (36,0) size 45x21
+          text run at (36,0) width 45: "world!"
diff --git a/LayoutTests/platform/qt/editing/selection/node-removal-2-expected.checksum b/LayoutTests/platform/qt/editing/selection/node-removal-2-expected.checksum
new file mode 100644
index 0000000..e3ba7e6
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/node-removal-2-expected.checksum
@@ -0,0 +1 @@
+6633d3c8d23c236bc8cebf795c7606af
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/node-removal-2-expected.png b/LayoutTests/platform/qt/editing/selection/node-removal-2-expected.png
new file mode 100644
index 0000000..623c0a1
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/node-removal-2-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/node-removal-2-expected.txt b/LayoutTests/platform/qt/editing/selection/node-removal-2-expected.txt
index f94b715..04682c5 100644
--- a/LayoutTests/platform/qt/editing/selection/node-removal-2-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/node-removal-2-expected.txt
@@ -7,22 +7,22 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 761x38
-          text run at (0,0) width 694: "This tests behavior when a node that serves as the start or end of a selection is removed from the document. "
-          text run at (694,0) width 67: "Ideally, we"
-          text run at (0,19) width 645: "would just adjust the selection when an endpoint is removed, for now, we just blow away the selection."
-      RenderBlock {P} at (0,52) size 784x38
-        RenderText {#text} at (0,0) size 780x38
-          text run at (0,0) width 484: "This test creates a selection that ends inside of a node that will be removed. "
-          text run at (484,0) width 175: "Then the node is removed. "
-          text run at (659,0) width 121: "Then a Select All is"
-          text run at (0,19) width 66: "executed. "
-          text run at (66,19) width 259: "The entire document should be selected."
-      RenderBlock {DIV} at (0,104) size 784x19
-        RenderText {#text} at (0,0) size 34x19
-          text run at (0,0) width 34: "hello "
-        RenderText {#text} at (34,0) size 38x19
-          text run at (34,0) width 38: "world!"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 777x42
+          text run at (0,0) width 727: "This tests behavior when a node that serves as the start or end of a selection is removed from the document. "
+          text run at (727,0) width 50: "Ideally,"
+          text run at (0,21) width 713: "we would just adjust the selection when an endpoint is removed, for now, we just blow away the selection."
+      RenderBlock {P} at (0,58) size 784x42
+        RenderText {#text} at (0,0) size 780x42
+          text run at (0,0) width 506: "This test creates a selection that ends inside of a node that will be removed. "
+          text run at (506,0) width 183: "Then the node is removed. "
+          text run at (689,0) width 91: "Then a Select"
+          text run at (0,21) width 105: "All is executed. "
+          text run at (105,21) width 270: "The entire document should be selected."
+      RenderBlock {DIV} at (0,116) size 784x21
+        RenderText {#text} at (0,0) size 36x21
+          text run at (0,0) width 36: "hello "
+        RenderText {#text} at (36,0) size 45x21
+          text run at (36,0) width 45: "world!"
 selection start: position 0 of child 0 {#text} of child 1 {P} of body
 selection end:   position 7 of child 1 {#text} of child 5 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/paragraph-granularity-expected.checksum b/LayoutTests/platform/qt/editing/selection/paragraph-granularity-expected.checksum
new file mode 100644
index 0000000..baebb11
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/paragraph-granularity-expected.checksum
@@ -0,0 +1 @@
+463fb60f92f911ef063276ee69671ab5
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/paragraph-granularity-expected.png b/LayoutTests/platform/qt/editing/selection/paragraph-granularity-expected.png
new file mode 100644
index 0000000..811cc95
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/paragraph-granularity-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/paragraph-granularity-expected.txt b/LayoutTests/platform/qt/editing/selection/paragraph-granularity-expected.txt
new file mode 100644
index 0000000..af8d998
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/paragraph-granularity-expected.txt
@@ -0,0 +1,55 @@
+EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 15 of #text > DIV > BODY > HTML > #document to 15 of #text > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 15 of #text > DIV > BODY > HTML > #document to 15 of #text > DIV > BODY > HTML > #document toDOMRange:range from 11 of #text > DIV > BODY > HTML > #document to 4 of #text > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 11 of #text > DIV > BODY > HTML > #document to 4 of #text > DIV > BODY > HTML > #document toDOMRange:range from 1 of #text > DIV > BODY > HTML > #document to 4 of DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 1 of #text > DIV > BODY > HTML > #document to 4 of DIV > BODY > HTML > #document toDOMRange:range from 1 of #text > DIV > BODY > HTML > #document to 5 of #text > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+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 {P} at (0,0) size 784x21
+        RenderText {#text} at (0,0) size 748x21
+          text run at (0,0) width 391: "This tests modifying a selection created with a triple click. "
+          text run at (391,0) width 357: "The new selection should use paragraph granularity."
+      RenderBlock {P} at (0,37) size 784x63 [color=#008000]
+        RenderText {#text} at (0,0) size 744x63
+          text run at (0,0) width 241: "This test does not run interactively. "
+          text run at (241,0) width 442: "It uses the layoutTestControllers eventSender to do mouse clicks. "
+          text run at (683,0) width 61: "To run it"
+          text run at (0,21) width 464: "manually, double click on the blue 'g', then drag down to the red 'g'. "
+          text run at (464,21) width 263: "As you drag, watch the selection that is"
+          text run at (0,42) width 442: "created, it should always start and end on paragraph boundaries."
+      RenderBlock {DIV} at (0,116) size 784x126
+        RenderText {#text} at (0,0) size 92x21
+          text run at (0,0) width 92: "This is a para"
+        RenderInline {SPAN} at (0,0) size 8x21 [color=#0000FF]
+          RenderText {#text} at (92,0) size 8x21
+            text run at (92,0) width 8: "g"
+        RenderText {#text} at (100,0) size 37x21
+          text run at (100,0) width 37: "raph."
+        RenderBR {BR} at (137,16) size 0x0
+        RenderText {#text} at (0,21) size 66x21
+          text run at (0,21) width 66: "Some text"
+        RenderBR {BR} at (66,37) size 0x0
+        RenderText {#text} at (0,42) size 66x21
+          text run at (0,42) width 66: "Some text"
+        RenderBR {BR} at (66,58) size 0x0
+        RenderText {#text} at (0,63) size 66x21
+          text run at (0,63) width 66: "Some text"
+        RenderBR {BR} at (66,79) size 0x0
+        RenderText {#text} at (0,84) size 66x21
+          text run at (0,84) width 66: "Some text"
+        RenderBR {BR} at (66,100) size 0x0
+        RenderText {#text} at (0,105) size 92x21
+          text run at (0,105) width 92: "This is a para"
+        RenderInline {SPAN} at (0,0) size 8x21 [color=#FF0000]
+          RenderText {#text} at (92,105) size 8x21
+            text run at (92,105) width 8: "g"
+        RenderText {#text} at (100,105) size 37x21
+          text run at (100,105) width 37: "raph."
+selection start: position 1 of child 0 {#text} of child 5 {DIV} of body
+selection end:   position 5 of child 14 {#text} of child 5 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/previous-line-position-expected.checksum b/LayoutTests/platform/qt/editing/selection/previous-line-position-expected.checksum
new file mode 100644
index 0000000..970c337
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/previous-line-position-expected.checksum
@@ -0,0 +1 @@
+57939e5c6462bf7a7d163781af75f65c
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/previous-line-position-expected.png b/LayoutTests/platform/qt/editing/selection/previous-line-position-expected.png
new file mode 100644
index 0000000..39d9177
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/previous-line-position-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/previous-line-position-expected.txt b/LayoutTests/platform/qt/editing/selection/previous-line-position-expected.txt
index 5e96179..5bb80eb 100644
--- a/LayoutTests/platform/qt/editing/selection/previous-line-position-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/previous-line-position-expected.txt
@@ -7,29 +7,29 @@ layer 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 {P} at (0,0) size 784x57
-        RenderText {#text} at (0,0) size 240x19
-          text run at (0,0) width 240: "There was a workaround added to fix "
-        RenderInline {A} at (0,0) size 150x19 [color=#0000EE]
-          RenderText {#text} at (240,0) size 150x19
-            text run at (240,0) width 150: "rdar://problem/4033202"
-        RenderText {#text} at (390,0) size 294x19
-          text run at (390,0) width 8: ". "
-          text run at (398,0) width 286: "A bug to remove the workaround was filed as"
-        RenderInline {A} at (0,0) size 150x19 [color=#0000EE]
-          RenderText {#text} at (0,19) size 150x19
-            text run at (0,19) width 150: "rdar://problem/4040763"
-        RenderText {#text} at (150,19) size 753x38
-          text run at (150,19) width 8: ". "
-          text run at (158,19) width 595: "The underlying problem with VisiblePositions was fixed, and so I removed the workaround and"
-          text run at (0,38) width 139: "added this layout test."
-      RenderBlock {DIV} at (0,71) size 784x59 [border: (1px solid #0000FF)]
-        RenderBlock {P} at (1,1) size 782x19
-          RenderText {#text} at (0,0) size 11x19
-            text run at (0,0) width 11: "hi"
-          RenderInline {SPAN} at (0,0) size 0x19
-        RenderBlock (anonymous) at (1,20) size 782x38
-          RenderBR {BR} at (0,0) size 0x19
-          RenderText {#text} at (0,19) size 23x19
-            text run at (0,19) width 23: "test"
+      RenderBlock {P} at (0,0) size 784x63
+        RenderText {#text} at (0,0) size 261x21
+          text run at (0,0) width 261: "There was a workaround added to fix "
+        RenderInline {A} at (0,0) size 161x21 [color=#0000EE]
+          RenderText {#text} at (261,0) size 161x21
+            text run at (261,0) width 161: "rdar://problem/4033202"
+        RenderText {#text} at (422,0) size 317x21
+          text run at (422,0) width 8: ". "
+          text run at (430,0) width 309: "A bug to remove the workaround was filed as"
+        RenderInline {A} at (0,0) size 161x21 [color=#0000EE]
+          RenderText {#text} at (0,21) size 161x21
+            text run at (0,21) width 161: "rdar://problem/4040763"
+        RenderText {#text} at (161,21) size 696x42
+          text run at (161,21) width 8: ". "
+          text run at (169,21) width 527: "The underlying problem with VisiblePositions was fixed, and so I removed the"
+          text run at (0,42) width 267: "workaround and added this layout test."
+      RenderBlock {DIV} at (0,79) size 784x65 [border: (1px solid #0000FF)]
+        RenderBlock {P} at (1,1) size 782x21
+          RenderText {#text} at (0,0) size 13x21
+            text run at (0,0) width 13: "hi"
+          RenderInline {SPAN} at (0,0) size 0x21
+        RenderBlock (anonymous) at (1,22) size 782x42
+          RenderBR {BR} at (0,0) size 0x21
+          RenderText {#text} at (0,21) size 23x21
+            text run at (0,21) width 23: "test"
 caret: position 0 of child 2 {BR} of child 3 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/range-between-block-and-inline-expected.checksum b/LayoutTests/platform/qt/editing/selection/range-between-block-and-inline-expected.checksum
index 63c6c0f..00e09e2 100644
--- a/LayoutTests/platform/qt/editing/selection/range-between-block-and-inline-expected.checksum
+++ b/LayoutTests/platform/qt/editing/selection/range-between-block-and-inline-expected.checksum
@@ -1 +1 @@
-2ad415a8921ea61230784dab8477f6e9
\ No newline at end of file
+c4f9e80502476b75bb8a1cf87e02a691
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/range-between-block-and-inline-expected.png b/LayoutTests/platform/qt/editing/selection/range-between-block-and-inline-expected.png
index ecf66a6..491ad27 100644
Binary files a/LayoutTests/platform/qt/editing/selection/range-between-block-and-inline-expected.png and b/LayoutTests/platform/qt/editing/selection/range-between-block-and-inline-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/rangeCount-expected.checksum b/LayoutTests/platform/qt/editing/selection/rangeCount-expected.checksum
new file mode 100644
index 0000000..19c5b0a
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/rangeCount-expected.checksum
@@ -0,0 +1 @@
+ce3929c24e865b5e3c1289cdbc58722f
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/rangeCount-expected.png b/LayoutTests/platform/qt/editing/selection/rangeCount-expected.png
new file mode 100644
index 0000000..56e1c7e
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/rangeCount-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/removeAllRanges-expected.checksum b/LayoutTests/platform/qt/editing/selection/removeAllRanges-expected.checksum
new file mode 100644
index 0000000..71aecff
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/removeAllRanges-expected.checksum
@@ -0,0 +1 @@
+3eefa43fef00c0ea60037aac90e51ac0
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/removeAllRanges-expected.png b/LayoutTests/platform/qt/editing/selection/removeAllRanges-expected.png
new file mode 100644
index 0000000..09302f6
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/removeAllRanges-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/replace-selection-crash-expected.checksum b/LayoutTests/platform/qt/editing/selection/replace-selection-crash-expected.checksum
new file mode 100644
index 0000000..e035371
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/replace-selection-crash-expected.checksum
@@ -0,0 +1 @@
+efc0441f94f1baa4478385399b5b448c
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/replace-selection-crash-expected.png b/LayoutTests/platform/qt/editing/selection/replace-selection-crash-expected.png
new file mode 100644
index 0000000..2cc2889
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/replace-selection-crash-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-1-expected.checksum b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-1-expected.checksum
new file mode 100644
index 0000000..44e90ea
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-1-expected.checksum
@@ -0,0 +1 @@
+306a78d6add550069962f47ef87f783b
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-1-expected.png b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-1-expected.png
new file mode 100644
index 0000000..e518bd2
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-1-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-1-expected.txt b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-1-expected.txt
index cb2d43f..86976a9 100644
--- a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-1-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-1-expected.txt
@@ -12,16 +12,16 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 726x38
-          text run at (0,0) width 726: "This tests that when a selection that starts at [replaced element, 1] is painted, the replaced element doesn't appear"
-          text run at (0,19) width 61: "selected. "
-          text run at (61,19) width 314: "This test uses an image for the replaced element."
-      RenderBlock {DIV} at (0,52) size 784x108
-        RenderText {#text} at (0,89) size 23x19
-          text run at (0,89) width 23: "abc"
-        RenderImage {IMG} at (23,0) size 76x103
-        RenderText {#text} at (99,89) size 20x19
-          text run at (99,89) width 20: "def"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 761x42
+          text run at (0,0) width 761: "This tests that when a selection that starts at [replaced element, 1] is painted, the replaced element doesn't appear"
+          text run at (0,21) width 60: "selected. "
+          text run at (60,21) width 325: "This test uses an image for the replaced element."
+      RenderBlock {DIV} at (0,58) size 784x108
+        RenderText {#text} at (0,87) size 24x21
+          text run at (0,87) width 24: "abc"
+        RenderImage {IMG} at (24,0) size 76x103
+        RenderText {#text} at (100,87) size 21x21
+          text run at (100,87) width 21: "def"
 selection start: position 0 of child 2 {#text} of child 3 {DIV} of body
 selection end:   position 3 of child 2 {#text} of child 3 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-2-expected.checksum b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-2-expected.checksum
new file mode 100644
index 0000000..f3f49ff
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-2-expected.checksum
@@ -0,0 +1 @@
+64ed69bcce3c5249db4f76969e131b03
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-2-expected.png b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-2-expected.png
new file mode 100644
index 0000000..3c583dc
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-2-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-2-expected.txt b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-2-expected.txt
index b7bd7e4..55236ba 100644
--- a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-2-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-2-expected.txt
@@ -12,15 +12,16 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 783x38
-          text run at (0,0) width 783: "This tests that when a selection that ends at [replaced element, 0] is painted, the replaced element doesn't appear selected."
-          text run at (0,19) width 314: "This test uses an image for the replaced element."
-      RenderBlock {DIV} at (0,52) size 784x108
-        RenderText {#text} at (0,89) size 23x19
-          text run at (0,89) width 23: "abc"
-        RenderImage {IMG} at (23,0) size 76x103
-        RenderText {#text} at (99,89) size 20x19
-          text run at (99,89) width 20: "def"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 755x42
+          text run at (0,0) width 755: "This tests that when a selection that ends at [replaced element, 0] is painted, the replaced element doesn't appear"
+          text run at (0,21) width 60: "selected. "
+          text run at (60,21) width 325: "This test uses an image for the replaced element."
+      RenderBlock {DIV} at (0,58) size 784x108
+        RenderText {#text} at (0,87) size 24x21
+          text run at (0,87) width 24: "abc"
+        RenderImage {IMG} at (24,0) size 76x103
+        RenderText {#text} at (100,87) size 21x21
+          text run at (100,87) width 21: "def"
 selection start: position 1 of child 0 {#text} of child 3 {DIV} of body
 selection end:   position 4 of child 0 {#text} of child 3 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-3-expected.checksum b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-3-expected.checksum
new file mode 100644
index 0000000..e489e0b
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-3-expected.checksum
@@ -0,0 +1 @@
+0622919c2f22f16282e93d9946522c7f
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-3-expected.png b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-3-expected.png
new file mode 100644
index 0000000..a9bf3c3
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-3-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-3-expected.txt b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-3-expected.txt
index 2c8094e..37c028f 100644
--- a/LayoutTests/platform/qt/editing/selection/replaced-boundaries-3-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/replaced-boundaries-3-expected.txt
@@ -10,18 +10,19 @@ layer 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 {P} at (0,0) size 784x38
-        RenderText {#text} at (0,0) size 783x38
-          text run at (0,0) width 783: "This tests that when a selection that ends at [replaced element, 0] is painted, the replaced element doesn't appear selected."
-          text run at (0,19) width 331: "This test uses a select box for the replaced element."
-      RenderBlock {DIV} at (0,52) size 784x48
-        RenderText {#text} at (0,0) size 23x19
-          text run at (0,0) width 23: "abc"
-        RenderBR {BR} at (23,14) size 0x0
-        RenderMenuList {SELECT} at (2,21) size 260x25 [bgcolor=#FFFFFF]
-          RenderBlock (anonymous) at (8,4) size 228x19
-            RenderText at (0,0) size 228x19
-              text run at (0,0) width 228: "this select box shouldn't be selected"
+      RenderBlock {P} at (0,0) size 784x42
+        RenderText {#text} at (0,0) size 755x42
+          text run at (0,0) width 755: "This tests that when a selection that ends at [replaced element, 0] is painted, the replaced element doesn't appear"
+          text run at (0,21) width 60: "selected. "
+          text run at (60,21) width 341: "This test uses a select box for the replaced element."
+      RenderBlock {DIV} at (0,58) size 784x52
+        RenderText {#text} at (0,0) size 24x21
+          text run at (0,0) width 24: "abc"
+        RenderBR {BR} at (24,16) size 0x0
+        RenderMenuList {SELECT} at (2,23) size 268x27 [bgcolor=#FFFFFF]
+          RenderBlock (anonymous) at (8,4) size 236x21
+            RenderText at (0,0) size 236x21
+              text run at (0,0) width 236: "this select box shouldn't be selected"
         RenderText {#text} at (0,0) size 0x0
 selection start: position 1 of child 0 {#text} of child 3 {DIV} of body
 selection end:   position 1 of child 1 {BR} of child 3 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/root-inlinebox-selected-children-crash-expected.checksum b/LayoutTests/platform/qt/editing/selection/root-inlinebox-selected-children-crash-expected.checksum
new file mode 100644
index 0000000..1c6eb24
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/root-inlinebox-selected-children-crash-expected.checksum
@@ -0,0 +1 @@
+60a1e8889eacb996547c5660e5cd7319
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/root-inlinebox-selected-children-crash-expected.png b/LayoutTests/platform/qt/editing/selection/root-inlinebox-selected-children-crash-expected.png
new file mode 100644
index 0000000..1b5142b
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/root-inlinebox-selected-children-crash-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/select-all-004-expected.checksum b/LayoutTests/platform/qt/editing/selection/select-all-004-expected.checksum
new file mode 100644
index 0000000..6641b27
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/select-all-004-expected.checksum
@@ -0,0 +1 @@
+ee718f2b772c23057e23ffe280df3968
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/select-all-004-expected.png b/LayoutTests/platform/qt/editing/selection/select-all-004-expected.png
new file mode 100644
index 0000000..ffdfeb8
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/select-all-004-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/select-all-004-expected.txt b/LayoutTests/platform/qt/editing/selection/select-all-004-expected.txt
index f18fbc1..e555032 100644
--- a/LayoutTests/platform/qt/editing/selection/select-all-004-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/select-all-004-expected.txt
@@ -3,20 +3,20 @@ EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 0 of #text > BODY > HTML > #document to 0 of #text > BODY > HTML > #document toDOMRange:range from 1 of #text > BODY > HTML > #document to 5 of BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
-layer at (0,0) size 812x600
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 812x600
-  RenderBlock {HTML} at (0,0) size 800x600
-    RenderBody {BODY} at (64,64) size 748x472 [border: (50px solid #FF0000)]
+layer at (0,0) size 812x584
+  RenderView at (0,0) size 800x584
+layer at (0,0) size 800x584
+  RenderBlock {HTML} at (0,0) size 800x584
+    RenderBody {BODY} at (64,64) size 748x456 [border: (50px solid #FF0000)]
       RenderBlock {DIV} at (74,74) size 600x0
       RenderBlock (anonymous) at (74,74) size 600x48
-        RenderText {#text} at (0,8) size 53x31
-          text run at (0,8) width 53: "Hello"
+        RenderText {#text} at (0,8) size 56x32
+          text run at (0,8) width 56: "Hello"
       RenderTable {TABLE} at (74,122) size 6x6
         RenderTableSection {TBODY} at (0,0) size 6x6
           RenderTableRow {TR} at (0,2) size 6x2
             RenderTableCell {TD} at (2,2) size 2x2 [r=0 c=0 rs=1 cs=1]
       RenderBlock (anonymous) at (74,128) size 600x48
-        RenderBR {BR} at (0,8) size 0x31
+        RenderBR {BR} at (0,8) size 0x32
 selection start: position 1 of child 2 {#text} of body
 selection end:   position 0 of child 5 {BR} of body
diff --git a/LayoutTests/platform/qt/editing/selection/select-all-iframe-expected.checksum b/LayoutTests/platform/qt/editing/selection/select-all-iframe-expected.checksum
new file mode 100644
index 0000000..6225b15
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/select-all-iframe-expected.checksum
@@ -0,0 +1 @@
+7e380a66e713cc5d5d8de271b5d66ae2
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/select-all-iframe-expected.png b/LayoutTests/platform/qt/editing/selection/select-all-iframe-expected.png
new file mode 100644
index 0000000..2891c43
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/select-all-iframe-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/select-all-iframe-expected.txt b/LayoutTests/platform/qt/editing/selection/select-all-iframe-expected.txt
new file mode 100644
index 0000000..16870a4
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/select-all-iframe-expected.txt
@@ -0,0 +1,56 @@
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of BODY > HTML > #document to 4 of BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 0 of DIV > BODY > HTML > #document to 0 of DIV > BODY > HTML > #document toDOMRange:range from 11 of #text > DIV > BODY > HTML > #document to 11 of #text > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 11 of #text > DIV > BODY > HTML > #document to 11 of #text > DIV > BODY > HTML > #document toDOMRange:range from 0 of #text > DIV > BODY > HTML > #document to 11 of #text > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldDeleteDOMRange:range from 0 of #text > DIV > BODY > HTML > #document to 11 of #text > DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 0 of DIV > BODY > HTML > #document to 0 of DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: webViewDidChange:WebViewDidChangeNotification
+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 784x576
+      RenderBlock (anonymous) at (0,0) size 784x175
+        RenderPartObject {IFRAME} at (0,0) size 304x154 [border: (2px inset #000000)]
+          layer at (0,0) size 300x150
+            RenderView at (0,0) size 300x150
+          layer at (0,0) size 300x150
+            RenderBlock {HTML} at (0,0) size 300x150
+              RenderBody {BODY} at (8,8) size 284x134 [bgcolor=#FFFFE0]
+                RenderBlock {DIV} at (0,0) size 284x21
+                  RenderBR {BR} at (0,0) size 0x21
+        RenderBR {BR} at (304,154) size 0x0
+        RenderBR {BR} at (0,154) size 0x21
+      RenderBlock {P} at (0,191) size 784x42
+        RenderInline {B} at (0,0) size 664x21
+          RenderText {#text} at (0,0) size 664x21
+            text run at (0,0) width 491: "This test uses the eventSender to do a mouse click to focus the subframe. "
+            text run at (491,0) width 173: "It won't run interactively."
+        RenderText {#text} at (664,0) size 729x42
+          text run at (664,0) width 4: " "
+          text run at (668,0) width 61: "To run it"
+          text run at (0,21) width 374: "manually, click on the iframe, Select All, then hit delete."
+      RenderBlock (anonymous) at (0,249) size 784x63
+        RenderText {#text} at (0,0) size 774x63
+          text run at (0,0) width 774: "Selecting all the content in a contenteditable iframe should select the iframe itself (to help the user delete the iframe)"
+          text run at (0,21) width 279: "only if the iframe is in an editable region. "
+          text run at (279,21) width 453: "This test loads ../resources/select-all-iframe-src.html into an iframe. "
+          text run at (732,21) width 33: "That"
+          text run at (0,42) width 200: "file does a Select All + Delete. "
+          text run at (200,42) width 185: "Two things should happen:"
+      RenderBlock {UL} at (0,328) size 784x63
+        RenderListItem {LI} at (40,0) size 744x42
+          RenderListMarker at (-18,0) size 7x21: bullet
+          RenderText {#text} at (0,0) size 711x42
+            text run at (0,0) width 479: "The Select All operation should not select the iframe, only it's contents. "
+            text run at (479,0) width 232: "The results of the Select All will be"
+            text run at (0,21) width 550: "apparent from the delegate messages that DumpRenderTree receives and dumps."
+        RenderListItem {LI} at (40,42) size 744x21
+          RenderListMarker at (-18,0) size 7x21: bullet
+          RenderText {#text} at (0,0) size 359x21
+            text run at (0,0) width 359: "The contents of the editable iframe should be deleted."
diff --git a/LayoutTests/platform/qt/editing/selection/select-all-textarea-expected.checksum b/LayoutTests/platform/qt/editing/selection/select-all-textarea-expected.checksum
new file mode 100644
index 0000000..94eaf5d
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/select-all-textarea-expected.checksum
@@ -0,0 +1 @@
+6490f59e413580c4d1620ebdfca6691d
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/select-all-textarea-expected.png b/LayoutTests/platform/qt/editing/selection/select-all-textarea-expected.png
new file mode 100644
index 0000000..393cd8b
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/select-all-textarea-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/select-all-user-select-none-expected.checksum b/LayoutTests/platform/qt/editing/selection/select-all-user-select-none-expected.checksum
new file mode 100644
index 0000000..567b9ec
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/select-all-user-select-none-expected.checksum
@@ -0,0 +1 @@
+0e3eb2b4cd9c84f369bb929ed4e357e4
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/select-all-user-select-none-expected.png b/LayoutTests/platform/qt/editing/selection/select-all-user-select-none-expected.png
new file mode 100644
index 0000000..4c6afdc
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/select-all-user-select-none-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/select-crash-001-expected.checksum b/LayoutTests/platform/qt/editing/selection/select-crash-001-expected.checksum
new file mode 100644
index 0000000..bc1aeea
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/select-crash-001-expected.checksum
@@ -0,0 +1 @@
+d9923d5bc5afa18630ea88afda036ac1
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/select-crash-001-expected.png b/LayoutTests/platform/qt/editing/selection/select-crash-001-expected.png
new file mode 100644
index 0000000..a4e0bdf
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/select-crash-001-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/select-crash-002-expected.checksum b/LayoutTests/platform/qt/editing/selection/select-crash-002-expected.checksum
new file mode 100644
index 0000000..c4e0113
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/select-crash-002-expected.checksum
@@ -0,0 +1 @@
+ea4b7b717327533e3ae4bda40b487369
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/select-crash-002-expected.png b/LayoutTests/platform/qt/editing/selection/select-crash-002-expected.png
new file mode 100644
index 0000000..7c68a2f
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/select-crash-002-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/select-element-paragraph-boundary-expected.checksum b/LayoutTests/platform/qt/editing/selection/select-element-paragraph-boundary-expected.checksum
new file mode 100644
index 0000000..ff69edc
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/select-element-paragraph-boundary-expected.checksum
@@ -0,0 +1 @@
+80217a6dccba7869af381edc691114f4
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/select-element-paragraph-boundary-expected.png b/LayoutTests/platform/qt/editing/selection/select-element-paragraph-boundary-expected.png
new file mode 100644
index 0000000..3bde2d1
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/select-element-paragraph-boundary-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/select-line-expected.checksum b/LayoutTests/platform/qt/editing/selection/select-line-expected.checksum
new file mode 100644
index 0000000..d8b1c1c
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/select-line-expected.checksum
@@ -0,0 +1 @@
+b88c268d98e3bafb3274537ff70b8a1f
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/select-line-expected.png b/LayoutTests/platform/qt/editing/selection/select-line-expected.png
new file mode 100644
index 0000000..abb8acc
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/select-line-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/select-missing-image-expected.checksum b/LayoutTests/platform/qt/editing/selection/select-missing-image-expected.checksum
new file mode 100644
index 0000000..27abc2e
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/select-missing-image-expected.checksum
@@ -0,0 +1 @@
+ed5909c3edb05b906ed8cb9f213cc166
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/select-missing-image-expected.png b/LayoutTests/platform/qt/editing/selection/select-missing-image-expected.png
new file mode 100644
index 0000000..8ee9e1e
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/select-missing-image-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/select-missing-image-expected.txt b/LayoutTests/platform/qt/editing/selection/select-missing-image-expected.txt
index 3193a31..0b1a6a7 100644
--- a/LayoutTests/platform/qt/editing/selection/select-missing-image-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/select-missing-image-expected.txt
@@ -1,4 +1,7 @@
-EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 1 of DIV > BODY > HTML > #document to 2 of DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 3 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 0 of DIV > BODY > HTML > #document to 0 of DIV > BODY > HTML > #document toDOMRange:range from 1 of DIV > BODY > HTML > #document to 2 of DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 layer at (0,0) size 800x600
   RenderView at (0,0) size 800x600
diff --git a/LayoutTests/platform/qt/editing/selection/select-text-overflow-ellipsis-expected.checksum b/LayoutTests/platform/qt/editing/selection/select-text-overflow-ellipsis-expected.checksum
new file mode 100644
index 0000000..293fbc3
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/select-text-overflow-ellipsis-expected.checksum
@@ -0,0 +1 @@
+715c53f19e9f49bf704fb37fa13cf457
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/select-text-overflow-ellipsis-expected.png b/LayoutTests/platform/qt/editing/selection/select-text-overflow-ellipsis-expected.png
new file mode 100644
index 0000000..1544120
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/select-text-overflow-ellipsis-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/selectAllChildren-expected.checksum b/LayoutTests/platform/qt/editing/selection/selectAllChildren-expected.checksum
new file mode 100644
index 0000000..5e8c0fe
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/selectAllChildren-expected.checksum
@@ -0,0 +1 @@
+ea819e9c0a7684cb3e1d110bbc2e29c6
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/selectAllChildren-expected.png b/LayoutTests/platform/qt/editing/selection/selectAllChildren-expected.png
new file mode 100644
index 0000000..b84fc9f
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/selectAllChildren-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/selectNode-expected.checksum b/LayoutTests/platform/qt/editing/selection/selectNode-expected.checksum
new file mode 100644
index 0000000..d1a4e47
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/selectNode-expected.checksum
@@ -0,0 +1 @@
+526370afe0f1d8d1df0f89c052099535
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/selectNode-expected.png b/LayoutTests/platform/qt/editing/selection/selectNode-expected.png
new file mode 100644
index 0000000..4306152
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/selectNode-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/selectNode-expected.txt b/LayoutTests/platform/qt/editing/selection/selectNode-expected.txt
index af3d813..ef5f1df 100644
--- a/LayoutTests/platform/qt/editing/selection/selectNode-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/selectNode-expected.txt
@@ -2,24 +2,24 @@ 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 784x578
-      RenderBlock {P} at (0,0) size 784x19
-        RenderText {#text} at (0,0) size 344x19
-          text run at (0,0) width 344: "This tests Range.selectNode() of a text node and a br."
-      RenderBlock {DIV} at (0,33) size 784x19
-        RenderText {#text} at (0,0) size 24x19
+    RenderBody {BODY} at (8,8) size 784x576
+      RenderBlock {P} at (0,0) size 784x21
+        RenderText {#text} at (0,0) size 358x21
+          text run at (0,0) width 358: "This tests Range.selectNode() of a text node and a br."
+      RenderBlock {DIV} at (0,37) size 784x21
+        RenderText {#text} at (0,0) size 24x21
           text run at (0,0) width 24: "one"
-      RenderBlock {DIV} at (0,52) size 784x38
-        RenderText {#text} at (0,0) size 22x19
-          text run at (0,0) width 22: "two"
-        RenderBR {BR} at (22,14) size 0x0
-        RenderText {#text} at (0,19) size 33x19
-          text run at (0,19) width 33: "three"
-      RenderBlock {DIV} at (0,90) size 784x19
-        RenderText {#text} at (0,0) size 25x19
-          text run at (0,0) width 25: "four"
-      RenderBlock {UL} at (0,123) size 784x19
-        RenderListItem {LI} at (40,0) size 744x19
-          RenderListMarker at (-17,0) size 7x19: bullet
-          RenderText {#text} at (0,0) size 57x19
-            text run at (0,0) width 57: "Success."
+      RenderBlock {DIV} at (0,58) size 784x42
+        RenderText {#text} at (0,0) size 25x21
+          text run at (0,0) width 25: "two"
+        RenderBR {BR} at (25,16) size 0x0
+        RenderText {#text} at (0,21) size 35x21
+          text run at (0,21) width 35: "three"
+      RenderBlock {DIV} at (0,100) size 784x21
+        RenderText {#text} at (0,0) size 29x21
+          text run at (0,0) width 29: "four"
+      RenderBlock {UL} at (0,137) size 784x21
+        RenderListItem {LI} at (40,0) size 744x21
+          RenderListMarker at (-18,0) size 7x21: bullet
+          RenderText {#text} at (0,0) size 55x21
+            text run at (0,0) width 55: "Success."
diff --git a/LayoutTests/platform/qt/editing/selection/selectNodeContents-expected.checksum b/LayoutTests/platform/qt/editing/selection/selectNodeContents-expected.checksum
new file mode 100644
index 0000000..f13495a
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/selectNodeContents-expected.checksum
@@ -0,0 +1 @@
+84fed1f2ebd99f2267ad4231e4f11919
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/selectNodeContents-expected.png b/LayoutTests/platform/qt/editing/selection/selectNodeContents-expected.png
new file mode 100644
index 0000000..1f8bdb1
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/selectNodeContents-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/selectNodeContents-expected.txt b/LayoutTests/platform/qt/editing/selection/selectNodeContents-expected.txt
index a500e22..427fd6d 100644
--- a/LayoutTests/platform/qt/editing/selection/selectNodeContents-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/selectNodeContents-expected.txt
@@ -2,24 +2,24 @@ 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 784x578
-      RenderBlock {P} at (0,0) size 784x19
-        RenderText {#text} at (0,0) size 401x19
-          text run at (0,0) width 401: "This tests Range.selectNodeContents() of a text node and a br."
-      RenderBlock {DIV} at (0,33) size 784x19
-        RenderText {#text} at (0,0) size 24x19
+    RenderBody {BODY} at (8,8) size 784x576
+      RenderBlock {P} at (0,0) size 784x21
+        RenderText {#text} at (0,0) size 419x21
+          text run at (0,0) width 419: "This tests Range.selectNodeContents() of a text node and a br."
+      RenderBlock {DIV} at (0,37) size 784x21
+        RenderText {#text} at (0,0) size 24x21
           text run at (0,0) width 24: "one"
-      RenderBlock {DIV} at (0,52) size 784x38
-        RenderText {#text} at (0,0) size 22x19
-          text run at (0,0) width 22: "two"
-        RenderBR {BR} at (22,14) size 0x0
-        RenderText {#text} at (0,19) size 33x19
-          text run at (0,19) width 33: "three"
-      RenderBlock {DIV} at (0,90) size 784x19
-        RenderText {#text} at (0,0) size 25x19
-          text run at (0,0) width 25: "four"
-      RenderBlock {UL} at (0,123) size 784x19
-        RenderListItem {LI} at (40,0) size 744x19
-          RenderListMarker at (-17,0) size 7x19: bullet
-          RenderText {#text} at (0,0) size 57x19
-            text run at (0,0) width 57: "Success."
+      RenderBlock {DIV} at (0,58) size 784x42
+        RenderText {#text} at (0,0) size 25x21
+          text run at (0,0) width 25: "two"
+        RenderBR {BR} at (25,16) size 0x0
+        RenderText {#text} at (0,21) size 35x21
+          text run at (0,21) width 35: "three"
+      RenderBlock {DIV} at (0,100) size 784x21
+        RenderText {#text} at (0,0) size 29x21
+          text run at (0,0) width 29: "four"
+      RenderBlock {UL} at (0,137) size 784x21
+        RenderListItem {LI} at (40,0) size 744x21
+          RenderListMarker at (-18,0) size 7x21: bullet
+          RenderText {#text} at (0,0) size 55x21
+            text run at (0,0) width 55: "Success."
diff --git a/LayoutTests/platform/qt/editing/selection/selection-3748164-fix-expected.checksum b/LayoutTests/platform/qt/editing/selection/selection-3748164-fix-expected.checksum
new file mode 100644
index 0000000..03a4d01
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/selection-3748164-fix-expected.checksum
@@ -0,0 +1 @@
+aa145a5f19e323d01e2b7ab04f5ce1b1
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/selection-3748164-fix-expected.png b/LayoutTests/platform/qt/editing/selection/selection-3748164-fix-expected.png
new file mode 100644
index 0000000..42172db
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/selection-3748164-fix-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/selection-3748164-fix-expected.txt b/LayoutTests/platform/qt/editing/selection/selection-3748164-fix-expected.txt
index d518f0c..8340986 100644
--- a/LayoutTests/platform/qt/editing/selection/selection-3748164-fix-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/selection-3748164-fix-expected.txt
@@ -1,3 +1,5 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 3 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
@@ -10,14 +12,14 @@ layer 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 (0,0) size 784x77 [border: (2px solid #FF0000)]
-        RenderBlock {DIV} at (14,14) size 756x49
+      RenderBlock {DIV} at (0,0) size 784x74 [border: (2px solid #FF0000)]
+        RenderBlock {DIV} at (14,14) size 756x46
           RenderInline {SPAN} at (0,0) size 0x0
-          RenderBR {BR} at (0,0) size 0x31
-          RenderInline {SPAN} at (0,0) size 29x17
-            RenderText {#text} at (0,32) size 29x17
-              text run at (0,32) width 29: "- Ken"
-          RenderBR {BR} at (29,44) size 0x0
+          RenderBR {BR} at (0,0) size 0x32
+          RenderInline {SPAN} at (0,0) size 29x15
+            RenderText {#text} at (0,31) size 29x15
+              text run at (0,31) width 29: "- Ken"
+          RenderBR {BR} at (29,43) size 0x0
           RenderInline {SPAN} at (0,0) size 0x0
           RenderText {#text} at (0,0) size 0x0
 caret: position 5 of child 0 {#text} of child 4 {SPAN} of child 1 {DIV} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/selection-actions-expected.checksum b/LayoutTests/platform/qt/editing/selection/selection-actions-expected.checksum
new file mode 100644
index 0000000..54c787b
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/selection-actions-expected.checksum
@@ -0,0 +1 @@
+72dedfb86ee80c69f1bc207e4a8817b7
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/selection-actions-expected.png b/LayoutTests/platform/qt/editing/selection/selection-actions-expected.png
new file mode 100644
index 0000000..893d940
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/selection-actions-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/selection-actions-expected.txt b/LayoutTests/platform/qt/editing/selection/selection-actions-expected.txt
new file mode 100644
index 0000000..32f736a
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/selection-actions-expected.txt
@@ -0,0 +1,40 @@
+EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 15 of #text > BODY > HTML > #document to 15 of #text > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 15 of #text > BODY > HTML > #document to 15 of #text > BODY > HTML > #document toDOMRange:range from 11 of #text > BODY > HTML > #document to 4 of #text > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 11 of #text > BODY > HTML > #document to 4 of #text > BODY > HTML > #document toDOMRange:range from 11 of #text > BODY > HTML > #document to 8 of BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+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
+      RenderText {#text} at (0,0) size 757x42
+        text run at (0,0) width 757: "This tests whether certain NSResponder methods that should only operate on editable regions modify a selection"
+        text run at (0,21) width 213: "that is not in an editable region."
+      RenderBR {BR} at (213,37) size 0x0
+      RenderText {#text} at (0,42) size 92x21
+        text run at (0,42) width 92: "This is a para"
+      RenderInline {SPAN} at (0,0) size 8x21 [color=#0000FF]
+        RenderText {#text} at (92,42) size 8x21
+          text run at (92,42) width 8: "g"
+      RenderText {#text} at (100,42) size 37x21
+        text run at (100,42) width 37: "raph."
+      RenderBR {BR} at (137,58) size 0x0
+      RenderText {#text} at (0,63) size 66x21
+        text run at (0,63) width 66: "Some text"
+      RenderBR {BR} at (66,79) size 0x0
+      RenderText {#text} at (0,84) size 66x21
+        text run at (0,84) width 66: "Some text"
+      RenderBR {BR} at (66,100) size 0x0
+      RenderText {#text} at (0,105) size 66x21
+        text run at (0,105) width 66: "Some text"
+      RenderBR {BR} at (66,121) size 0x0
+      RenderText {#text} at (0,126) size 66x21
+        text run at (0,126) width 66: "Some text"
+      RenderBR {BR} at (66,142) size 0x0
+      RenderText {#text} at (0,147) size 137x21
+        text run at (0,147) width 137: "This is a paragraph."
+      RenderText {#text} at (0,0) size 0x0
+selection start: position 11 of child 2 {#text} of body
+selection end:   position 1 of child 7 {BR} of body
diff --git a/LayoutTests/platform/qt/editing/selection/selection-applet-expected.checksum b/LayoutTests/platform/qt/editing/selection/selection-applet-expected.checksum
new file mode 100644
index 0000000..848eaf4
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/selection-applet-expected.checksum
@@ -0,0 +1 @@
+4385e41da94d3409c7aae2c5e0d08d26
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/selection-applet-expected.png b/LayoutTests/platform/qt/editing/selection/selection-applet-expected.png
new file mode 100644
index 0000000..2cae47c
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/selection-applet-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/selection-invalid-offset-expected.checksum b/LayoutTests/platform/qt/editing/selection/selection-invalid-offset-expected.checksum
new file mode 100644
index 0000000..ebced88
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/selection-invalid-offset-expected.checksum
@@ -0,0 +1 @@
+99a10d16d2f9695dc35440532834ab4a
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/selection-invalid-offset-expected.png b/LayoutTests/platform/qt/editing/selection/selection-invalid-offset-expected.png
new file mode 100644
index 0000000..636c8ee
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/selection-invalid-offset-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/selection-modify-crash-expected.checksum b/LayoutTests/platform/qt/editing/selection/selection-modify-crash-expected.checksum
new file mode 100644
index 0000000..2a414cd
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/selection-modify-crash-expected.checksum
@@ -0,0 +1 @@
+04bd9a1abf8d4a6aad5b16bac31781e5
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/selection-modify-crash-expected.png b/LayoutTests/platform/qt/editing/selection/selection-modify-crash-expected.png
new file mode 100644
index 0000000..4cc18f4
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/selection-modify-crash-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/setBaseAndExtent-revert-selection-expected.checksum b/LayoutTests/platform/qt/editing/selection/setBaseAndExtent-revert-selection-expected.checksum
new file mode 100644
index 0000000..53ab178
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/setBaseAndExtent-revert-selection-expected.checksum
@@ -0,0 +1 @@
+db15cf375be12535c3dd9fb8ede86b20
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/setBaseAndExtent-revert-selection-expected.png b/LayoutTests/platform/qt/editing/selection/setBaseAndExtent-revert-selection-expected.png
new file mode 100644
index 0000000..d7c0e82
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/setBaseAndExtent-revert-selection-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/shrink-selection-after-shift-pagedown-expected.checksum b/LayoutTests/platform/qt/editing/selection/shrink-selection-after-shift-pagedown-expected.checksum
new file mode 100644
index 0000000..573abdd
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/shrink-selection-after-shift-pagedown-expected.checksum
@@ -0,0 +1 @@
+dc42a0e3797ee8bdeb75eb2fa69dfe51
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/shrink-selection-after-shift-pagedown-expected.png b/LayoutTests/platform/qt/editing/selection/shrink-selection-after-shift-pagedown-expected.png
new file mode 100644
index 0000000..cac8ad2
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/shrink-selection-after-shift-pagedown-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/skip-non-editable-1-expected.checksum b/LayoutTests/platform/qt/editing/selection/skip-non-editable-1-expected.checksum
new file mode 100644
index 0000000..dd02db3
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/skip-non-editable-1-expected.checksum
@@ -0,0 +1 @@
+a2cd6180e84edbc670a640e554c85b2c
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/skip-non-editable-1-expected.png b/LayoutTests/platform/qt/editing/selection/skip-non-editable-1-expected.png
new file mode 100644
index 0000000..005fff0
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/skip-non-editable-1-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/skip-non-editable-2-expected.checksum b/LayoutTests/platform/qt/editing/selection/skip-non-editable-2-expected.checksum
new file mode 100644
index 0000000..296193e
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/skip-non-editable-2-expected.checksum
@@ -0,0 +1 @@
+67d3b656f8426291845efe3004e0a077
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/skip-non-editable-2-expected.png b/LayoutTests/platform/qt/editing/selection/skip-non-editable-2-expected.png
new file mode 100644
index 0000000..c8f850a
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/skip-non-editable-2-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/table-caret-1-expected.checksum b/LayoutTests/platform/qt/editing/selection/table-caret-1-expected.checksum
new file mode 100644
index 0000000..c1855fb
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/table-caret-1-expected.checksum
@@ -0,0 +1 @@
+d8598a11646dbde486a93d6de0ff8b8e
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/table-caret-1-expected.png b/LayoutTests/platform/qt/editing/selection/table-caret-1-expected.png
new file mode 100644
index 0000000..962d962
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/table-caret-1-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/table-caret-1-expected.txt b/LayoutTests/platform/qt/editing/selection/table-caret-1-expected.txt
index 072b479..e5688a4 100644
--- a/LayoutTests/platform/qt/editing/selection/table-caret-1-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/table-caret-1-expected.txt
@@ -1,31 +1,33 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 3 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 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 {P} at (0,0) size 784x19
-        RenderText {#text} at (0,0) size 388x19
-          text run at (0,0) width 388: "This tests the caret position for the caret before a block table."
-      RenderBlock {DIV} at (0,33) size 784x117
-        RenderBlock (anonymous) at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 20x19
-            text run at (0,0) width 20: "foo"
-        RenderTable {TABLE} at (0,19) size 53x79 [border: (1px solid #999999)]
-          RenderTableSection {TBODY} at (1,1) size 51x77
-            RenderTableRow {TR} at (0,2) size 51x23
-              RenderTableCell {TD} at (2,2) size 47x23 [border: (1px solid #999999)] [r=0 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 22x19
-                  text run at (2,2) width 22: "this"
-            RenderTableRow {TR} at (0,27) size 51x23
-              RenderTableCell {TD} at (2,27) size 47x23 [border: (1px solid #999999)] [r=1 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 10x19
+      RenderBlock {P} at (0,0) size 784x21
+        RenderText {#text} at (0,0) size 411x21
+          text run at (0,0) width 411: "This tests the caret position for the caret before a block table."
+      RenderBlock {DIV} at (0,37) size 784x127
+        RenderBlock (anonymous) at (0,0) size 784x21
+          RenderText {#text} at (0,0) size 21x21
+            text run at (0,0) width 21: "foo"
+        RenderTable {TABLE} at (0,21) size 55x85 [border: (1px solid #999999)]
+          RenderTableSection {TBODY} at (1,1) size 53x83
+            RenderTableRow {TR} at (0,2) size 53x25
+              RenderTableCell {TD} at (2,2) size 49x25 [border: (1px solid #999999)] [r=0 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 24x21
+                  text run at (2,2) width 24: "this"
+            RenderTableRow {TR} at (0,29) size 53x25
+              RenderTableCell {TD} at (2,29) size 49x25 [border: (1px solid #999999)] [r=1 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 10x21
                   text run at (2,2) width 10: "is"
-            RenderTableRow {TR} at (0,52) size 51x23
-              RenderTableCell {TD} at (2,52) size 47x23 [border: (1px solid #999999)] [r=2 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 43x19
-                  text run at (2,2) width 43: "a table"
-        RenderBlock (anonymous) at (0,98) size 784x19
-          RenderText {#text} at (0,0) size 23x19
-            text run at (0,0) width 23: "baz"
+            RenderTableRow {TR} at (0,56) size 53x25
+              RenderTableCell {TD} at (2,56) size 49x25 [border: (1px solid #999999)] [r=2 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 45x21
+                  text run at (2,2) width 45: "a table"
+        RenderBlock (anonymous) at (0,106) size 784x21
+          RenderText {#text} at (0,0) size 24x21
+            text run at (0,0) width 24: "baz"
 caret: position 0 of child 1 {TABLE} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/table-caret-2-expected.checksum b/LayoutTests/platform/qt/editing/selection/table-caret-2-expected.checksum
new file mode 100644
index 0000000..baaa6f8
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/table-caret-2-expected.checksum
@@ -0,0 +1 @@
+ab0bb484c03efcd1c38bfb476c947901
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/table-caret-2-expected.png b/LayoutTests/platform/qt/editing/selection/table-caret-2-expected.png
new file mode 100644
index 0000000..659bbf6
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/table-caret-2-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/table-caret-2-expected.txt b/LayoutTests/platform/qt/editing/selection/table-caret-2-expected.txt
index 445cae5..137c818 100644
--- a/LayoutTests/platform/qt/editing/selection/table-caret-2-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/table-caret-2-expected.txt
@@ -1,31 +1,33 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 3 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 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 {P} at (0,0) size 784x19
-        RenderText {#text} at (0,0) size 376x19
-          text run at (0,0) width 376: "This tests the caret position for the caret after a block table."
-      RenderBlock {DIV} at (0,33) size 784x117
-        RenderBlock (anonymous) at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 20x19
-            text run at (0,0) width 20: "foo"
-        RenderTable {TABLE} at (0,19) size 53x79 [border: (1px solid #999999)]
-          RenderTableSection {TBODY} at (1,1) size 51x77
-            RenderTableRow {TR} at (0,2) size 51x23
-              RenderTableCell {TD} at (2,2) size 47x23 [border: (1px solid #999999)] [r=0 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 22x19
-                  text run at (2,2) width 22: "this"
-            RenderTableRow {TR} at (0,27) size 51x23
-              RenderTableCell {TD} at (2,27) size 47x23 [border: (1px solid #999999)] [r=1 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 10x19
+      RenderBlock {P} at (0,0) size 784x21
+        RenderText {#text} at (0,0) size 400x21
+          text run at (0,0) width 400: "This tests the caret position for the caret after a block table."
+      RenderBlock {DIV} at (0,37) size 784x127
+        RenderBlock (anonymous) at (0,0) size 784x21
+          RenderText {#text} at (0,0) size 21x21
+            text run at (0,0) width 21: "foo"
+        RenderTable {TABLE} at (0,21) size 55x85 [border: (1px solid #999999)]
+          RenderTableSection {TBODY} at (1,1) size 53x83
+            RenderTableRow {TR} at (0,2) size 53x25
+              RenderTableCell {TD} at (2,2) size 49x25 [border: (1px solid #999999)] [r=0 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 24x21
+                  text run at (2,2) width 24: "this"
+            RenderTableRow {TR} at (0,29) size 53x25
+              RenderTableCell {TD} at (2,29) size 49x25 [border: (1px solid #999999)] [r=1 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 10x21
                   text run at (2,2) width 10: "is"
-            RenderTableRow {TR} at (0,52) size 51x23
-              RenderTableCell {TD} at (2,52) size 47x23 [border: (1px solid #999999)] [r=2 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 43x19
-                  text run at (2,2) width 43: "a table"
-        RenderBlock (anonymous) at (0,98) size 784x19
-          RenderText {#text} at (0,0) size 23x19
-            text run at (0,0) width 23: "baz"
+            RenderTableRow {TR} at (0,56) size 53x25
+              RenderTableCell {TD} at (2,56) size 49x25 [border: (1px solid #999999)] [r=2 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 45x21
+                  text run at (2,2) width 45: "a table"
+        RenderBlock (anonymous) at (0,106) size 784x21
+          RenderText {#text} at (0,0) size 24x21
+            text run at (0,0) width 24: "baz"
 caret: position 1 of child 1 {TABLE} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/table-caret-3-expected.checksum b/LayoutTests/platform/qt/editing/selection/table-caret-3-expected.checksum
new file mode 100644
index 0000000..b9b3edc
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/table-caret-3-expected.checksum
@@ -0,0 +1 @@
+969c17f645da7c32a920f8d6ecdbd702
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/table-caret-3-expected.png b/LayoutTests/platform/qt/editing/selection/table-caret-3-expected.png
new file mode 100644
index 0000000..a79759c
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/table-caret-3-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/table-caret-3-expected.txt b/LayoutTests/platform/qt/editing/selection/table-caret-3-expected.txt
index 897205e..f344f3e 100644
--- a/LayoutTests/platform/qt/editing/selection/table-caret-3-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/table-caret-3-expected.txt
@@ -1,29 +1,31 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 3 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 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 {P} at (0,0) size 784x19
-        RenderText {#text} at (0,0) size 384x19
-          text run at (0,0) width 384: "This tests the caret position for the caret after an inline table."
-      RenderBlock {DIV} at (0,33) size 784x84
-        RenderText {#text} at (0,65) size 20x19
-          text run at (0,65) width 20: "foo"
-        RenderTable {TABLE} at (20,0) size 53x79 [border: (1px solid #999999)]
-          RenderTableSection {TBODY} at (1,1) size 51x77
-            RenderTableRow {TR} at (0,2) size 51x23
-              RenderTableCell {TD} at (2,2) size 47x23 [border: (1px solid #999999)] [r=0 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 22x19
-                  text run at (2,2) width 22: "this"
-            RenderTableRow {TR} at (0,27) size 51x23
-              RenderTableCell {TD} at (2,27) size 47x23 [border: (1px solid #999999)] [r=1 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 10x19
+      RenderBlock {P} at (0,0) size 784x21
+        RenderText {#text} at (0,0) size 409x21
+          text run at (0,0) width 409: "This tests the caret position for the caret after an inline table."
+      RenderBlock {DIV} at (0,37) size 784x90
+        RenderText {#text} at (0,69) size 21x21
+          text run at (0,69) width 21: "foo"
+        RenderTable {TABLE} at (21,0) size 55x85 [border: (1px solid #999999)]
+          RenderTableSection {TBODY} at (1,1) size 53x83
+            RenderTableRow {TR} at (0,2) size 53x25
+              RenderTableCell {TD} at (2,2) size 49x25 [border: (1px solid #999999)] [r=0 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 24x21
+                  text run at (2,2) width 24: "this"
+            RenderTableRow {TR} at (0,29) size 53x25
+              RenderTableCell {TD} at (2,29) size 49x25 [border: (1px solid #999999)] [r=1 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 10x21
                   text run at (2,2) width 10: "is"
-            RenderTableRow {TR} at (0,52) size 51x23
-              RenderTableCell {TD} at (2,52) size 47x23 [border: (1px solid #999999)] [r=2 c=0 rs=1 cs=1]
-                RenderText {#text} at (2,2) size 43x19
-                  text run at (2,2) width 43: "a table"
-        RenderText {#text} at (73,65) size 23x19
-          text run at (73,65) width 23: "baz"
+            RenderTableRow {TR} at (0,56) size 53x25
+              RenderTableCell {TD} at (2,56) size 49x25 [border: (1px solid #999999)] [r=2 c=0 rs=1 cs=1]
+                RenderText {#text} at (2,2) size 45x21
+                  text run at (2,2) width 45: "a table"
+        RenderText {#text} at (76,69) size 24x21
+          text run at (76,69) width 24: "baz"
 caret: position 1 of child 1 {TABLE} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/thai-word-at-document-end-expected.checksum b/LayoutTests/platform/qt/editing/selection/thai-word-at-document-end-expected.checksum
new file mode 100644
index 0000000..0bf6efd
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/thai-word-at-document-end-expected.checksum
@@ -0,0 +1 @@
+8ab159c1f2f3e150007d532c3e86d49b
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/thai-word-at-document-end-expected.png b/LayoutTests/platform/qt/editing/selection/thai-word-at-document-end-expected.png
new file mode 100644
index 0000000..b381645
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/thai-word-at-document-end-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/toString-1-expected.checksum b/LayoutTests/platform/qt/editing/selection/toString-1-expected.checksum
new file mode 100644
index 0000000..260e323
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/toString-1-expected.checksum
@@ -0,0 +1 @@
+da957ab2ebe0e8517ab1d8c3f375629f
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/toString-1-expected.png b/LayoutTests/platform/qt/editing/selection/toString-1-expected.png
new file mode 100644
index 0000000..6ca9d11
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/toString-1-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/toString-expected.checksum b/LayoutTests/platform/qt/editing/selection/toString-expected.checksum
new file mode 100644
index 0000000..7f79811
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/toString-expected.checksum
@@ -0,0 +1 @@
+38cf247628d4d423953edd07eab9f7ca
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/toString-expected.png b/LayoutTests/platform/qt/editing/selection/toString-expected.png
new file mode 100644
index 0000000..feb2775
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/toString-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/triple-click-in-pre-expected.checksum b/LayoutTests/platform/qt/editing/selection/triple-click-in-pre-expected.checksum
new file mode 100644
index 0000000..767de1e
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/triple-click-in-pre-expected.checksum
@@ -0,0 +1 @@
+7ee61afaba8a4575e23ed22de04173e0
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/triple-click-in-pre-expected.png b/LayoutTests/platform/qt/editing/selection/triple-click-in-pre-expected.png
new file mode 100644
index 0000000..1156ce0
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/triple-click-in-pre-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/triple-click-in-pre-expected.txt b/LayoutTests/platform/qt/editing/selection/triple-click-in-pre-expected.txt
new file mode 100644
index 0000000..42b861f
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/triple-click-in-pre-expected.txt
@@ -0,0 +1,33 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 3 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 30 of #text > PRE > DIV > DIV > BODY > HTML > #document to 30 of #text > PRE > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 30 of #text > PRE > DIV > DIV > BODY > HTML > #document to 30 of #text > PRE > DIV > DIV > BODY > HTML > #document toDOMRange:range from 16 of #text > PRE > DIV > DIV > BODY > HTML > #document to 30 of #text > PRE > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 16 of #text > PRE > DIV > DIV > BODY > HTML > #document to 30 of #text > PRE > DIV > DIV > BODY > HTML > #document toDOMRange:range from 16 of #text > PRE > DIV > DIV > BODY > HTML > #document to 30 of #text > PRE > DIV > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+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 {P} at (0,0) size 784x21
+        RenderText {#text} at (0,0) size 721x21
+          text run at (0,0) width 401: "This tests modifying a selection created with a double click. "
+          text run at (401,0) width 320: "The new selection should use word granularity."
+      RenderBlock {P} at (0,37) size 784x63 [color=#008000]
+        RenderText {#text} at (0,0) size 781x63
+          text run at (0,0) width 241: "This test does not run interactively. "
+          text run at (241,0) width 442: "It uses the layoutTestControllers eventSender to do mouse clicks. "
+          text run at (683,0) width 61: "To run it"
+          text run at (0,21) width 630: "manually, triple click on the second line in the box below (anywhere after \"whitespace:pre\"). "
+          text run at (630,21) width 151: "The triple click should"
+          text run at (0,42) width 136: "select the entire line."
+      RenderBlock {DIV} at (0,116) size 784x60
+        RenderBlock {DIV} at (0,0) size 784x60 [border: (1px solid #0000FF)]
+          RenderBlock {PRE} at (1,14) size 782x32
+            RenderText {#text} at (0,0) size 87x32
+              text run at (0,0) width 75: "this text is in"
+              text run at (75,0) width 0: " "
+              text run at (0,16) width 87: "whitespace:pre"
+selection start: position 16 of child 0 {#text} of child 1 {PRE} of child 1 {DIV} of child 5 {DIV} of body
+selection end:   position 30 of child 0 {#text} of child 1 {PRE} of child 1 {DIV} of child 5 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-001-expected.checksum b/LayoutTests/platform/qt/editing/selection/unrendered-001-expected.checksum
new file mode 100644
index 0000000..9f3acf1
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-001-expected.checksum
@@ -0,0 +1 @@
+b232cbee172ef75766727b67d8408632
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-001-expected.png b/LayoutTests/platform/qt/editing/selection/unrendered-001-expected.png
new file mode 100644
index 0000000..2a79a1f
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/unrendered-001-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-001-expected.txt b/LayoutTests/platform/qt/editing/selection/unrendered-001-expected.txt
index 21db629..18e85e0 100644
--- a/LayoutTests/platform/qt/editing/selection/unrendered-001-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-001-expected.txt
@@ -1,13 +1,15 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 4 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
-layer at (0,0) size 820x600
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 820x600
-  RenderBlock {HTML} at (0,0) size 800x600
-    RenderBody {BODY} at (8,64) size 784x472
+layer at (0,0) size 820x584
+  RenderView at (0,0) size 800x584
+layer at (0,0) size 800x584
+  RenderBlock {HTML} at (0,0) size 800x584
+    RenderBody {BODY} at (8,64) size 784x456
       RenderBlock {DIV} at (64,0) size 748x196 [border: (50px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 33x31
-          RenderText {#text} at (74,82) size 33x31
-            text run at (74,82) width 33: "foo"
-        RenderText {#text} at (107,82) size 45x31
-          text run at (107,82) width 45: " baz"
+        RenderInline {SPAN} at (0,0) size 32x32
+          RenderText {#text} at (74,82) size 32x32
+            text run at (74,82) width 32: "foo"
+        RenderText {#text} at (106,82) size 42x32
+          text run at (106,82) width 42: " baz"
 caret: position 3 of child 0 {#text} of child 1 {SPAN} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-002-expected.checksum b/LayoutTests/platform/qt/editing/selection/unrendered-002-expected.checksum
new file mode 100644
index 0000000..e6bf478
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-002-expected.checksum
@@ -0,0 +1 @@
+9825bd5809918ab9f3bf75c7355f83a5
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-002-expected.png b/LayoutTests/platform/qt/editing/selection/unrendered-002-expected.png
new file mode 100644
index 0000000..9dd36ea
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/unrendered-002-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-002-expected.txt b/LayoutTests/platform/qt/editing/selection/unrendered-002-expected.txt
index 933aa3e..b0880b5 100644
--- a/LayoutTests/platform/qt/editing/selection/unrendered-002-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-002-expected.txt
@@ -1,14 +1,16 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 4 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
-layer at (0,0) size 820x600
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 820x600
-  RenderBlock {HTML} at (0,0) size 800x600
-    RenderBody {BODY} at (8,64) size 784x472
+layer at (0,0) size 820x584
+  RenderView at (0,0) size 800x584
+layer at (0,0) size 800x584
+  RenderBlock {HTML} at (0,0) size 800x584
+    RenderBody {BODY} at (8,64) size 784x456
       RenderBlock {DIV} at (64,0) size 748x196 [border: (50px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 33x31
-          RenderText {#text} at (74,82) size 33x31
-            text run at (74,82) width 33: "foo"
-        RenderText {#text} at (107,82) size 45x31
-          text run at (107,82) width 45: " baz"
+        RenderInline {SPAN} at (0,0) size 32x32
+          RenderText {#text} at (74,82) size 32x32
+            text run at (74,82) width 32: "foo"
+        RenderText {#text} at (106,82) size 42x32
+          text run at (106,82) width 42: " baz"
 caret: position 1 of child 3 {#text} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-003-expected.checksum b/LayoutTests/platform/qt/editing/selection/unrendered-003-expected.checksum
new file mode 100644
index 0000000..0d5c2a7
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-003-expected.checksum
@@ -0,0 +1 @@
+b53fb8f04c31291e7b5ed9b040416ffa
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-003-expected.png b/LayoutTests/platform/qt/editing/selection/unrendered-003-expected.png
new file mode 100644
index 0000000..dc954da
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/unrendered-003-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-003-expected.txt b/LayoutTests/platform/qt/editing/selection/unrendered-003-expected.txt
index fa87a31..54f132d 100644
--- a/LayoutTests/platform/qt/editing/selection/unrendered-003-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-003-expected.txt
@@ -1,15 +1,17 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 4 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
-layer at (0,0) size 820x600
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 820x600
-  RenderBlock {HTML} at (0,0) size 800x600
-    RenderBody {BODY} at (8,64) size 784x472
+layer at (0,0) size 820x584
+  RenderView at (0,0) size 800x584
+layer at (0,0) size 800x584
+  RenderBlock {HTML} at (0,0) size 800x584
+    RenderBody {BODY} at (8,64) size 784x456
       RenderBlock {DIV} at (64,0) size 748x196 [border: (50px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 33x31
-          RenderText {#text} at (74,82) size 33x31
-            text run at (74,82) width 33: "foo"
-        RenderText {#text} at (107,82) size 45x31
-          text run at (107,82) width 45: " baz"
+        RenderInline {SPAN} at (0,0) size 32x32
+          RenderText {#text} at (74,82) size 32x32
+            text run at (74,82) width 32: "foo"
+        RenderText {#text} at (106,82) size 42x32
+          text run at (106,82) width 42: " baz"
 selection start: position 0 of child 3 {#text} of child 1 {DIV} of body
 selection end:   position 1 of child 3 {#text} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-004-expected.checksum b/LayoutTests/platform/qt/editing/selection/unrendered-004-expected.checksum
new file mode 100644
index 0000000..9f3acf1
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-004-expected.checksum
@@ -0,0 +1 @@
+b232cbee172ef75766727b67d8408632
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-004-expected.png b/LayoutTests/platform/qt/editing/selection/unrendered-004-expected.png
new file mode 100644
index 0000000..2a79a1f
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/unrendered-004-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-004-expected.txt b/LayoutTests/platform/qt/editing/selection/unrendered-004-expected.txt
index 4b4993a..f6e4fd2 100644
--- a/LayoutTests/platform/qt/editing/selection/unrendered-004-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-004-expected.txt
@@ -1,15 +1,17 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 4 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
-layer at (0,0) size 820x600
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 820x600
-  RenderBlock {HTML} at (0,0) size 800x600
-    RenderBody {BODY} at (8,64) size 784x472
+layer at (0,0) size 820x584
+  RenderView at (0,0) size 800x584
+layer at (0,0) size 800x584
+  RenderBlock {HTML} at (0,0) size 800x584
+    RenderBody {BODY} at (8,64) size 784x456
       RenderBlock {DIV} at (64,0) size 748x196 [border: (50px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 33x31
-          RenderText {#text} at (74,82) size 33x31
-            text run at (74,82) width 33: "foo"
-        RenderText {#text} at (107,82) size 45x31
-          text run at (107,82) width 45: " baz"
+        RenderInline {SPAN} at (0,0) size 32x32
+          RenderText {#text} at (74,82) size 32x32
+            text run at (74,82) width 32: "foo"
+        RenderText {#text} at (106,82) size 42x32
+          text run at (106,82) width 42: " baz"
 caret: position 3 of child 0 {#text} of child 1 {SPAN} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-005-expected.checksum b/LayoutTests/platform/qt/editing/selection/unrendered-005-expected.checksum
new file mode 100644
index 0000000..9f3acf1
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-005-expected.checksum
@@ -0,0 +1 @@
+b232cbee172ef75766727b67d8408632
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-005-expected.png b/LayoutTests/platform/qt/editing/selection/unrendered-005-expected.png
new file mode 100644
index 0000000..2a79a1f
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/unrendered-005-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-005-expected.txt b/LayoutTests/platform/qt/editing/selection/unrendered-005-expected.txt
index 4b4993a..f6e4fd2 100644
--- a/LayoutTests/platform/qt/editing/selection/unrendered-005-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-005-expected.txt
@@ -1,15 +1,17 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 4 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
-layer at (0,0) size 820x600
-  RenderView at (0,0) size 800x600
-layer at (0,0) size 820x600
-  RenderBlock {HTML} at (0,0) size 800x600
-    RenderBody {BODY} at (8,64) size 784x472
+layer at (0,0) size 820x584
+  RenderView at (0,0) size 800x584
+layer at (0,0) size 800x584
+  RenderBlock {HTML} at (0,0) size 800x584
+    RenderBody {BODY} at (8,64) size 784x456
       RenderBlock {DIV} at (64,0) size 748x196 [border: (50px solid #FF0000)]
-        RenderInline {SPAN} at (0,0) size 33x31
-          RenderText {#text} at (74,82) size 33x31
-            text run at (74,82) width 33: "foo"
-        RenderText {#text} at (107,82) size 45x31
-          text run at (107,82) width 45: " baz"
+        RenderInline {SPAN} at (0,0) size 32x32
+          RenderText {#text} at (74,82) size 32x32
+            text run at (74,82) width 32: "foo"
+        RenderText {#text} at (106,82) size 42x32
+          text run at (106,82) width 42: " baz"
 caret: position 3 of child 0 {#text} of child 1 {SPAN} of child 1 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-space-expected.checksum b/LayoutTests/platform/qt/editing/selection/unrendered-space-expected.checksum
new file mode 100644
index 0000000..e595638
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-space-expected.checksum
@@ -0,0 +1 @@
+c0723bc7454b3b1fd9dc3708badfe856
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-space-expected.png b/LayoutTests/platform/qt/editing/selection/unrendered-space-expected.png
new file mode 100644
index 0000000..ca99444
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/unrendered-space-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/unrendered-space-expected.txt b/LayoutTests/platform/qt/editing/selection/unrendered-space-expected.txt
index 8609c5a..fb7fd97 100644
--- a/LayoutTests/platform/qt/editing/selection/unrendered-space-expected.txt
+++ b/LayoutTests/platform/qt/editing/selection/unrendered-space-expected.txt
@@ -1,20 +1,23 @@
+EDITING DELEGATE: shouldBeginEditingInDOMRange:range from 0 of DIV > BODY > HTML > #document to 2 of DIV > BODY > HTML > #document
+EDITING DELEGATE: webViewDidBeginEditing:WebViewDidBeginEditingNotification
 EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
 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 {P} at (0,0) size 784x57
-        RenderText {#text} at (0,0) size 774x57
-          text run at (0,0) width 631: "This tests visible position creation in unrendered space after rendered text, just before a new block. "
-          text run at (631,0) width 143: "The caret should be at"
-          text run at (0,19) width 750: "the end of the line containing 'foo' because we choose to treat all positions in the unrendered space after 'foo' as being"
-          text run at (0,38) width 750: "visually equivalent to the position just after 'foo', and not visually equivalent to the position on the next line, before 'bar'."
-      RenderBlock {DIV} at (0,71) size 784x38
-        RenderBlock (anonymous) at (0,0) size 784x19
-          RenderText {#text} at (0,0) size 20x19
-            text run at (0,0) width 20: "foo"
-        RenderBlock {DIV} at (0,19) size 784x19
-          RenderText {#text} at (0,0) size 21x19
-            text run at (0,0) width 21: "bar"
+      RenderBlock {P} at (0,0) size 784x84
+        RenderText {#text} at (0,0) size 782x84
+          text run at (0,0) width 671: "This tests visible position creation in unrendered space after rendered text, just before a new block. "
+          text run at (671,0) width 65: "The caret"
+          text run at (0,21) width 782: "should be at the end of the line containing 'foo' because we choose to treat all positions in the unrendered space after"
+          text run at (0,42) width 781: "'foo' as being visually equivalent to the position just after 'foo', and not visually equivalent to the position on the next"
+          text run at (0,63) width 115: "line, before 'bar'."
+      RenderBlock {DIV} at (0,100) size 784x42
+        RenderBlock (anonymous) at (0,0) size 784x21
+          RenderText {#text} at (0,0) size 21x21
+            text run at (0,0) width 21: "foo"
+        RenderBlock {DIV} at (0,21) size 784x21
+          RenderText {#text} at (0,0) size 24x21
+            text run at (0,0) width 24: "bar"
 caret: position 3 of child 0 {#text} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/user-drag-element-and-user-select-none-expected.checksum b/LayoutTests/platform/qt/editing/selection/user-drag-element-and-user-select-none-expected.checksum
new file mode 100644
index 0000000..379a3ff
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/user-drag-element-and-user-select-none-expected.checksum
@@ -0,0 +1 @@
+0ca3c0971b2874cd5933f8d0fd7eb4c5
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/user-drag-element-and-user-select-none-expected.png b/LayoutTests/platform/qt/editing/selection/user-drag-element-and-user-select-none-expected.png
new file mode 100644
index 0000000..4d35aab
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/user-drag-element-and-user-select-none-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/word-granularity-expected.checksum b/LayoutTests/platform/qt/editing/selection/word-granularity-expected.checksum
new file mode 100644
index 0000000..15f6f6b
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/word-granularity-expected.checksum
@@ -0,0 +1 @@
+fe6c47cec2a9908c62cffb3039b42b96
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/word-granularity-expected.png b/LayoutTests/platform/qt/editing/selection/word-granularity-expected.png
new file mode 100644
index 0000000..4c457de
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/word-granularity-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/word-granularity-expected.txt b/LayoutTests/platform/qt/editing/selection/word-granularity-expected.txt
new file mode 100644
index 0000000..53987aa
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/word-granularity-expected.txt
@@ -0,0 +1,53 @@
+EDITING DELEGATE: shouldChangeSelectedDOMRange:(null) toDOMRange:range from 15 of #text > DIV > BODY > HTML > #document to 15 of #text > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 15 of #text > DIV > BODY > HTML > #document to 15 of #text > DIV > BODY > HTML > #document toDOMRange:range from 11 of #text > DIV > BODY > HTML > #document to 4 of #text > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+EDITING DELEGATE: shouldChangeSelectedDOMRange:range from 11 of #text > DIV > BODY > HTML > #document to 4 of #text > DIV > BODY > HTML > #document toDOMRange:range from 11 of #text > DIV > BODY > HTML > #document to 4 of #text > DIV > BODY > HTML > #document affinity:NSSelectionAffinityDownstream stillSelecting:FALSE
+EDITING DELEGATE: webViewDidChangeSelection:WebViewDidChangeSelectionNotification
+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 {P} at (0,0) size 784x21
+        RenderText {#text} at (0,0) size 721x21
+          text run at (0,0) width 401: "This tests modifying a selection created with a double click. "
+          text run at (401,0) width 320: "The new selection should use word granularity."
+      RenderBlock {P} at (0,37) size 784x63 [color=#008000]
+        RenderText {#text} at (0,0) size 744x63
+          text run at (0,0) width 241: "This test does not run interactively. "
+          text run at (241,0) width 442: "It uses the layoutTestControllers eventSender to do mouse clicks. "
+          text run at (683,0) width 61: "To run it"
+          text run at (0,21) width 464: "manually, double click on the blue 'g', then drag down to the red 'g'. "
+          text run at (464,21) width 263: "As you drag, watch the selection that is"
+          text run at (0,42) width 405: "created, it should always start and end on word boundaries."
+      RenderBlock {DIV} at (0,116) size 784x126
+        RenderText {#text} at (0,0) size 92x21
+          text run at (0,0) width 92: "This is a para"
+        RenderInline {SPAN} at (0,0) size 8x21 [color=#0000FF]
+          RenderText {#text} at (92,0) size 8x21
+            text run at (92,0) width 8: "g"
+        RenderText {#text} at (100,0) size 37x21
+          text run at (100,0) width 37: "raph."
+        RenderBR {BR} at (137,16) size 0x0
+        RenderText {#text} at (0,21) size 66x21
+          text run at (0,21) width 66: "Some text"
+        RenderBR {BR} at (66,37) size 0x0
+        RenderText {#text} at (0,42) size 66x21
+          text run at (0,42) width 66: "Some text"
+        RenderBR {BR} at (66,58) size 0x0
+        RenderText {#text} at (0,63) size 66x21
+          text run at (0,63) width 66: "Some text"
+        RenderBR {BR} at (66,79) size 0x0
+        RenderText {#text} at (0,84) size 66x21
+          text run at (0,84) width 66: "Some text"
+        RenderBR {BR} at (66,100) size 0x0
+        RenderText {#text} at (0,105) size 92x21
+          text run at (0,105) width 92: "This is a para"
+        RenderInline {SPAN} at (0,0) size 8x21 [color=#FF0000]
+          RenderText {#text} at (92,105) size 8x21
+            text run at (92,105) width 8: "g"
+        RenderText {#text} at (100,105) size 37x21
+          text run at (100,105) width 37: "raph."
+selection start: position 11 of child 0 {#text} of child 5 {DIV} of body
+selection end:   position 4 of child 14 {#text} of child 5 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-1-expected.checksum b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-1-expected.checksum
new file mode 100644
index 0000000..be0ca9c
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-1-expected.checksum
@@ -0,0 +1 @@
+034d1a0e2c46f320799ee7e7f29114d5
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-1-expected.png b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-1-expected.png
new file mode 100644
index 0000000..9d40ded
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-1-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-1-expected.txt b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-1-expected.txt
new file mode 100644
index 0000000..a003513
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-1-expected.txt
@@ -0,0 +1,17 @@
+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 (anonymous) at (0,0) size 784x21
+        RenderInline {SPAN} at (0,0) size 394x21
+          RenderText {#text} at (0,0) size 394x21
+            text run at (0,0) width 394: "This test passes if the caret is at the start of the second line."
+        RenderText {#text} at (0,0) size 0x0
+      RenderBlock {DIV} at (0,21) size 352x102 [border: (1px solid #0000FF)]
+        RenderText {#text} at (1,1) size 12x21
+          text run at (1,1) width 8: "a"
+          text run at (9,1) width 4: " "
+        RenderText {#text} at (1,22) size 344x21
+          text run at (1,22) width 344: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
+caret: position 2 of child 0 {#text} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-2-expected.checksum b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-2-expected.checksum
new file mode 100644
index 0000000..2ae9caa
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-2-expected.checksum
@@ -0,0 +1 @@
+d92779e1384bd4e6154ddd891dc1fe62
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-2-expected.png b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-2-expected.png
new file mode 100644
index 0000000..6da1850
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-2-expected.png differ
diff --git a/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-2-expected.txt b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-2-expected.txt
new file mode 100644
index 0000000..ae71fd6
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-2-expected.txt
@@ -0,0 +1,18 @@
+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 (anonymous) at (0,0) size 784x21
+        RenderInline {SPAN} at (0,0) size 394x21
+          RenderText {#text} at (0,0) size 394x21
+            text run at (0,0) width 394: "This test passes if the caret is at the start of the second line."
+        RenderText {#text} at (0,0) size 0x0
+      RenderBlock {DIV} at (0,21) size 352x102 [border: (1px solid #0000FF)]
+        RenderText {#text} at (1,1) size 12x21
+          text run at (1,1) width 8: "a"
+          text run at (9,1) width 4: " "
+        RenderInline {SPAN} at (0,0) size 344x21 [color=#0000FF]
+          RenderText {#text} at (1,22) size 344x21
+            text run at (1,22) width 344: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
+caret: position 2 of child 0 {#text} of child 2 {DIV} of body
diff --git a/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-3-expected.checksum b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-3-expected.checksum
new file mode 100644
index 0000000..22955f2
--- /dev/null
+++ b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-3-expected.checksum
@@ -0,0 +1 @@
+a2eaec367fec756a0c53a5f0a436a79d
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-3-expected.png b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-3-expected.png
new file mode 100644
index 0000000..793a3f5
Binary files /dev/null and b/LayoutTests/platform/qt/editing/selection/wrapped-line-caret-3-expected.png differ

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list