2011-04-11 Ryosuke Niwa <rniwa@webkit.org>
[WebKit-https.git] / LayoutTests / editing / unsupported-content / table-type-after.html
1 <html> 
2 <head>
3
4 <style>
5 .editing { 
6     border: 2px solid red; 
7     font-size: 24px; 
8 }
9 .explanation { 
10     border: 4px solid blue; 
11     padding: 16px; 
12     font-size: 18px; 
13     margin-bottom: 10px;
14 }
15 .scenario:first-line { font-weight: bold; font-size: 24px; }
16 .expected:first-line { font-weight: bold; font-size: 24px; }
17 .results { margin-bottom: 10px; border: 2px solid green; font-size: 24px; }
18 </style>
19 <script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
20
21 <script>
22
23 function editingTest() {
24     for (i = 0; i < 10; i++)
25         moveSelectionForwardByLineCommand();
26     moveSelectionForwardByCharacterCommand();
27     for (i = 0; i < 3; i++)
28         typeCharacterCommand("x");
29 }
30
31 </script>
32
33 <title>Editing Test</title> 
34 </head> 
35 <body>
36
37 <div class="explanation">
38 <div class="scenario">
39 Tests: 
40 <br>
41 Our ability to "edit around" content the HTML editing code does not yet handle very well.
42 <br><i>For this test: </i>Test typing after a table.
43 </div>
44 <br>
45 <div class="expected">
46 Expected Results:
47 <br>
48 The content in the red box must exactly match the content in the green box (except for the border color).
49 <br><i>For this test: </i>Typed text should appear after (on the line below) the table.
50 </div>
51 </div>
52
53 <div class="results">
54 <table border="1">
55 <tr>
56 <td>1</td>
57 <td>2</td>
58 <td>3</td>
59 </tr>
60 <tr>
61 <td>4</td>
62 <td>5</td>
63 <td>6</td>
64 </tr>
65 <tr>
66 <td>7</td>
67 <td>8</td>
68 <td>9</td>
69 </tr>
70 </table>
71 xxx
72 </div>
73
74 <div contenteditable id="root" style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space;">
75 <div id="test" class="editing">
76 <table border="1">
77 <tr>
78 <td>1</td>
79 <td>2</td>
80 <td>3</td>
81 </tr>
82 <tr>
83 <td>4</td>
84 <td>5</td>
85 <td>6</td>
86 </tr>
87 <tr>
88 <td>7</td>
89 <td>8</td>
90 <td>9</td>
91 </tr>
92 </table>
93 </div>
94 </div>
95
96 <script>
97 runEditingTest();
98 </script>
99
100 </body>
101 </html>