[change] disable multicursor by default
This commit is contained in:
parent
1bbb686778
commit
070c32e007
@ -619,7 +619,7 @@ class MainWindow(QMainWindow):
|
|||||||
self.disconnectWFplotEvents()
|
self.disconnectWFplotEvents()
|
||||||
if str(settings.value('pyqtgraphic')) == 'false' or not pg:
|
if str(settings.value('pyqtgraphic')) == 'false' or not pg:
|
||||||
self.pg = False
|
self.pg = False
|
||||||
self.dataPlot = PylotCanvas(parent=self, connect_events=False)
|
self.dataPlot = PylotCanvas(parent=self, connect_events=False, multicursor=True)
|
||||||
self.dataPlot.updateWidget(xlab, None, plottitle)
|
self.dataPlot.updateWidget(xlab, None, plottitle)
|
||||||
else:
|
else:
|
||||||
self.pg = True
|
self.pg = True
|
||||||
|
@ -594,7 +594,7 @@ class WaveformWidgetPG(QtGui.QWidget):
|
|||||||
|
|
||||||
|
|
||||||
class PylotCanvas(FigureCanvas):
|
class PylotCanvas(FigureCanvas):
|
||||||
def __init__(self, figure=None, parent=None, connect_events=True):
|
def __init__(self, figure=None, parent=None, connect_events=True, multicursor=False):
|
||||||
|
|
||||||
self._parent = parent
|
self._parent = parent
|
||||||
if not figure:
|
if not figure:
|
||||||
@ -607,6 +607,7 @@ class PylotCanvas(FigureCanvas):
|
|||||||
self.plotdict = dict()
|
self.plotdict = dict()
|
||||||
# initialize super class
|
# initialize super class
|
||||||
super(PylotCanvas, self).__init__(self.figure)
|
super(PylotCanvas, self).__init__(self.figure)
|
||||||
|
if multicursor:
|
||||||
# add a cursor for station selection
|
# add a cursor for station selection
|
||||||
self.multiCursor = MultiCursor(self.figure.canvas, (self.axes,),
|
self.multiCursor = MultiCursor(self.figure.canvas, (self.axes,),
|
||||||
horizOn=True, useblit=True,
|
horizOn=True, useblit=True,
|
||||||
@ -955,7 +956,7 @@ class PickDlg(QDialog):
|
|||||||
self.stime, self.etime = full_range(self.getWFData())
|
self.stime, self.etime = full_range(self.getWFData())
|
||||||
|
|
||||||
# initialize plotting widget
|
# initialize plotting widget
|
||||||
self.multicompfig = PylotCanvas(parent=self, connect_events=False)
|
self.multicompfig = PylotCanvas(parent=self, connect_events=False, multicursor=True)
|
||||||
self.phaseplot = PhasePlotWidget(self)
|
self.phaseplot = PhasePlotWidget(self)
|
||||||
self.phaseplot.hide()
|
self.phaseplot.hide()
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user