I want to put a WorldWindowGLJPanel
into a Pane, and I want to make it resizable, but I can't, even when I call resize
or setSize
method.
Here's what I'm doing :
wwd = new WorldWindowGLJPanel();
wwd.setPreferredSize(new java.awt.Dimension(300, 300));
wwd.setModel(new BasicModel());
swingNode = new SwingNode();
swingNode.setContent(wwd);
wwdPane = new Pane();
wwdPane.getChildren().add(swingNode);
Then I use this wwdPane
to display World Wind.
I want my world wind panel
to have the size of the pane which contains it, and I want to make this world wind panel
resizable.
I thought about give the size to my world wind panel
of my pane
with a setSize(PaneDimenson)
and then bind the size of my worldwindpanel with my pane , but the setSize
function doesn't work.
EDIT : I found an alternative solution by not using a pane, but directly the swingNode, the resize is now automatic. But if you want to use a pane there's still a problem, and you're force to use a group.