Summary: | Tree widget vertical scrollbar is not recomputed sometimes | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | [Eclipse Project] Platform | Reporter: | Olivier Thomann <Olivier_Thomann> | ||||||
Component: | SWT | Assignee: | Steve Northover <steve_northover> | ||||||
Status: | NEW --- | QA Contact: | |||||||
Severity: | normal | ||||||||
Priority: | P3 | ||||||||
Version: | 3.3 | ||||||||
Target Milestone: | --- | ||||||||
Hardware: | PC | ||||||||
OS: | Windows XP | ||||||||
Whiteboard: | |||||||||
Attachments: |
|
Description
Olivier Thomann
2007-05-11 12:37:27 EDT
Created attachment 66902 [details]
First screenshot
Created attachment 66903 [details]
Second screenshot
Here is some test code that shows the problem: import org.eclipse.swt.*; import org.eclipse.swt.layout.*; import org.eclipse.swt.widgets.*; public class PR_186599 { static final int COUNT = 1000; public static void main(String[] args) { Display display = new Display(); Shell shell = new Shell(display); shell.setLayout(new RowLayout()); final Tree tree = new Tree(shell, SWT.NONE | SWT.VIRTUAL); tree.setLayoutData (new RowData (100, 200)); tree.addListener(SWT.SetData, new Listener() { public void handleEvent(Event event) { TreeItem item = (TreeItem) event.item; item.setText("Item " + event.index); if (event.index == tree.getItemCount () - 1) { item.setText("A very long item that will need to scroll"); } } }); tree.setItemCount(COUNT); shell.pack(); shell.open(); while (!shell.isDisposed()) { if (!display.readAndDispatch()) display.sleep(); } display.dispose(); } } Note that if you click on the line down arrow in the scroll bar, you can scroll to the last item but you cannot drag. Is this the behavior you are seeing? What I am seeing is a little worse than that :-). When I clicked on the last item, I still cannot see it completely. Maybe this is due to the two columns. This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. |