-
5 Dec 2012 8:42 AM #1
Hide columns in a grid break the width for the following columns
Hide columns in a grid break the width for the following columns
Found an issue in GXT 3.0.2b with usage of HeaderGroupConfig (two rows). When I try to hide
a column on a GridView with forceFit set to false, the refresh() method resize all the next columns with the wrong size (all the size of the columns are shifted actually). I attached a patch fixing the issue:
Code:### Eclipse Workspace Patch 1.0 #P GXT3.0 Index: com.sencha.gxt.ui/src/main/java/com/sencha/gxt/widget/core/client/grid/ColumnHeader.java =================================================================== --- com.sencha.gxt.ui/src/main/java/com/sencha/gxt/widget/core/client/grid/ColumnHeader.java (revision 2620) +++ com.sencha.gxt.ui/src/main/java/com/sencha/gxt/widget/core/client/grid/ColumnHeader.java (working copy) @@ -538,6 +538,7 @@ for (int k = mark; k < (mark + colspan); k++) { ColumnConfig<M, ?> c = cm.getColumn(k); if (c.isHidden()) { + mark++; // In the case of a hidden column, we need to increment the marker for the next columns to retrieve the correct width continue; } w += cm.getColumnWidth(k);
Thank you for reporting this bug. We will make it our priority to review this report.


Reply With Quote