add repaint code

Signed-off-by: wenpincui <wenpincui224@gmail.com>