Created
November 22, 2012 22:15
-
-
Save mike-perdide/4133125 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| from kivy.app import App | |
| from kivy.uix.boxlayout import BoxLayout | |
| from kivy.uix.button import Button | |
| from kivy.uix.dropdown import DropDown | |
| from kivy.lang import Builder | |
| Builder.load_string(""" | |
| <ComboBox> | |
| cols: 1 | |
| DropDown: | |
| Button: | |
| text: 'My first Item' | |
| Label: | |
| text: 'Unselectable item' | |
| Button: | |
| text: 'My second Item' | |
| """) | |
| class ComboBox(BoxLayout): | |
| def __init__(self): | |
| BoxLayout.__init__(self) | |
| if __name__ == "__main__": | |
| class TestApp(App): | |
| def build(self): | |
| widget = ComboBox() | |
| return widget | |
| TestApp().run() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment