Im having a simple JFrame which draws a background color. But when i resize the window, the background color is somehow lagging, as you can see in the screenshot. Is there a way to prevent this issue?
public class ToolBarTest extends JFrame{
public ToolBarTest(){
getContentPane().setBackground(new Color(221,221,221));
setSize(400,250);
setTitle("Hello");
setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
}
public static void main(String ... args){
new ToolBarTest().setVisible(true);
}
}
SOLUTION:
Remove JVM and JDK 7 and reinstall java 6.
Conclusion: dont use java 7 on mac os. (?)