MCPcopy Index your code
hub / github.com/rawpython/remi / main

Method main

examples/closeable_app.py:25–36  ·  view source on GitHub ↗
(self, name='world')

Source from the content-addressed store, hash-verified

23
24class MyApp(App):
25 def main(self, name='world'):
26 # margin 0px auto allows to center the app to the screen
27 wid = gui.VBox(width=300, height=200, margin='0px auto')
28
29 bt = gui.Button('Close App', width=200, height=30)
30 bt.style['margin'] = 'auto 50px'
31 bt.style['background-color'] = 'red'
32
33 bt.onclick.do(self.on_button_pressed)
34
35 wid.append(bt)
36 return wid
37
38 # listener function
39 def on_button_pressed(self, _):

Callers

nothing calls this directly

Calls 2

doMethod · 0.45
appendMethod · 0.45

Tested by

no test coverage detected