I have built a drawing app based on the code under. When you draw a straight line these interruptions happen as shown in the picture. I assigned random colors to each new line,