blob: 7548b3b71aee64e0d14354db1beea94f2622f4a1 [file] [log] [blame]
<!DOCTYPE HTML>
<script src="../../resources/ahem.js"></script>
<script>
function highlightRange(id, start, end, active) {
var range = document.createRange();
var elem = document.getElementById(id).firstChild;
range.setStart(elem, start);
range.setEnd(elem, end);
window.internals.addTextMatchMarker(range, active);
window.internals.setMarkedTextMatchesAreHighlighted(document, true);
}
function highlightTest() {
highlightRange('1', 2, 5, true);
}
</script>
<body onload="highlightTest()">
Test for crbug.com/512354
<p>Find In Page: The below text "ndM" from findMe should be highlighted as orange and painted as black</p>
<span id="1" style="font-family: Ahem; font-size: 20px; color:#FF9632">findMe</span>
</body>