title: repaint() Method in Java
body: <p>I am playing around with the Java graphics class a little bit and I was just wondering--when is it necessary to call the method <code>repaint()</code>? I tried commenting it out and it didn't seem to affect my output GUI. I've seen it used a lot in Java GUI code that I've read, though. Would anyone mind explaining when to use it and when not to use it?</p>