def __init__(self, parent): QwtPlot.__init__(self, parent) self.variables = [] self.insertLegend(QwtLegend(self), QwtPlot.TopLegend) self.setCanvasBackground(Qt.white) self.magnifier = QwtPlotMagnifier(self.canvas()) self.magnifier.setAxisEnabled(QwtPlot.xBottom, False) self.magnifier.setAxisEnabled(QwtPlot.yLeft, True) self.panner = QwtPlotPanner(self.canvas()) self.panner.setAxisEnabled(QwtPlot.xBottom, False) self.panner.setAxisEnabled(QwtPlot.yLeft, True)