[dmurray@xxxxxxxxxxxxxxxx: 19991008: Focus Policy]

----- Forwarded message from Don Murray <dmurray@xxxxxxxxxxxxxxxx> -----

This is a problem of mixing lightweight (ie Swing Components) with
heavyweight components (ex: AWT components).  The DisplayImplJ3D.getComponent()
method returns (I believe) an AWT Canvas which is a heavyweight
component.  Heavyweight components will overlay lightweight versions.
The DisplayImplJ2D returns a JPanel which is lightweight.  In previous
discussions of this problem, Bill mentioned that this is a frequent
complaint on the Java3D list.

I ran into this when trying to use Swing InternalFrames and had to
abandon that idea.  So, it is not a VisAD problem per-se, just 
a problem of mixing and matching AWT and Swing components.  There is
a paper on Sun's Swing Connection about this. (I'm at home so don't
have a URL handy).

Note you will also run into this problem if you use Swing menu
components that drop down over 3D panels. For the VisAD spreadsheet,
Curtis got around this by using AWT components for the menus. You could
create AWT Panels instead of JPanels, but that kind of defeats the cross
platform look and feel.

----- End forwarded message -----

Another way to get Swing menu's to work with heavyweight canvases is to
move the canvas to the "right side" and have plenty of lightweight
stuff under the menus on the "left side".

I would also like to discourage people from using Internal Frames. One
has a window manager to manage these things. Internal Frames don't 
map to multiple monitors well either.

bellenot@xxxxxxxxxxxx http://www.math.fsu.edu/~bellenot (850)644-7189 (4053fax)