add lines without overlaps maintain colors