Exemplo n.º 1
0
 private void createControlPart(Composite parent) {
   Composite composite = new Composite(parent, SWT.NONE);
   composite.setLayout(ExampleUtil.createGridLayout(1, false, true, false));
   composite.setLayoutData(ExampleUtil.createFillData());
   createButton(composite, "Europe", ExampleData.BROWSER_QUARTERLY_EUROPE).setSelection(true);
   createButton(composite, "North America", ExampleData.BROWSER_QUARTERLY_NORTHAMERICA);
   createButton(composite, "Asia", ExampleData.BROWSER_QUARTERLY_ASIA);
   createButton(composite, "Africa", ExampleData.BROWSER_QUARTERLY_AFRICA);
 }
Exemplo n.º 2
0
 private void createChartPart(Composite parent) {
   Composite composite = new Composite(parent, SWT.NONE);
   composite.setLayoutData(ExampleUtil.createFillData());
   composite.setLayout(ExampleUtil.createGridLayout(1, false, true, true));
   chart = new StreamChart(composite, SWT.BORDER);
   GridData layoutData = new GridData(SWT.FILL, SWT.DEFAULT, true, false);
   layoutData.heightHint = 300;
   chart.setLayoutData(layoutData);
   createItems();
   update();
 }
Exemplo n.º 3
0
 public void createControl(Composite parent) {
   parent.setLayout(ExampleUtil.createMainLayout(2));
   dataSet = ExampleData.BROWSER_QUARTERLY_EUROPE;
   colors = Colors.cat10Colors(parent.getDisplay()).loop();
   createChartPart(parent);
   createControlPart(parent);
 }