Scrollpane with Textarea doesn't show up. (I have gif running in the background too). I've tried to add it to another frame alone it worked but somehow i can't add it inside the container
static class UserGUI extends JFrame implements ActionListener {
PlaceHolder p1, p2 ,p3 ,p4, p5, p6;
// Components of the Form
private Container c;
private JLabel title;
private JTextArea textarea1;
public UserGUI () throws IOException {
setTitle("User Panel");
setBounds(300, 90, 1000, 1000);
setDefaultCloseOperation(EXIT_ON_CLOSE);
setLocationRelativeTo(null);
setResizable(false);
c = getContentPane();
c.setLayout(null);
textarea1 = new JTextArea();
textarea1.setFont(new Font("Arial", Font.PLAIN, 15));
textarea1.setSize(300, 400);
textarea1.setLocation(500, 100);
textarea1.setLineWrap(true);
textarea1.setEditable(false);
textarea1.setVisible(true);
JScrollPane scroll = new JScrollPane (textarea1);
scroll.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);
scroll.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS);
add(scroll);
c.add(textarea1);
}
}