gecko-dev/layout/tables/reftests/dynamic-text-overflow-table-cell.html
2017-03-03 16:14:39 -05:00

20 lines
549 B
HTML

<!DOCTYPE html>
<html class="reftest-wait">
<table style="table-layout: fixed; width: 130px">
<tr>
<td style="overflow: hidden; white-space: nowrap;">
Some long text that cannot possibly fit in 130 px, because it just can't.
</td>
</tr>
</table>
<script>
onload = function() {
var td = document.querySelector("td");
// Make sure layout has happened.
var width = td.offsetWidth;
td.style.textOverflow = "ellipsis";
document.documentElement.className = "";
}
</script>
</html>