Hi,

If I try to add JFrame component to the Frame component like

Frame.add(JFrame);

I get the error message "you cannot add window to a container".

Now the question arises, which component I always can add to which?
Speaking about such containers like: 

Panel     JPanel
Frame     JFrame
Window    JWindow
Canvas    JComponent

what are the rules which govern the "addability" of those components?

Can I have in my program the following statements:
Container.add(Container)
JWindow.add(Frame)
Panel.add(Jpanel)
Jpanel.add(Panel),
.......................
Canvas3D.add(JFrame)
........................

and so on with many possible combinations. There are
Swing components, AWT components, Java2D components,
Java3D components, JAI, JMF components, etc. How to
navigate which could be added to which? What are the
rules?

Thank you,

Jacob Nikom


----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to