-
Notifications
You must be signed in to change notification settings - Fork 6
/
jarvis.kv
614 lines (537 loc) · 16.4 KB
/
jarvis.kv
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
#:import Toolbar kivymd.toolbar.Toolbar
#:import ThemeManager kivymd.theming.ThemeManager
#:import NavigationDrawer kivymd.navigationdrawer.NavigationDrawer
#:import MDCheckbox kivymd.selectioncontrols.MDCheckbox
#:import MDList kivymd.list.MDList
#:import OneLineListItem kivymd.list.OneLineListItem
#:import TwoLineListItem kivymd.list.TwoLineListItem
#:import OneLineAvatarListItem kivymd.list.OneLineAvatarListItem
#:import OneLineIconListItem kivymd.list.OneLineIconListItem
#:import OneLineAvatarIconListItem kivymd.list.OneLineAvatarIconListItem
#:import MDTextField kivymd.textfields.MDTextField
#:import MDSpinner kivymd.spinner.MDSpinner
#:import get_color_from_hex kivy.utils.get_color_from_hex
#:import colors kivymd.color_definitions.colors
#:import SmartTile kivymd.grid.SmartTile
#:import MDThemePicker kivymd.theme_picker.MDThemePicker
<Toast>:
size_hint:None,None
y:'-50dp'
size: '300dp','48dp'
anchor_x:'right'
canvas:
Color:
rgba: 0.910, 0.298, 0.239, 1.0
RoundedRectangle:
pos: self.pos
size: self.size
radius: 10,10,10,10
Label:
id:label
font_size: '18sp'
# font_name: 'Lato-Bold.ttf'
AnchorLayout:
size_hint:None, None
size:'48dp','48dp'
anchor_x:'center'
SegButton:
size_hint:None, None
size:'24dp', '24dp'
border:0,0,0,0
background_normal:'./assets//close.png'
background_down:'./assets/close_down.png'
on_release:root.exit(None)
<SegButton@Button>:
# font_name: './kivymd/Lato-Bold.ttf'
font_size: '22sp'
border: 10,10,10,10
background_disabled_normal:'./assets/but_disabled.png'
background_disabled_down:'./assets/but_disabled.png'
<SegInput@TextInput>:
background_normal:'./assets/textinput.png'
background_active:'./assets/textinput_active.png'
# font_name: 'Lato-Regular.ttf'
font_size: '14sp'
cursor_color: 0.498, 0.549, 0.552,1.0
foreground_color: 0.204, 0.286, 0.369, 1.0
selection_color: 0.925, 0.941, 0.937, 0.5
padding: '16dp', '16dp'
halign:'justify'
border: 10,10,10,10
<GbeeRoot>:
orientation: 'vertical'
ScreenManager:
id:gbee_screen_manager
MainScreen:
id:main_screen
name: 'main_screen'
Testimonies
id: testimonies
name: 'testimonies'
Requests
id: requests
name: 'requests'
Sermons
id: sermons
name: 'sermons'
Guide:
id: guide
name: 'guide'
Pastors
id: pastors
name: 'pastors'
RequestsReader
id: requests_reader
name: 'requests_reader'
Tithe:
id: tithe
name: 'tithe'
TitheViewer
id: tithe_viewer
name: 'tithe_viewer'
Search
id: search
name: 'search'
Quotes
id: quotes
name: 'quotes'
Gallery
id: gallery
name: 'gallery'
<MainScreen>:
Image:
source:'./assets/tower.png'
Toolbar:
id: toolbar
title: 'GoshenApp'
md_bg_color: app.theme_cls.primary_color
background_palette: 'Primary'
background_hue: '500'
right_action_items: [['dots-vertical', lambda x: app.nav_drawer.toggle()]]
<Testimonies>:
Image:
source: './assets/tower.png'
MDLabel:
font_style: 'Body1'
theme_text_color: 'Primary'
text: "It is always good to share what the Lord has done in your life to encourage\nothers in the church "
halign: 'center'
pos_hint:{'center_x': 0.5, 'center_y': 0.85}
font_size: 25
MDRaisedButton:
text: " Testify"
opposite_colors: True
size_hint: None, None
size: 4 * dp(40), dp(40)
pos_hint: {'center_x': 0.2, 'center_y': 0.3}
font_name: 'Roboto-Regular'
on_release: root.share()
MDRaisedButton:
text: " read"
opposite_colors: True
size_hint: None, None
size: 4 * dp(40), dp(40)
pos_hint: {'center_x': 0.8, 'center_y': 0.3}
font_name: 'Roboto-Regular'
on_release: root.thread_read()
Toast:
id:toast
width: min(root.width - dp(32), dp(300))
x:root.center_x - self.width // 2
<F>:
name: name
message: message
shiermor_button:shiermor_button
id: sub_button
title: 'Share Your Testimony'
markup: True
size_hint: .9, None
height: dp(350)
pos_hint:{'center_x': 0.5, 'center_y': 0.6}
FloatLayout:
MDTextField:
id: name
hint_text: 'Name'
multiline: False
size_hint: 0.8, None
height: dp(48)
pos_hint:{'center_x': 0.5, 'center_y': 0.8}
MDTextField:
id: message
hint_text: 'Message'
multiline: True
pos_hint:{'center_x': 0.5, 'center_y': 0.6}
size_hint: 0.8, None
height: dp(60)
MDRaisedButton:
id: shiermor_button
text: 'ShieeeeeeM)'
pos_hint:{'center_x': 0.5, 'center_y': 0.2}
size_hint: None,None
size: dp(150),dp(35)
on_press: root.shiermor_thread()
MDSpinner:
id: spinner
size_hint: None,None
size: dp(30),dp(30)
pos_hint:{'center_x': 0.2, 'center_y': 0.2}
active: False
<Requests>:
name: name
prayer: prayer
Image:
source: './assets/tower.png'
pos_hint:{'center_x': 0.5, 'center_y': 0.7}
FloatLayout:
SegInput:
id: name
size_hint: 0.8, None
height: dp(48)
hint_text: "Full Name "
pos_hint: {'center_x':.5, 'center_y': .6}
# font_name:'Roboto-Thin'
multiline: False
SegInput:
id: prayer
size_hint: 0.8, None
height: dp(80)
hint_text: "Prayer "
pos_hint: {'center_x':.5, 'center_y': .4}
# font_name:'Roboto-Thin'
multiline: True
hint_text: "Type Your Requests Here"
MDRaisedButton:
id: float_act_btn
text: 'Send'
pos_hint:{'center_x': 0.5, 'center_y': 0.2}
size_hint: None,None
size: dp(150),dp(35)
on_press: root.add_thread()
MDSpinner:
id: spinner
size_hint: None,None
size: dp(30),dp(30)
pos_hint:{'center_x': 0.5, 'center_y': 0.1}
active: False
Toast:
id:toast
width: min(root.width - dp(32), dp(300))
x:root.center_x - self.width // 2
<Sermons>
on_enter: root.load()
scroller: scroller
grid: grid
spinner:spinner
box2: box2
#search_input: search_input
BoxLayout:
id: box1
orientation:'vertical'
BoxLayout:
id: box2
height: "40dp"
size_hint_y: None
TextInput:
id: search_input
text: ''
hint_text:'Search Sermon Here :-)'
BoxLayout:
FloatLayout:
ScrollView:
id: scroller
do_scroll_x: False
MDList:
id: grid
cols: 1
size_hint_y: None
height: 8 * dp(100) # /1 * self.row_default_height
padding: dp(4), dp(4)
spacing: dp(4)
MDSpinner:
id: spinner
size_hint: None,None
size: dp(30),dp(30)
pos_hint:{'center_x': 0.5, 'center_y': 0.8}
active: False
Toast:
id:toast
width: min(root.width - dp(32), dp(300))
x:root.center_x - self.width // 2
<DownPop>:
play_stop:play_stop
size_hint: .9,.3
# height: dp(220)
pos_hint:{'center_x': 0.5, 'center_y': 0.65}
BoxLayout:
orientation:'vertical'
Button:
id: play_stop
text:'Play'
on_release: root.load_play()
Button:
text:'Download'
on_release: root.download()
Button:
text:'Share Link'
on_release: root.share()
<Guide>:
on_enter:root.thread_guide()
ml:ml
scroller:scroller
spinner: spinner
Image:
source: './assets/tower.png'
ScrollView:
id: scroller
do_scroll_x: False
bar_color: [.1, .5, .7, .9]
bar_margin: 3
bar_width: 5
MDList:
id: ml
MDSpinner:
id: spinner
size_hint: None,None
size: sp(30),sp(30)
pos_hint:{'center_x': 0.5, 'center_y': 0.7}
active: False
Toast:
id:toast
width: min(root.width - dp(32), dp(300))
x:root.center_x - self.width // 2
<Pastors>:
pas_text_field:pas_text_field
name_text_field:name_text_field
button:button
Image:
source: './assets/tower.png'
FloatLayout:
MDTextField:
id: name_text_field
size_hint: 0.8, None
height: dp(48)
hint_text: "Name "
pos_hint: {'center_x':.5, 'center_y': .7}
# font_name:'Roboto-Thin'
MDTextField:
id: pas_text_field
size_hint: 0.8, None
height: dp(48)
hint_text: "Password "
pos_hint: {'center_x':.5, 'center_y': .5}
# font_name:'Roboto-Thin'
password: True
MDRaisedButton:
id: button
text: "Login"
opposite_colors: True
size_hint: None, None
size: 4 * dp(40), dp(40)
pos_hint: {'center_x': 0.5, 'center_y': 0.3}
# font_name: 'Roboto-Regular'
on_release: root.login_thread()
MDSpinner:
id: spinner
size_hint: None,None
size: sp(30),sp(30)
pos_hint:{'center_x': 0.5, 'center_y': 0.8}
active: False
Toast:
id:toast
width: min(root.width - dp(32), dp(300))
x:root.center_x - self.width // 2
<Tithe>:
on_enter: root.adder()
grid:grid
ScrollView:
MDList:
id: grid
cols: 2
size_hint_y: None
height: 8 * dp(80)
row_default_height:(0.5 * (self.width - self.spacing[0]) -self.padding[0])
row_force_default: True
spacing: 5
padding: 5
MDFloatingActionButton:
id: float_act_btn
icon:'receipt' #chart
size_hint: None, None
size: dp(60), dp(60)
opposite_colors: True
elevation_normal: 8
pos_hint:{'center_x': 0.8, 'center_y': 0.2}
on_press: app.root.next_screen('tithe_viewer')
<TitheViewer>:
on_enter: root.adder()
ml:ml
Image:
source: './assets/tower.png'
ScrollView:
id: scroller
do_scroll_x: False
bar_color: [.1, .5, .7, .9]
bar_margin: 3
bar_width: 5
MDList:
id: ml
cols:2
<TithePopup>:
amount:amount
add:add
size_hint: .9, None
height: dp(220)
pos_hint:{'center_x': 0.5, 'center_y': 0.7}
BoxLayout:
orientation:'vertical'
padding:10
spacing:10
SegInput:
id: amount
hint_text: 'Amount'
font_size: 20
BoxLayout:
orientation: 'horizontal'
Button:
id: add
text: 'Add'
on_press:root.on_add()
<RequestsReader>:
GridLayout:
rows:2
padding: 5
spacing: 5
MDRaisedButton:
text: "READ REQUESTS"
on_release: root.load_requests()
MDRaisedButton:
text: "Add Annoucements"
on_release: root.add_announce()
<Search>:
on_enter: root.loader()
ml:ml
scroller: scroller
BoxLayout:
orientation:'vertical'
BoxLayout:
id: box1
height: "40dp"
size_hint_y: None
TextInput:
id: search_input
size_hint_x: 75
text:''
BoxLayout:
FloatLayout:
ScrollView:
id: scroller
do_scroll_x: False
bar_color: [.1, .5, .7, .9]
bar_margin: 3
bar_width: 5
MDList:
id: ml
Toast:
id:toast
width: min(root.width - dp(32), dp(300))
x:root.center_x - self.width // 2
MDSpinner:
id: spinner
size_hint: None,None
size: sp(30),sp(30)
pos_hint:{'center_x': 0.5, 'center_y': 0.7}
active: False
<Quotes>:
# on_enter: root.thread_announcement()
ml:ml
scroller:scroller
spinner: spinner
Image:
source: './assets/tower.png'
ScrollView:
id: scroller
do_scroll_x: False
bar_color: [.1, .5, .7, .9]
bar_margin: 3
bar_width: 5
MDList:
id: ml
MDSpinner:
id: spinner
size_hint: None,None
size: sp(30),sp(30)
pos_hint:{'center_x': 0.5, 'center_y': 0.7}
active: False
Toast:
id:toast
width: min(root.width - dp(32), dp(300))
x:root.center_x - self.width // 2
<Gallery>:
on_enter: root.load()
grid: grid
spinner:spinner
Carousel:
id: grid
direction: 'bottom'
spacing: dp(20)
padding: dp(10)
MDSpinner:
id: spinner
size_hint: None,None
size: dp(30),dp(30)
pos_hint:{'center_x': 0.5, 'center_y': 0.8}
active: True
Toast:
id:toast
width: min(root.width - dp(32), dp(300))
x:root.center_x - self.width // 2
<Drawer>:
title: "Tower of Favour"
NavigationDrawerIconButton:
icon: 'microphone'
text: "Testimonies"
on_press: app.root.next_screen('testimonies')
NavigationDrawerIconButton:
icon: 'fire'
text: "Prayer Requests"
on_release: app.root.next_screen('requests')
NavigationDrawerIconButton:
icon: 'audiobook'
text: "Audio Sermons"
on_release: app.root.next_screen('sermons')
NavigationDrawerIconButton:
icon: 'calendar-check'
text: "Daily Guide"
on_release: app.root.next_screen('guide')
NavigationDrawerIconButton:
icon: 'account-star'
text: "Pastors Circle"
on_release: app.root.next_screen('pastors')
# NavigationDrawerIconButton:
# icon: 'slideshow'
# text: "Gallery"
# on_release: app.root.next_screen('gallery')
# NavigationDrawerIconButton:
# icon: 'inbox'
# text: "Announcements"
# on_release: app.root.next_screen('announcements')
NavigationDrawerIconButton:
icon: 'wallet'
text: "Tithe Calculator"
on_release: app.root.next_screen('tithe')
NavigationDrawerIconButton:
icon: 'image'
text: "Gallery"
on_release: app.root.next_screen('gallery')
NavigationDrawerIconButton:
icon: 'dialpad'
text: "Search"
on_release: app.root.next_screen('search')
NavigationDrawerIconButton:
icon: 'format-quote'
text: "Quotes"
on_release: app.root.next_screen('quotes')
NavigationDrawerIconButton:
icon: 'flip-to-back'
text: "Back"
on_release: app.root.next_screen('main_screen')