renWin.addWindowSetObserver(new Observer() {
addWindowSetObserver(new Observer() {
  public ImagePlaneWidget(String path) {    setLayout(new BorderLayout());    renWin = new vtkCanvas();    // attach observer to set the render window size after    // the render window is created...    renWin.addWindowSetObserver(new Observer() {        public void update(Observable o, Object arg) {          renWin.setSize(width, height);        }      });    add(renWin, BorderLayout.CENTER);    //Start by loading some data.    vtkVolume16Reader v16 = new vtkVolume16Reader();    v16.SetDataDimensions(64, 64);    v16.SetDataByteOrderToLittleEndian();    v16.SetFilePrefix(path);    v16.SetImageRange (1, 93);    v16.SetDataSpacing(3.2, 3.2, 1.5);    v16.Update();    setImageData(v16.GetOutput());    JFrame frame = new JFrame("ImagePlaneWidget Test");    frame.setBounds(10, 10, width, height);    frame.getContentPane().add(this, BorderLayout.CENTER);    frame.setVisible(true);    frame.addWindowListener(new WindowAdapter()       {        public void windowClosing(WindowEvent e) {System.exit(0);}      });  }