-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcookie.kv
128 lines (120 loc) · 3.71 KB
/
cookie.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
#: include shapebutton.kv
#: include picture.kv
#: include pictureview.kv
#: include listview.kv
#: include loadfiledialog.kv
#: include savefiledialog.kv
#: include shapelabel.kv
<Cookie>:
canvas.before:
Color:
rgb: (0.9, 0.9, 0.9)
Rectangle:
size: self.width, self.height
pos: self.x, self.y
PictureView:
id: picture_view
size_hint: None, None
size: root.width - 540, root.height - 170
pos: 10, 10
Picture:
id: picture
source: ''
BoxLayout:
size_hint: None, None
size: 500, 60
pos: root.width - 510, root.height - 70
spacing: 4
padding: 4,4,4,4
canvas.before:
Color:
rgba: (1, 1, 1, 1)
Rectangle:
size: self.width, self.height
pos: self.x, self.y
ListViewHeaderLabel:
text: 'Type'
ListViewHeaderLabel:
text: 'Length'
ListViewHeaderLabel:
text: 'Area'
ListViewHeaderLabel:
text: 'Volume'
ListView:
id: list_view
size_hint: None, None
size: 500, root.height - 80
pos: root.width - 510, 10
canvas.before:
Color:
rgb: (0.8, 0.8, 0.8)
Rectangle:
size: self.width, self.height
pos: self.x, self.y
viewclass: 'ShapeLabel'
BoxLayout:
size_hint: None, None
size: 480, 140
pos: 10, root.height - 150
canvas:
Color:
rgb: (1, 1, 1)
Rectangle:
size: self.width, self.height
pos: self.x, self.y
GridLayout:
rows: 2
col: 1
spacing: 4
padding: 4, 4, 4, 4
BoxLayout:
spacing: 4
Button:
text: 'Open file'
on_release: root.open_file()
Button:
text: 'Save'
size_hint: None, None
size: 200, 64
on_release: root.save_file()
GridLayout:
rows: 1
cols: 5
spacing: 4
ShapeButton:
id: line_button
name: 'line'
background_normal: 'icons/line.png'
on_release: root.shape_button_click(self)
ShapeButton:
id: circle_button
name: 'circle'
background_normal: 'icons/circle.png'
on_release: root.shape_button_click(self)
ShapeButton:
id: rectangle_button
name: 'rectangle'
background_normal: 'icons/rectangle.png'
on_release: root.shape_button_click(self)
ShapeButton:
id: freeform_button
name: 'freeform'
background_normal: 'icons/freeform.png'
on_release: root.shape_button_click(self)
Button:
id: shape_remove_button
text: 'Delete'
on_release: root.delete_drawing()
canvas.before:
Color:
rgb: (0.8, 0.8, 0.8)
Rectangle:
size: self.width, self.height
pos: self.x, self.y
<ListViewHeaderLabel@Label>
canvas.before:
Color:
rgba: (0, 0, 0, 0.7)
Rectangle:
size: self.width, self.height
pos: self.x, self.y