Bug 517775 - Wrong rendering of Toolbar in E4 PartStack
Summary: Wrong rendering of Toolbar in E4 PartStack
Status: CLOSED DUPLICATE of bug 471313
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.6   Edit
Hardware: PC Windows NT
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-06-03 17:43 EDT by Patrik Suzzi CLA
Modified: 2020-06-10 09:25 EDT (History)
1 user (show)

See Also:


Attachments
image displaying the rendering problem (23.68 KB, image/png)
2017-06-03 17:43 EDT, Patrik Suzzi CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Patrik Suzzi CLA 2017-06-03 17:43:55 EDT
Created attachment 268739 [details]
image displaying the rendering problem

During the development of a Demo, I realized the part stack renderer does a bad rendering for Part tool controls.
Comment 1 Patrik Suzzi CLA 2017-06-04 05:28:00 EDT
Update: this is a refresh problem, and there is a workaround, which consists in requesting redraw to the parent container. 

Below, you can see the workaround in action

@PostConstruct
public void createControls(Composite parent) {
	this.shell = parent.getShell();		
	parent.getParent().setRedraw(true); // <-- WORKAROUND !
	parent.setLayout(new FillLayout(SWT.HORIZONTAL));
	composite = new Composite(parent, SWT.NONE);
	GridLayout gl_composite = new GridLayout(2, false);
	composite.setLayout(gl_composite);
	
	btnNewTransaction = new Button(composite, SWT.NONE);
	btnNewTransaction.setText("New transaction");
	
	comboViewer = new ComboViewer(composite, SWT.NONE);
	combo = comboViewer.getCombo();
	combo.setItems(new String[] {"Deposit", "Withdrawal", "Charge", "Transfer"});
	combo.select(0);
}
Comment 2 Rolf Theunissen CLA 2020-06-10 09:25:23 EDT

*** This bug has been marked as a duplicate of bug 471313 ***