<!doctype HTML> | |
<script src="resources/text-based-repaint.js"></script> | |
<div contenteditable id="root" class="editing"></div> | |
<style> | |
* { | |
font-family: Courier New; | |
} | |
</style> | |
<script> | |
onload = function() { | |
// The innerText must be set explicitly, and not with an editing command. | |
root.innerText = "1"; | |
window.getSelection().collapse(root.firstChild, 1); | |
runRepaintAndPixelTest(); | |
}; | |
function repaintTest() { | |
document.execCommand('delete'); | |
} | |
</script> |