draws a horizontal line from (x1,y) to (x2,y)