Creating a simple JFace ApplicationWindow

Make sure your classpath and library path includes the correct SWT and JFace libraries.

In my case:

   org.eclipse.ui_2.0.1/workbench.jar
   org.eclipse.swt.win32_2.0.1/ws/win32/swt.jar
   org.eclipse.core.runtime_2.0.1/runtime.jar

Main.java:

import org.eclipse.jface.window.*;
import org.eclipse.swt.widgets.*;
import org.eclipse.swt.*;
 
public class Main extends ApplicationWindow {
   public Main(Shell parent) {
      super(parent);
      setBlockOnOpen(true);
   }
   
   public static void main(String []args) {
      Display display = new Display();
      Shell shell = new Shell(display);
      
      Main main = new Main(shell);
      main.open();
   }
}