this.addWindowListener(new WindowAdapter() { public void windowClosing(WindowEvent winEvent) { doExit(); } });   this.getContentPane().add(new AppPanel(args)); this.pack(); this.setVisible(true);
BranchGroup scene = createSceneGraph(args);   createOffScreenCanvas(onScreenCanvas3D);  univ.addBranchGraph(scene);
    private PrintCanvas3D(String args[]) {	this.setTitle("Canvas3D Print Test");	// Create and initialize menu bar	JPopupMenu.setDefaultLightWeightPopupEnabled(false);	this.setJMenuBar(createMenuBar());	// Handle the close event	this.addWindowListener(new WindowAdapter() {	    public void windowClosing(WindowEvent winEvent) {		doExit();	    }	});	// Add main panel to top-level frame and make it visible	this.getContentPane().add(new AppPanel(args));	this.pack();	this.setVisible(true);    }