Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(150)

Unified Diff: LayoutTests/fast/table/table-cell-offset-width.html

Issue 25086004: offsetWidth on a table cell with fixed width is wrong (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: LayoutTests/fast/table/table-cell-offset-width.html
diff --git a/LayoutTests/fast/table/table-cell-offset-width.html b/LayoutTests/fast/table/table-cell-offset-width.html
new file mode 100644
index 0000000000000000000000000000000000000000..0a77d227588c56928b878df62cb0f1b7f51a1596
--- /dev/null
+++ b/LayoutTests/fast/table/table-cell-offset-width.html
@@ -0,0 +1,10 @@
+<table><td style="font: Ahem; width: 10px">FAIL</td></table>
+<script>
+if (window.testRunner)
+ testRunner.dumpAsText();
+// crbug.com/290399 reported that offsetWidth on a table cell
+// would incorrectly return the specified width instead of the layout-expanded width.
+// When this would fail, it would be 12px instead of the 36px 'FAIL' expands to in Ahem.
+var width = document.getElementsByTagName('td')[0].offsetWidth;
+document.body.textContent = (width == 36 ? "PASS" : "FAIL") + " (" + width + "px)";
+</script>
« no previous file with comments | « no previous file | LayoutTests/fast/table/table-cell-offset-width-expected.txt » ('j') | Source/core/rendering/RenderBox.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698