After updating the interface, you need to repaint the whole thing so that the changes are visible.
how do i repaint everything?
@ blazedaces
this is the whole code:
public void showTaems(Taems t) {
JFrame frame;
taemsFrame = new JFrame("Taems");
taemsFrame.setSize(INITIAL_WIDTH, INITIAL_HEIGHT);
Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
taemsFrame.setSize(screenSize.width, (int)(screenSize.height * .95));
taemsFrame.setLocation(screenSize.width/2 - INITIAL_WIDTH/2,
screenSize.height/2 - INITIAL_HEIGHT/2);
taemsFrame.setLocation(0, 0);
taemsFrame.setDefaultCloseOperation(JFrame.DISPOSE _ON_CLOSE);
taemsFrame.getContentPane().add(t, BorderLayout.CENTER);
//AR taemsFrame.setBackground(Color.white);
taemsFrame.setBackground(Color.green);
taemsFrame.setVisible(true);
taemsFrame.setFont(new Font("Palatino", Font.BOLD, 16));
//Jayasri 06/15
taemsFrame.setResizable(true);
Container c = taemsFrame.getContentPane();
c.setBackground(Color.white);
c.setFont(new Font("Palatino", Font.BOLD, 16));
t.setBackground(Color.black);
t.setForeground(Color.red);
taemsFrame.show();
}