--- /dev/null
+layer at (0,0) size 800x600
+ RenderCanvas 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 784x84 [border: (2px solid #FF0000)]
+ RenderInline {SPAN} at (0,0) size 744x56
+ RenderText {TEXT} at (14,14) size 97x28
+ text run at (14,14) width 97: "in Liberty"
+ RenderInline {I} at (0,0) size 117x28
+ RenderText {TEXT} at (111,14) size 117x28
+ text run at (111,14) width 21: "F "
+ text run at (132,14) width 96: "and seven"
+ RenderText {TEXT} at (228,14) size 63x28
+ text run at (228,14) width 63: " years "
+ RenderInline {B} at (0,0) size 15x28
+ RenderText {TEXT} at (291,14) size 15x28
+ text run at (291,14) width 15: "s "
+ RenderText {TEXT} at (306,14) size 744x56
+ text run at (306,14) width 110: "our fathers "
+ text run at (416,14) width 342: "f upon this continent, a new nation,"
+ text run at (14,42) width 232: "conceived in Liberty, "
+ text run at (246,42) width 386: "and dedicated to the proposition that all"
+ RenderText {TEXT} at (0,0) size 0x0
+selection is CARET:
+start: position 7 of child 3 {TEXT} of child 2 {SPAN} of root {DIV}
+upstream: position 7 of child 3 {TEXT} of child 2 {SPAN} of root {DIV}
+downstream: position 0 of child 1 {TEXT} of child 4 {B} of child 2 {SPAN} of root {DIV}
--- /dev/null
+<html>
+<head>
+
+<style>
+.editing {
+ border: 2px solid red;
+ padding: 12px;
+ font-size: 24px;
+ word-wrap: break-word;
+ -khtml-nbsp-mode: space;
+ -khtml-line-break: after-white-space;
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+ for (i = 0; i < 29; i++)
+ moveSelectionForwardByCharacterCommand();
+ deleteCommand();
+}
+
+</script>
+
+<title>Editing Test</title>
+</head>
+<body>
+<div contenteditable id="root" class="editing">
+<span id="test">in Liberty<i>F and seven</i> years <b> as </b>our fathers f upon this
+continent, a new nation, conceived in Liberty, and dedicated to the
+proposition that all</span>
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
--- /dev/null
+layer at (0,0) size 800x600
+ RenderCanvas 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 784x84 [border: (2px solid #FF0000)]
+ RenderInline {SPAN} at (0,0) size 735x56
+ RenderText {TEXT} at (14,14) size 97x28
+ text run at (14,14) width 97: "in Liberty"
+ RenderInline {I} at (0,0) size 117x28
+ RenderText {TEXT} at (111,14) size 117x28
+ text run at (111,14) width 21: "F "
+ text run at (132,14) width 96: "and seven"
+ RenderText {TEXT} at (228,14) size 63x28
+ text run at (228,14) width 63: " years "
+ RenderInline {B} at (0,0) size 6x28
+ RenderText {TEXT} at (291,14) size 6x28
+ text run at (291,14) width 6: " "
+ RenderText {TEXT} at (297,14) size 735x56
+ text run at (297,14) width 110: "our fathers "
+ text run at (407,14) width 342: "f upon this continent, a new nation,"
+ text run at (14,42) width 232: "conceived in Liberty, "
+ text run at (246,42) width 386: "and dedicated to the proposition that all"
+ RenderText {TEXT} at (0,0) size 0x0
+selection is CARET:
+start: position 7 of child 3 {TEXT} of child 2 {SPAN} of root {DIV}
+upstream: position 7 of child 3 {TEXT} of child 2 {SPAN} of root {DIV}
+downstream: position 0 of child 1 {TEXT} of child 4 {B} of child 2 {SPAN} of root {DIV}
--- /dev/null
+<html>
+<head>
+
+<style>
+.editing {
+ border: 2px solid red;
+ padding: 12px;
+ font-size: 24px;
+ word-wrap: break-word;
+ -khtml-nbsp-mode: space;
+ -khtml-line-break: after-white-space;
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+ for (i = 0; i < 28; i++)
+ moveSelectionForwardByCharacterCommand();
+ for (i = 0; i < 2; i++)
+ extendSelectionForwardByCharacterCommand();
+ deleteCommand();
+}
+
+</script>
+
+<title>Editing Test</title>
+</head>
+<body>
+<div contenteditable id="root" class="editing">
+<span id="test">in Liberty<i>F and seven</i> years <b> as </b>our fathers f upon this
+continent, a new nation, conceived in Liberty, and dedicated to the
+proposition that all</span>
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
--- /dev/null
+layer at (0,0) size 800x600
+ RenderCanvas 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 784x56 [border: (2px solid #FF0000)]
+ RenderInline {SPAN} at (0,0) size 75x28
+ RenderText {TEXT} at (14,14) size 37x28
+ text run at (14,14) width 37: "bar "
+ RenderInline {SPAN} at (0,0) size 6x28
+ RenderText {TEXT} at (51,14) size 6x28
+ text run at (51,14) width 6: " "
+ RenderText {TEXT} at (57,14) size 32x28
+ text run at (57,14) width 32: "foo"
+ RenderText {TEXT} at (0,0) size 0x0
+selection is CARET:
+start: position 4 of child 1 {TEXT} of child 2 {SPAN} of root {DIV}
+upstream: position 4 of child 1 {TEXT} of child 2 {SPAN} of root {DIV}
+downstream: position 0 of child 1 {TEXT} of child 2 {SPAN} of child 2 {SPAN} of root {DIV}
--- /dev/null
+<html>
+<head>
+
+<style>
+.editing {
+ border: 2px solid red;
+ padding: 12px;
+ font-size: 24px;
+ word-wrap: break-word;
+ -khtml-nbsp-mode: space;
+ -khtml-line-break: after-white-space;
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+ for (i = 0; i < 4; i++)
+ moveSelectionForwardByCharacterCommand();
+ for (i = 0; i < 3; i++)
+ extendSelectionForwardByCharacterCommand();
+ deleteCommand();
+}
+
+</script>
+
+<title>Editing Test</title>
+</head>
+<body>
+<div contenteditable id="root" class="editing">
+<span id="test">bar baz<span> </span>foo</span>
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
--- /dev/null
+layer at (0,0) size 800x600
+ RenderCanvas 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 784x56 [border: (2px solid #FF0000)]
+ RenderInline {SPAN} at (0,0) size 87x28
+ RenderText {TEXT} at (14,14) size 37x28
+ text run at (14,14) width 37: "bar "
+ RenderInline {SPAN} at (0,0) size 18x28
+ RenderText {TEXT} at (51,14) size 18x28
+ text run at (51,14) width 18: " "
+ RenderText {TEXT} at (69,14) size 32x28
+ text run at (69,14) width 32: "foo"
+ RenderText {TEXT} at (0,0) size 0x0
+selection is CARET:
+start: position 4 of child 1 {TEXT} of child 2 {SPAN} of root {DIV}
+upstream: position 4 of child 1 {TEXT} of child 2 {SPAN} of root {DIV}
+downstream: position 0 of child 1 {TEXT} of child 2 {SPAN} of child 2 {SPAN} of root {DIV}
--- /dev/null
+<html>
+<head>
+
+<style>
+.editing {
+ border: 2px solid red;
+ padding: 12px;
+ font-size: 24px;
+ word-wrap: break-word;
+ -khtml-nbsp-mode: space;
+ -khtml-line-break: after-white-space;
+}
+</style>
+<script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
+
+<script>
+
+function editingTest() {
+ for (i = 0; i < 4; i++)
+ moveSelectionForwardByCharacterCommand();
+ for (i = 0; i < 3; i++)
+ extendSelectionForwardByCharacterCommand();
+ deleteCommand();
+}
+
+</script>
+
+<title>Editing Test</title>
+</head>
+<body>
+<div contenteditable id="root" class="editing">
+<span id="test">bar baz<span> </span>foo</span>
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
--- /dev/null
+layer at (0,0) size 800x600
+ RenderCanvas 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 784x140 [border: (2px solid #FF0000)]
+ RenderInline {SPAN} at (0,0) size 0x0
+ RenderText {TEXT} at (0,0) size 0x0
+ RenderText {TEXT} at (14,14) size 732x112
+ text run at (14,14) width 696: "xxxx x xx xxxx xxxxxx xxxxx xxxxxx xxx xx xxxx xxx xxx xx x xxxxx"
+ text run at (14,42) width 732: "xxxxxxxxxxxx xxxxxxxx xxx xxxx xxxxx xx xxx xxxx xxxx xxxxx xxxxxx"
+ text run at (14,70) width 714: "xxx xx xxxx xxx xxx xx xxxxxx xxxxx xxxxxx xxx xx xxxx xxx xxx xx x"
+ text run at (14,98) width 360: "xxxxx xxxxxxxxxxxx xxxxxxxx xxx "
+selection is CARET:
+start: position 233 of child 4 {TEXT} of root {DIV}
+upstream: position 233 of child 4 {TEXT} of root {DIV}
+downstream: position 233 of child 4 {TEXT} of root {DIV}
--- /dev/null
+<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 typeWord(n) {
+ for (i = 0; i < n; i++)
+ typeCharacterCommand();
+ typeCharacterCommand(' ');
+}
+
+function editingTest() {
+ typeWord(4);
+ typeWord(1);
+ typeWord(2);
+ typeWord(4);
+ typeWord(6);
+ typeWord(5);
+ typeWord(6);
+ typeWord(3);
+ typeWord(2);
+ typeWord(4);
+ typeWord(3);
+ typeWord(3);
+ typeWord(2);
+ typeWord(1);
+ typeWord(5);
+ typeWord(12);
+ typeWord(8);
+ typeWord(3);
+ typeWord(4);
+ typeWord(5);
+ typeWord(2);
+ typeWord(3);
+ typeWord(4);
+ typeWord(4);
+ typeWord(5);
+ typeWord(6);
+ typeWord(3);
+ typeWord(2);
+ typeWord(4);
+ typeWord(3);
+ typeWord(3);
+ typeWord(2);
+ typeWord(6);
+ typeWord(5);
+ typeWord(6);
+ typeWord(3);
+ typeWord(2);
+ typeWord(4);
+ typeWord(3);
+ typeWord(3);
+ typeWord(2);
+ typeWord(1);
+ typeWord(5);
+ typeWord(12);
+ typeWord(8);
+ typeWord(3);
+}
+
+</script>
+
+<title>Editing Test</title>
+</head>
+<body>
+<div contenteditable id="root" class="editing">
+<span id="test"></span>
+</div>
+
+<script>
+runEditingTest();
+</script>
+
+</body>
+</html>
+2004-10-25 Ken Kocienda <kocienda@apple.com>
+
+ Reviewed by me
+
+ Added some more editing layout tests.
+
+ * layout-tests/editing/deleting/delete-ws-fixup-001-expected.txt: Added.
+ * layout-tests/editing/deleting/delete-ws-fixup-001.html: Added.
+ * layout-tests/editing/deleting/delete-ws-fixup-002-expected.txt: Added.
+ * layout-tests/editing/deleting/delete-ws-fixup-002.html: Added.
+ * layout-tests/editing/deleting/delete-ws-fixup-003-expected.txt: Added.
+ * layout-tests/editing/deleting/delete-ws-fixup-003.html: Added.
+ * layout-tests/editing/deleting/delete-ws-fixup-004-expected.txt: Added.
+ * layout-tests/editing/deleting/delete-ws-fixup-004.html: Added.
+ * layout-tests/editing/inserting/typing-003-expected.txt: Added.
+ * layout-tests/editing/inserting/typing-003.html: Added.
+
2004-10-25 Ken Kocienda <kocienda@apple.com>
Reviewed by John