forked from remi2257/sudoku-solver
-
Notifications
You must be signed in to change notification settings - Fork 0
/
sudoku.kv
181 lines (150 loc) · 4.11 KB
/
sudoku.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
<MonBouton>
BoxLayout:
orientation: 'horizontal'
ToggleButton:
id: btn1
text: "Full Solve"
group: "solve"
state: "down"
pos_hint: {"left":1}
ToggleButton:
id: btn2
text: "Hint"
group: "solve"
pos_hint: {"right":1}
WindowManager:
id: screen_manager
MainScreen:
id: main
name: "main"
HelpScreen:
id: help
name: "help"
LiveSolverScreen:
id: live_solver
name: "live_solver"
GallerySolverScreen:
id: gallery_solver
name: "gallery_solver"
ManualSolverScreen:
id: manual_solver
name: "manual_solver"
AboutScreen:
id: about
name: "about"
<MainScreen>:
name: "main"
FloatLayout:
Button:
id: button_help
text: "Help"
pos_hint: {"top":0.95}
size_hint_y: 0.1
on_release:
app.root.transition.direction = "down"
app.root.current = "help"
Button:
id: button_live_solver
text: "Live Solver"
pos_hint: {"top":0.8}
size_hint_y: 0.1
on_release:
app.root.transition.direction = "right"
app.root.current = "live_solver"
app.root.ids.live_solver.start_stream()
Button:
id: button_gallery_solver
text: "Gallery Solver"
pos_hint: {"top":0.65}
size_hint_y: 0.1
on_release:
app.root.transition.direction = "left"
app.root.current = "gallery_solver"
Button:
id: button_manual_solver
text: "Manual Solver"
pos_hint: {"top":0.5}
size_hint_y: 0.1
on_release:
app.root.transition.direction = "left"
app.root.current = "manual_solver"
Button:
id: button_about
text: "About"
pos_hint: {"top":0.3}
size_hint_y: 0.1
on_release:
app.root.transition.direction = "up"
app.root.current = "about"
<HelpScreen>:
name: "help"
FloatLayout:
id: float_layout
Button:
id: button
text: "Back"
size_hint_y: 0.1
on_release:
app.root.transition.direction = "up"
app.root.current = "main"
<LiveSolverScreen>:
name: "live_solver"
camera: camera
FloatLayout:
id: float_layout
MyKivyCamera:
id: camera
size_hint_y: 0.8
pos_hint: {"top":1}
Button:
id: button_back
text: "Back"
size_hint_y: 0.1
on_release:
root.stop_stream()
app.root.transition.direction = "left"
app.root.current = "main"
MonBouton:
size_hint_y: 0.1
pos_hint: {"y":0.2}
id: toggle_button
<GallerySolverScreen>:
name: "gallery_solver"
kivy_image: image
FloatLayout:
Image:
id: image
size_hint_y: 0.9
pos_hint: {"top":1}
Button:
id: button
text: "Back"
size_hint_y: 0.1
on_release:
app.root.transition.direction = "right"
app.root.current = "main"
<ManualSolverScreen>:
name: "gallery_solver"
image: image
FloatLayout:
Image:
id: image
size_hint_y: 0.9
pos_hint: {"top":1}
Button:
id: button
text: "Back"
size_hint_y: 0.1
on_release:
app.root.transition.direction = "right"
app.root.current = "main"
<AboutScreen>:
name: "about"
FloatLayout:
Button:
id: button
text: "Back"
size_hint_y: 0.1
on_release:
app.root.transition.direction = "down"
app.root.current = "main"