Reviewed by me
authorkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 9 Apr 2004 14:41:37 +0000 (14:41 +0000)
committerkocienda <kocienda@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 9 Apr 2004 14:41:37 +0000 (14:41 +0000)
        Added two more layout tests for editing.

        * layout-tests/editing/selection/move-between-blocks-no-001-expected.txt: Added.
        * layout-tests/editing/selection/move-between-blocks-no-001.html: Added.
        * layout-tests/editing/selection/move-between-blocks-yes-001-expected.txt: Added.
        * layout-tests/editing/selection/move-between-blocks-yes-001.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@6342 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/editing/selection/move-between-blocks-no-001-expected.txt [new file with mode: 0644]
LayoutTests/editing/selection/move-between-blocks-no-001.html [new file with mode: 0644]
LayoutTests/editing/selection/move-between-blocks-yes-001-expected.txt [new file with mode: 0644]
LayoutTests/editing/selection/move-between-blocks-yes-001.html [new file with mode: 0644]
WebCore/ChangeLog-2005-08-23

diff --git a/LayoutTests/editing/selection/move-between-blocks-no-001-expected.txt b/LayoutTests/editing/selection/move-between-blocks-no-001-expected.txt
new file mode 100644 (file)
index 0000000..040eef5
--- /dev/null
@@ -0,0 +1,17 @@
+layer at (0,0) size 800x600
+  RenderCanvas at (0,0) size 800x600
+layer at (0,0) size 800x128
+  RenderBlock {HTML} at (0,0) size 800x128
+    RenderBody {BODY} at (8,8) size 784x112
+      RenderBlock {DIV} at (0,0) size 784x56 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 381x28
+          RenderText {TEXT} at (14,14) size 381x28
+            text run at (14,14) width 381: "We hold these truths to be self-evident,"
+        RenderText {TEXT} at (0,0) size 0x0
+      RenderBlock {DIV} at (0,56) size 784x56 [border: (2px solid #FF0000)]
+        RenderText {TEXT} at (14,14) size 318x28
+          text run at (14,14) width 318: "that all men are created equal, ..."
+selection is CARET:
+start:      position 40 of child 1 {TEXT} of child 1 {SPAN} of root {DIV}
+upstream:   position 40 of child 1 {TEXT} of child 1 {SPAN} of root {DIV}
+downstream: position 1 of child 2 {TEXT} of root {DIV}
diff --git a/LayoutTests/editing/selection/move-between-blocks-no-001.html b/LayoutTests/editing/selection/move-between-blocks-no-001.html
new file mode 100644 (file)
index 0000000..02e57a1
--- /dev/null
@@ -0,0 +1,40 @@
+<html> 
+<head>
+
+<style>
+.editing { 
+    border: 2px solid red; 
+    padding: 12px; 
+    font-size: 24px; 
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+    for (i = 0; i < 50; i++) {
+        moveSelectionForwardByCharacterCommand();
+    }
+}
+
+</script>
+
+<title>Editing Test</title> 
+</head> 
+<body>
+<!-- body not contenteditable. treat these two divs like separate widgets.
+     arrowing from one to the other is prevented. -->
+<div contenteditable id="root" class="editing">
+<span id="test">We hold these truths to be self-evident,</span>
+</div>
+<div contenteditable class="editing">
+that all men are created equal, ...
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
diff --git a/LayoutTests/editing/selection/move-between-blocks-yes-001-expected.txt b/LayoutTests/editing/selection/move-between-blocks-yes-001-expected.txt
new file mode 100644 (file)
index 0000000..4b93451
--- /dev/null
@@ -0,0 +1,17 @@
+layer at (0,0) size 800x600
+  RenderCanvas at (0,0) size 800x600
+layer at (0,0) size 800x128
+  RenderBlock {HTML} at (0,0) size 800x128
+    RenderBody {BODY} at (8,8) size 784x112
+      RenderBlock {DIV} at (0,0) size 784x56 [border: (2px solid #FF0000)]
+        RenderInline {SPAN} at (0,0) size 381x28
+          RenderText {TEXT} at (14,14) size 381x28
+            text run at (14,14) width 381: "We hold these truths to be self-evident,"
+        RenderText {TEXT} at (0,0) size 0x0
+      RenderBlock {DIV} at (0,56) size 784x56 [border: (2px solid #FF0000)]
+        RenderText {TEXT} at (14,14) size 318x28
+          text run at (14,14) width 318: "that all men are created equal, ..."
+selection is CARET:
+start:      position 9 of child 1 {TEXT} of child 4 {DIV} of root {BODY}
+upstream:   position 9 of child 1 {TEXT} of child 4 {DIV} of root {BODY}
+downstream: position 9 of child 1 {TEXT} of child 4 {DIV} of root {BODY}
diff --git a/LayoutTests/editing/selection/move-between-blocks-yes-001.html b/LayoutTests/editing/selection/move-between-blocks-yes-001.html
new file mode 100644 (file)
index 0000000..4883e9a
--- /dev/null
@@ -0,0 +1,41 @@
+<html> 
+<head>
+
+<style>
+.editing { 
+    border: 2px solid red; 
+    padding: 12px; 
+    font-size: 24px; 
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+    for (i = 0; i < 50; i++) {
+        moveSelectionForwardByCharacterCommand();
+    }
+}
+
+</script>
+
+<title>Editing Test</title> 
+</head> 
+<body id="root" contenteditable>
+<!-- body is contenteditable. treat these two divs like 
+     different paragraphs in the same widget. arrowing from
+     one to the other is OK. -->
+<div class="editing">
+<span id="test">We hold these truths to be self-evident,</span>
+</div>
+<div class="editing">
+that all men are created equal, ...
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
index 2784451c2a60b202656bde469258c3747bbd7cda..414046b84f9c2cecae044702598accd162f5ba8d 100644 (file)
@@ -1,3 +1,14 @@
+2004-04-09  Ken Kocienda  <kocienda@apple.com>
+
+        Reviewed by me
+        
+        Added two more layout tests for editing.
+
+        * layout-tests/editing/selection/move-between-blocks-no-001-expected.txt: Added.
+        * layout-tests/editing/selection/move-between-blocks-no-001.html: Added.
+        * layout-tests/editing/selection/move-between-blocks-yes-001-expected.txt: Added.
+        * layout-tests/editing/selection/move-between-blocks-yes-001.html: Added.
+
 2004-04-09  Ken Kocienda  <kocienda@apple.com>
 
         Reviewed by Dave