forked from PI2G05-2021-2/software
-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.py
49 lines (37 loc) · 1.42 KB
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
import os
from kivy.core.window import Window
from kivymd.app import MDApp
from kaki.app import App
from kivy.factory import Factory
Window.size = (414, 736)
# main app class for kaki app with kivymd modules
class LiveApp(MDApp, App):
""" Hi Windows users """
DEBUG = 1 # set this to 0 make live app not working
# *.kv files to watch
KV_FILES = {
os.path.join(os.getcwd(), "screens/mainscreenmanager.kv"),
os.path.join(os.getcwd(), "screens/screens_login/loginscreen.kv"),
}
# class to watch from *.py files
CLASSES = {
"MainScreenManager": "screens.mainscreenmanager",
"LoginScreen": "screens.screens_login.loginscreen",
"LaboratorioScreen": "screens.screens_laboratorio.laboratorioscreen",
"AcompanharScreen": "screens.screens_acompanhar.acompanharscreen",
"PerfilScreen": "screens.screens_perfil.perfilscreen",
"RelatorioScreen": "screens.screens_relatorio.relatorioscreen",
"HomeLaboratorioScreen": "screens.screens_laboratorioHome.laboratoriohomescreen",
}
# auto reload path
AUTORELOADER_PATHS = [
(".", {"recursive": True}),
]
def build_app(self):
self.theme_cls.theme_style = "Dark"
self.theme_cls.primary_palette = "Green"
self.theme_cls.accent_palette = "Blue"
return Factory.MainScreenManager()
# finally, run the app
if __name__ == "__main__":
LiveApp().run()