fixed behavior of paint line