from kivy.app import App
from kivy.uix.floatlayout import FloatLayout
from kivy.uix.button import Button,Label
class Platform(FloatLayout):
def __init__(self):
super(Platform, self).__init__()
self.but = Button(text = "push")
self.add_widget(self.but)
self.but.size_hint = None,None
def on_touch_down(self, touch):
pass
class T_App(App):
def build(self):
return Platform()
T_App().run()
Post your code and we can show you how :-)
--
You received this message because you are subscribed to a topic in the Google Groups "Kivy users support" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/kivy-users/HH9SP3u3_xw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to kivy-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
> You received this message because you are subscribed to the Google Groups
> "Kivy users support" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to kivy-users+unsubscribe@googlegroups.com.
You received this message because you are subscribed to a topic in the Google Groups "Kivy users support" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/kivy-users/HH9SP3u3_xw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to kivy-users+unsubscribe@googlegroups.com.
from kivy.app import App
from kivy.uix.floatlayout import FloatLayout
from kivy.uix.button import Button,Label
class Platform(FloatLayout):
touch = True
def __init__(self):
super(Platform, self).__init__()
self.but = Button(text = "push")
self.add_widget(self.but)
self.but.size_hint = None,None
def on_touch_down(self, touch):
if self.touch == True:
return True
else:
return super(Platform, self).on_touch_down(touch)
def on_touch_up(self, touch):
self.touch = False
class T_App(App):
def build(self):
return Platform()
T_App().run()