我想用一个运行一次然后停止的gif动画制作一个kivy程序。 我将anim_loop设置为1,但它一直运行一遍又一遍。 下面是代码:Kivy Gif动画运行频率过高
Root = Builder.load_string('''
Image:
source: 'streifen1.gif'
size_hint_y: 1
anim_loop: 1
''')
class TTT(App):
def build(self):
Window.clearcolor = (0, 0.5, 1, 1)# sets the backgroundcolor
return Root #returnst the kv string and therefore the root widget`
您使用的是kivy 1.9吗?你是否可以尝试一下你的图片而不是一个gif,这可能会更好地支持? – inclement
@inclement我该如何做到这一点,在文档中没有任何关于它的内容:http://kivy.org/docs/api-kivy.uix.image.html?highlight=image#kivy.uix.image – Gilgamesch
制作一个包含你的图像的zip文件,并将图像源指向该文件名。 – inclement