Fix multiple rendering of bars

* Due to setInterval(tryQtBridge, 1000), for every 1 second, a new
  series point gets added to the graph resulting in a increase in the
  number of bars per tick as time passes by.
Extract out rendering axes part