Community
Participate
Working Groups
Build Identifier: 20100917-0705 Hiding a column using a Tree widget by setting one or more columns to size 0 removes the column (including header), but data from all hidden column(s) are displayed and concatenated together in the last column of the table (the one without a header). I tested using the Table widget and the same code works as expected. I modified and attached the workbench demo application DemoTreeViewPart view to illustrate this behavior. Replace the DemoTreeViewPart.java file with the attached version and launch the Workbench Demo Application. Expand all child nodes for any of the tree views (View V probably the best) and enlarge the view so you can see all 4 columns displayed. Then right click on any table cell and deselect the check Marked Column 3. This results in column 3 being hidden and notice the data is still displayed. Repeat steps and hid column 4 and you will see that column 4 is hidden but the last column in the tree contains data from column 3 & column 4. Reproducible: Always Steps to Reproduce: 1. Create a view container a TreeViewer containing 3 or more columns 2. Set the size of one or more columns to 0 3. Observe that the data is still displayed in last column
Created attachment 180507 [details] Workbench Demo Patch Test Case Replace the DemoTreeViewPart.java file in the RAP Workbench Demo application with the attached file, then launch the Workbench Demo Application. Expand all child nodes for any of the tree views (View V probably the best) and enlarge the view so you can see all 4 columns displayed. Then right click on any table cell and deselect the check Marked Column 3. This results in column 3 being hidden and notice the data is still displayed. Repeat steps and hid column 4 and you will see that column 4 is hidden but the last column in the tree contains data from column 3 & column 4.
Created attachment 180508 [details] Screen shots showing display bug
This issue can be reproduced with Controls Demo -> Tree Tab. If you resize the column to a very small width ( in the example above it is set to 0 to completely hide the column ), but the size that is less than the item left padding provoke the bug too.
This is an issue of server-side layouting. A related bug can be seen with any image in a column except the first: It will not be cut-off if the column is to small to show it.
Fixed in CVS HEAD in Tree.java. Also added and refactored a number of tests for Tree and TreeItem.
*** Bug 328665 has been marked as a duplicate of this bug. ***