MCPcopy Index your code
hub / github.com/PyQt5/PyQt / CustomViewBox

Class CustomViewBox

PyQtGraph/testGraphAnalysis.py:21–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

19
20
21class CustomViewBox(pg.ViewBox):
22 def __init__(self, *args, **kwds):
23 pg.ViewBox.__init__(self, *args, **kwds)
24 self.RectMode = 3
25 self.setMouseMode(self.RectMode)
26
27 def mouseClickEvent(self, ev):
28 if ev.button() == pg.QtCore.Qt.RightButton:
29 self.autoRange()
30
31 def mouseDragEvent(self, ev):
32 pg.ViewBox.mouseDragEvent(self, ev)
33
34 def wheelEvent(self, ev, axis=None):
35 ev.ignore()
36
37
38class graphAnalysis(QDialog, graph_Form):

Callers 1

testMethod · 0.70

Calls

no outgoing calls

Tested by 1

testMethod · 0.56