How can I specify the location on JFrame that a component (JLabel specifically) is placed? I created a JFrame object and added a JLabel and a JList to the frame but both objects are being placed on top of each other. I have tried using
label.setBounds(10,10,10,10);
list.setBounds(20,20,100,100);
and
label.setLocation(10,10);
list.setLocation(10, 50);
Neither of these are working. Any help is appreciated! Thanks.