Fix smarter way to repaint line chart.