3 <title>Editing Test (Skipping a virama sign)
</title>
4 <meta http-equiv=
"Content-Type" content=
"text/html; charset=UTF-8"/>
5 <script src=
"../editing.js" language=
"javascript" type=
"text/javascript"></script>
6 <script language=
"javascript" type=
"text/javascript">
8 var li
= document
.createElement("li");
9 li
.appendChild(document
.createTextNode(str
));
10 var console
= document
.getElementById("console");
11 console
.appendChild(li
);
13 function sendBackwardDeleteKey() {
14 if (window
.eventSender
)
15 eventSender
.keyDown("backspace", null);
17 function editingTest() {
18 if (window
.testRunner
)
19 testRunner
.dumpAsText();
20 var testarea
= document
.getElementById("test");
22 typeCharacterCommand(String
.fromCharCode(0x0915));
23 typeCharacterCommand(String
.fromCharCode(0x094D));
24 typeCharacterCommand(String
.fromCharCode(0x0937));
25 moveSelectionBackwardByCharacterCommand();
26 sendBackwardDeleteKey();
27 var expected_result
= "\u0915\u094D\u0937";
28 if (testarea
.textContent
== expected_result
)
31 log("Failed. Actual: \"" + testarea
.textContent
+ "\", Expected: \"" + expected_result
+ "\".");
36 <p>This test tests whether or not we can prevent a cursor from moving after a virama sign.
</p>
37 <p>If this test succeeds, you can see a string
"succeeded" below.
</p>
38 <div contenteditable
id=
"test"></div>
39 <ul id=
"console"></ul>
40 <script language=
"javascript" type=
"text/javascript">