-
Notifications
You must be signed in to change notification settings - Fork 0
/
gamepage.kv
117 lines (109 loc) · 2.28 KB
/
gamepage.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
#:kivy 1.10.0
<GamePage>:
name: 'game_page'
GamePageLayout:
pos: self.pos
<GameTitle@BoxLayout>:
text: 'Suka'
Label:
text: root.text
font_size: 55
size_hint_x: None
size: self.texture_size
pos_hint: {'left': 1, 'center_y': 0.5}
Label:
font_size: 30
size_hint_x: None
size: self.texture_size
text: '(' + app.release_date + ')'
<InfoLabel@Label>:
size_hint_y: .1
text: ''
font_size: 15
size_hint_x: None
size: self.texture_size
#text_size: self.size
pos_hint: {'left': 1, 'center_y': 0.5}
<Buttons@BoxLayout>:
canvas.before:
Color:
rgba: 0.6, 0.2, 0.3, 1
Rectangle:
size: self.size
pos: self.pos
Button:
text: 'Отзывы'
on_press: app.rw.sm.go_to_reviews_page(app.game_id)#app.rw.sm.current = 'reviews_page'
Button:
text: 'Написать отзыв'
on_press: app.rw.sm.go_to_write_review()
#on_press: app.rw.sm.current = 'write_review_page'
<GameInfo@BoxLayout>:
orientation: 'horizontal'
canvas.before:
Color:
rgba: 0.3, 0.6, 0.9, 1
Rectangle:
size: self.size
pos: self.pos
BoxLayout:
size_hint_y: .25
pos_hint: {'top': 1}
orientation: 'vertical'
InfoLabel:
text: 'Жанры: ' + app.genres
InfoLabel:
text: 'Платформы: ' + app.platforms
InfoLabel:
text: 'Разработчик: ' + app.developer
InfoLabel:
text: 'Издатели: ' + app.publishers
Label:
# canvas.before:
# Color:
# rgba: 0, 1, 0.0, 1
# Rectangle:
# size: self.size
# pos: self.pos
size_hint_y: .2
font_size: 25
bold: True
size_hint_x: None
#size: self.texture_size
#text_size: self.size
pos_hint: {'center_x': 0.5, 'center_y': 0.5}
text: app.game_score
Buttons:
size_hint_y: .1
Label:
canvas.before:
Color:
rgba: 0.3, 0.6, 0.9, 1
Rectangle:
size: self.size
pos: self.pos
# canvas.before:
# Color:
# rgba: 0, 1, 0.0, 1
# Rectangle:
# size: self.size
# pos: self.pos
#size_hint_y: None
#pos_hint: {'center_y': 1}
valign: 'top'
#size_hint_y: 1
text_size: self.size
font_size: 20
size: self.texture_size
text: app.description
<GamePageLayout@BoxLayout>:
orientation: 'vertical'
canvas.before:
Color:
rgba: 0.9, 0.5, 0.1, 1
Rectangle:
size: self.size
GameTitle:
size_hint_y: .1
text: app.game_name
GameInfo: