fixed stuttering by painting JComponent instead of JFrame