changeset 1380:0d6d4249cce9

RT-22908: Column width of data rows does not align with header column width
author jgiles
date Fri, 29 Jun 2012 09:40:29 +1200
parents 4484722efef7
children d17e7e409769
files javafx-ui-controls/src/com/sun/javafx/scene/control/skin/NestedTableColumnHeader.java
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/javafx-ui-controls/src/com/sun/javafx/scene/control/skin/NestedTableColumnHeader.java	Fri Jun 29 09:39:54 2012 +1200
+++ b/javafx-ui-controls/src/com/sun/javafx/scene/control/skin/NestedTableColumnHeader.java	Fri Jun 29 09:40:29 2012 +1200
@@ -417,7 +417,7 @@
         for (TableColumnHeader n : getColumnHeaders()) {
             if (! n.isVisible()) continue;
             
-            double prefWidth = n.prefWidth(-1);
+            double prefWidth = snapSize(n.prefWidth(-1));
 //            double prefHeight = n.prefHeight(-1);
 
             // position the column header in the default location...
@@ -453,7 +453,7 @@
         if (getColumns() != null) {
             for (TableColumnHeader c : getColumnHeaders()) {
                 if (c.isVisible()) {
-                    width += c.computePrefWidth(height);
+                    width += snapSize(c.computePrefWidth(height));
                 }
             }
         }