blob: 246db46ecb04ed8270a10c355bd92dd59a6da252 [file] [log] [blame]
<!DOCTYPE html>
<style>
#target {
text-decoration: underline;
}
</style>
<p id=target>This text should have under-positioned underline.</p>
<script>
if (window.testRunner)
testRunner.waitUntilDone();
window.onload = function () {
document.body.offsetTop; /* force layout */
/* Theoretically setting style can reproduce the issue, but neither setting
immediately nor requestAnimationFrame() work, so use setTimeout(). */
setTimeout(function () {
target.style.textUnderlinePosition = 'under';
if (window.testRunner)
testRunner.notifyDone();
}, 10);
};
</script>