Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from kivy.app import App
- from kivy.lang import Builder
- from kivy.uix.button import Button
- from kivy.properties import ObjectProperty
- from kivy.uix.gridlayout import GridLayout
- import fiona
- import sqlite3
- class AddButton(Button):
- pass
- class SubtractButton(Button):
- pass
- class Container(GridLayout):
- display = ObjectProperty()
- def add_one(self):
- value = int(self.display.text)
- conn = sqlite3.connect('./test.sqlite')
- cur = conn.cursor()
- cur.execute("select 1 as a")
- self.display.text=str(cur.fetchone()["a"])
- def subtract_one(self):
- value = int(self.display.text)
- peo=fiona.open('./etiquetas_geo.shp')
- self.display.text = str(value-1)
- class MainApp(App):
- def build(self):
- self.title = 'Probatina'
- return Container()
- if __name__ == "__main__":
- app = MainApp()
- app.run()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement