Adding JPanels to JFrames based on x-y co-ordinates
I have written a code for adding background image to a JFrame as given below.
My requirement is that, I need to add other JComponents like JTextfields, JTextArea,JButton etc. on to this frame and it should be on top of this image.
JFrame frame = new JFrame();
ImageIcon icon = new ImageIcon("c:\\final.jpg");
JLabel background = new JLabel(icon);
When I maximize or drag and enlarge the JFrame, the JComponents should automatically get aligned with the frame and background. Please help.