blob: 29787339034b80f14b87a8e0917a870f75322bf2 [file] [log] [blame]
<span>This test passes if the caret is at the start of the second line.</span>
<div id="edit" contentEditable="true" style="width: 350px; height: 100px; border: 1px solid blue;">a&nbsp;<span style=color:blue;">xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx</span></div>
<script>
var edit = document.getElementById("edit");
window.getSelection().setPosition(edit.firstChild, 2);
</script>