View Javadoc

1   /*
2    * Created on Apr 29, 2005
3    *
4    * TODO To change the template for this generated file go to
5    * Window - Preferences - Java - Code Style - Code Templates
6    */
7   package yawn.ui.gui;
8   
9   /***
10   * @author marti
11   *
12   * TODO To change the template for this generated type comment go to
13   * Window - Preferences - Java - Code Style - Code Templates
14   */
15  public class ExperimentCreator {
16  
17  	private org.eclipse.swt.widgets.Shell sShell = null;
18  
19  	public static void main(String[] args) {
20  		/* Before this is run, be sure to set up the following in the launch configuration 
21  		 * (Arguments->VM Arguments) for the correct SWT library path. 
22  		 * The following is a windows example:
23  		 * -Djava.library.path="installation_directory\plugins\org.eclipse.swt.win32_3.0.0\os\win32\x86"
24  		 */
25  		org.eclipse.swt.widgets.Display display = org.eclipse.swt.widgets.Display.getDefault();		
26  		ExperimentCreator thisClass = new ExperimentCreator();
27  		thisClass.createSShell() ;
28  		thisClass.sShell.open();
29  		
30  		while (!thisClass.sShell.isDisposed()) {
31  			if (!display.readAndDispatch()) display.sleep ();
32  		}
33  		display.dispose();		
34  	}
35  	/***
36  	 * This method initializes sShell
37  	 */
38  	private void createSShell() {
39  		sShell = new org.eclipse.swt.widgets.Shell();		   
40  		sShell.setSize(new org.eclipse.swt.graphics.Point(300,200));
41  		sShell.setText("Shell");
42  	}
43  }