blob: 858b132607d01bfd70eba2191b8dcae55dcd30d9 [file] [log] [blame]
<!DOCTYPE html>
<html>
<head>
<style>
@font-face {
font-family: Ahem;
src: url("../../resources/Ahem.ttf");
}
#test {
font-family: Ahem;
width: 100px;
}
</style>
</head>
<body>
<div id="test" contenteditable="true"></div>
<script>
var testElement = document.getElementById("test");
testElement.focus();
document.execCommand("InsertText", false, "misllHlll"); // The H is a placeholder for the hyphen (had it been automatically inserted).
document.execCommand("InsertText", false, " "); // Trigger spell checker
testElement.blur();
</script>
</body>
</html>