upload tizen1.0 source
[framework/web/webkit-efl.git] / LayoutTests / editing / execCommand / 16049.html
1 <div id="description1">This tests to see if BackColor can be performed on a caret selection. The text typed afterword should have the new background color.</div>
2 <div id="edit1" contentEditable="true"></div>
3
4 <div id="description2">This tests to see if ForeColor can be performed in a plaintext-only region. The text typed afterword should not have the requested color.</div>
5 <div id="edit2" contentEditable="plaintext-only"></div>
6
7 <script>
8 if (window.layoutTestController)
9     window.layoutTestController.dumpAsText();
10
11 edit1 = document.getElementById("edit1");
12 edit1.focus();
13 document.execCommand("BackColor", false, "#00F");
14 document.execCommand("InsertText", false, "Blue");
15
16 edit2 = document.getElementById("edit2");
17 edit2.focus();
18 document.execCommand("ForeColor", false, "#00F");
19 document.execCommand("InsertText", false, "Black");
20
21 if (window.layoutTestController)
22     document.body.innerText = document.getElementById("description1").innerText + "\n" + edit1.innerHTML + "\n\n" +
23                               document.getElementById("description2").innerText + "\n" + edit2.innerHTML;
24 </script>