-
-
Save tito/2590088 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from kivy.app import App | |
from kivy.uix.widget import Widget | |
from kivy.properties import ObjectProperty, NumericProperty | |
from kivy.lang import Builder | |
Builder.load_string(''' | |
<ArrowPointer>: | |
canvas: | |
Color: | |
rgb: 0, 0, 111 / 255. | |
Line: | |
points: self.x - self.offset, self.y - self.offset, self.x + self.offset, self.y + self.offset | |
''') | |
class ArrowPointer(Widget): | |
arrow_tip = ObjectProperty(None) | |
offset = NumericProperty(50) | |
class TestB(App): | |
def build(self): | |
return ArrowPointer() | |
if __name__ == '__main__': | |
TestB().run() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment