I am using zest to create plugin that show graph. I am trying to create button that refresh the plugin. The button is working, and I see the graph in the view also. But, the button is taking a lot of space in the view, and limit the place for the graph.I want that the button want limit the graph place.. How can I fix it? Thanks]
public void createPartControl(Composite parent) {
//create refresh button
Composite container = new Composite(parent, SWT.NONE);
container.setLayout(new GridLayout(1, false));
Button btnMybutton = new Button(container, SWT.PUSH);
btnMybutton.setBounds(0, 10, 75, 25);
btnMybutton.setText("Refresh Graph");
btnMybutton.addSelectionListener(new SelectionListener() {
@Override
public void widgetSelected(SelectionEvent e) {
init();
}
@Override
public void widgetDefaultSelected(SelectionEvent e) {
// TODO Auto-generated method stub
}
});
// Graph will hold all other objects
graph = new Graph(parent, SWT.NONE);
}