I have code with null
panel:
JPanel thePanel = new JPanel();
thePanel.setLayout(null);
I used setBounds(x, y, width, heigth)
, for example here:
label2.setBounds(150, 220, 459, 311);
I read that this is not a good practice, can you tell me why?
Is it only because when you want to add something between one component and another you have to set them positions again and again or is it something else?