#:kivy 1.9.0
<PongGame> :
canvas :
Rectangle :
pos : self . center_x - 5 , 0
size : 10 , self . height
Label :
font_size : 70
center_x : root . width / 4
top : root . top - 50
text : "0"
Label :
font_size : 70
center_x : root . width * 3 / 4
top : root . top - 50
text : "0"
При выполнении программы терминал пишет :
[INFO ] [Logger ] Record log in /home/sergey/.kivy/logs/kivy_16-01-14_2.txt
[INFO ] [Kivy ] v1.9.0
[INFO ] [Python ] v3.4.3 (default, Oct 14 2015, 20:28:29)
[GCC 4.8.4]
[INFO ] [Factory ] 173 symbols loaded
[INFO ] [Image ] Providers: img_tex, img_dds, img_gif, img_sdl2, img_pil (img_ffpyplayer ignored)
Traceback (most recent call last):
File "main.py", line 16, in <module>
PongApp () . run ()
File "/usr/lib/python3/dist-packages/kivy/app.py", line 797, in run
self.load_kv(filename=self.kv_file)
File "/usr/lib/python3/dist-packages/kivy/app.py", line 594, in load_kv
root = Builder.load_file(rfilename)
File "/usr/lib/python3/dist-packages/kivy/lang.py", line 1749, in load_file
return self.load_string(data, **kwargs)
File "/usr/lib/python3/dist-packages/kivy/lang.py", line 1796, in load_string
parser = Parser(content=string, filename=fn)
File "/usr/lib/python3/dist-packages/kivy/lang.py", line 1185, in __init__
self.parse(content)
File "/usr/lib/python3/dist-packages/kivy/lang.py", line 1287, in parse
objects, remaining_lines = self.parse_level(0, lines)
File "/usr/lib/python3/dist-packages/kivy/lang.py", line 1369, in parse_level
current_object = ParserRule(self, ln, x[0], rlevel)
File "/usr/lib/python3/dist-packages/kivy/lang.py", line 1043, in __init__
self._detect_selectors()
File "/usr/lib/python3/dist-packages/kivy/lang.py", line 1085, in _detect_selectors
self._build_rule()
File "/usr/lib/python3/dist-packages/kivy/lang.py", line 1101, in _build_rule
'Invalid rule (must be inside <>)')
kivy.lang.ParserException: Parser: File "./pong.kv", line 3:
...
1:#:kivy 1.9.0
2:
>> 3:<PongGame> :
4: canvas :
5: Rectangle :
...
Invalid rule (must be inside <>)
В чем проблема?