1 <script src="resources/repaint.js" type="text/javascript"></script>
2 <script type="text/javascript">
3 function repaintTest() {
4 document.execCommand("InsertParagraph");
7 <body onload="runRepaintTest();">
8 <p>This tests for a repaint bug. The old caret position should be invalidated when a paragraph separator is inserted.</p>
9 <div contenteditable="true">
11 <div id="div"><br></div>
14 var div = document.getElementById("div");
15 var sel = window.getSelection();
17 sel.setPosition(div, 0);