如何在Python/Kivy中实现ScrollView

dep*_*oul 6 python kivy

我已经制作了一些代码来显示Python/Kivy中的一些内容,似乎我没有写好ScrollView.

我在程序中尝试了一些变化,但程序没有显示滚动条.

这是我的代码:

def build(self):
    root = BoxLayout(orientation='vertical')
    box = BoxLayout(orientation='vertical')     
    lists = rss_feed()      
    for lista in lists:
        temp = BoxLayout(orientation='vertical')
        for entry in lista:
            temp.add_widget(Label(text=entry))
        box.add_widget(temp)
    sv = ScrollView(size_hint=(True, True), size=(400, 400))
    root.add_widget(sv)
    sv.add_widget(box)      
    return root
Run Code Online (Sandbox Code Playgroud)

我的问题是:我需要做什么才能显示scroolbar ???

谢谢

dep*_*oul 5

我在https://groups.google.com/forum/?fromgroups=#!topic/kivy-users/AiaUnKp3XX4上找到了一个示例,错误已得到纠正.

我忘了设置绑定方法