Example #1
0
 def build(self):
     layout = BoxLayout(orientation='vertical')
     self.label = Label(font_size='128dp')
     s = datetime.now().isoformat()[11:19]
     self.label.text = s
     self.label.padding = (10,10)
     self.label.size = self.label.texture_size
     layout.add_widget(self.label)
     button = Button(size_hint=(.5, .5), text='plop',
                     pos_hint={'x':0.3},on_press=self.play)
     layout.add_widget(button)
     button.pos_hint_x=0.3
     Clock.schedule_interval(self.animate,1/5)
     return layout