I'm using code:
main.setContentPane(new JLabel(new ImageIcon(ImageIO.read(new File("4.jpg")).getScaledInstance(main.getContentPane().getWidth(), main.getContentPane().getHeight(), Image.SCALE_SMOOTH))));
to set the image.problem is,it's not on the full frame
and having 1 more problem when I'm designing GUI in the NetBeans IDE,the picture is overlapping the components.
plz suggest some solution.