MCPcopy
hub / github.com/PyQt5/PyQt / CustomViewBox

Class CustomViewBox

PyQtGraph/graph1.py:20–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

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

Callers 1

testMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected