Sorry, but my previous pull request contained a bug. Unless you set an xRange line graphs do not work any longer.
This pull request fixes that.
BTW: What I did in getMaxLimX() should also be applied to getMaxYLim(). But that would change the behaviour compared to previous versions, which is why I didn't add this change. If you want I can add it, though.