MCPcopy Create free account
hub / github.com/LabPy/lantz / keyPressEvent

Method keyPressEvent

lantz/ui/widgets.py:122–130  ·  view source on GitHub ↗

When 'u' is pressed, request new units. When 'r' is pressed, get new value from the driver.

(self, event)

Source from the content-addressed store, hash-verified

120 _WRAPPERS = {}
121
122 def keyPressEvent(self, event):
123 """When 'u' is pressed, request new units.
124 When 'r' is pressed, get new value from the driver.
125 """
126 super().keyPressEvent(event)
127
128 if event.text() == 'r':
129 # This should also trigger a widget update if necessary.
130 self.value_from_feat()
131
132 def value(self):
133 """Get widget value.

Callers 1

keyPressEventMethod · 0.45

Calls 1

value_from_featMethod · 0.95

Tested by

no test coverage detected