Drawing code tidy and fixes for when there are no tracks to draw.