bug fix issue 27: https://github.com/timmolter/XChart/issues/27