| Summary: | FormDialog calculates TableViewer's initial width incorrectly | ||
|---|---|---|---|
| Product: | [RT] RAP | Reporter: | Setya Nugdjaja <jsetya> |
| Component: | JFace | Assignee: | Project Inbox <rap-inbox> |
| Status: | RESOLVED WONTFIX | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | ||
| Version: | 1.3 | ||
| Target Milestone: | --- | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | |||
After spending too much time on it, trying to find the reason/fix, there is still no progress. I will close it as WONTFIX. Setya, if you can provide some insides/fix/patch please reopen the bug. Hi, (In reply to comment #1) > After spending too much time on it, trying to find the reason/fix, there is > still no progress. I will close it as WONTFIX. Setya, if you can provide some > insides/fix/patch please reopen the bug. I'll try to help as soon as I have time to delve deep into this problem. In the meantime maybe the rest of the team can also investigate this ? Regards, Setya Setya, with the adoption of Forms 3.6 ( see bug 303731 ), we activated a scrollbars related code in SharedScrolledComposite#reflow(boolean). Can you check if the problem is fixed? |
Hi all, When laying out TableViewer on FormDialog, a horizontal scrollbar is always drawn on 1st display. It seems that FormDialog doesn't compute the TableViewer's initial width correctly. The following is the snippet to reproduce the problem: ... FormDialog dialog = new FormDialog(parent.getDisplay().getActiveShell()) { @Override protected void createFormContent(IManagedForm form) { Composite parent = form.getForm().getBody(); parent.setLayout(GridLayoutFactory.fillDefaults().create()); Composite container = new Composite(parent,SWT.None); TableColumnLayout layout = new TableColumnLayout(); container.setLayout(layout); container.setLayoutData(GridDataFactory.fillDefaults().grab(true, true).create()); TableViewer tableViewer = new TableViewer(new Table(container, SWT.VIRTUAL)); tableViewer.getTable().setHeaderVisible(true); TableViewerColumn col = new TableViewerColumn(tableViewer, SWT.NULL); col.getColumn().setText("Field 1"); layout.setColumnData(col.getColumn(), new ColumnWeightData(100)); } @Override protected Point getInitialSize(){return new Point(500,400);} }; dialog.open(); ... I've tried above snippet on RCP and it worked fine. Regards, Setya