Check the J3D FAQ regarding mixing heavy and lightweight components:
http://www.j3d.org/faq/swing.html

>>> [EMAIL PROTECTED] 03/18/02 10:41AM >>>
Canvas3D seems to always keep itself on top, so that drop down menus
(and other GUI components) always fall behind it. Is there any way to
get the Canvas3D to honor the layering of other components?

Here's a piece of my code. The internal frame that the Canvas3D is
placed in works fine, and it's own boundary get's covered by the menu
drop downs, but, not the Canvas3D itself.


public class MainDesktop extends JDesktopPane {

  private MainDesktop() {
    ...
    addViewFrame();
  }

  ...
  private void addViewFrame() {
    JInternalFrame viewFrame = new JInternalFrame();
    viewFrame.setBounds(VIEW_LEFT, VIEW_TOP, VIEW_WIDTH, VIEW_HEIGHT);
    viewFrame.setNormalBounds(viewFrame.getBounds());
    viewFrame.setVisible(true);
    this.add(viewFrame, JLayeredPane.DEFAULT_LAYER);
    // If do the following before viewFrame is added to the
JDesktopPanel,
    //   adding to the JDesktopPanel fails. Cannot load the Canvas3D.
    java.awt.Container cp = viewFrame.getContentPane();
    cp.setLayout(new BorderLayout());
    cp.add(ViewCanvas.getReference(), BorderLayout.CENTER);
   }
  ...
}

==========================================================================To 
unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to