Repaint function should be implemented.