Skip to content

Instantly share code, notes, and snippets.

@geojeff
Created April 26, 2013 20:52
Show Gist options
  • Save geojeff/5470355 to your computer and use it in GitHub Desktop.
Save geojeff/5470355 to your computer and use it in GitHub Desktop.
import kivy
kivy.require('{{{ kivy.target_version }}}')
from kivy.uix.floatlayout import FloatLayout
from kivy.app import App
from kivy.properties import ObjectProperty, StringProperty
class {{{ widget.class_name}}}(FloatLayout):
'''{{{ widget.description }}}
'''
label_wid = ObjectProperty()
info = StringProperty()
def do_action(self):
self.label_wid.text = 'My label after a touch'
self.info = 'New info text'
class {{{ widget.class_name }}}App(App):
def build(self):
return {{{ widget.class_name }}}(info='Hello world')
if __name__ == '__main__':
{{{ widget.class_name }}}App().run()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment