Skip to content

Instantly share code, notes, and snippets.

@wasimafser
Created May 7, 2020 07:51
Show Gist options
  • Save wasimafser/ff7df2f847457a1b1a9090c6c13311e0 to your computer and use it in GitHub Desktop.
Save wasimafser/ff7df2f847457a1b1a9090c6c13311e0 to your computer and use it in GitHub Desktop.
from kivy.lang import Builder
from kivymd.app import MDApp
KV = '''
Screen:
BoxLayout:
orientation: 'vertical'
size_hint_y: None
canvas.before:
Color:
rgba: (1, 0, 0, 0.5)
Rectangle:
size: self.size
pos: self.pos
MDSlider:
min: 0
max: 100
value: 40
on_touch_up: app.print_test()
'''
class Test(MDApp):
def build(self):
return Builder.load_string(KV)
def print_test(self, *args):
print("TOUCH UP")
Test().run()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment