attributeerrorpython&;具有函数的Kivy设置属性

attributeerrorpython&;具有函数的Kivy设置属性,python,kivy,attributeerror,Python,Kivy,Attributeerror,我试图使用python函数(getText,见下文)在kivy lang中设置属性,但我得到了一个 AttributeError:“非类型”对象没有属性“绑定” 这是我的代码: 千伏 白痴 顺便说一句,追踪者告诉我错误在“text:app.getText()”行中,请检查代码。删除对未定义方法的引用将生成一个运行的示例。查阅 BoxLayout: padding: root.width * .02, root.height * .02 Label: tex

我试图使用python函数(
getText
,见下文)在kivy lang中设置属性,但我得到了一个

AttributeError:“非类型”对象没有属性“绑定”

这是我的代码:

千伏

白痴


顺便说一句,追踪者告诉我错误在“text:app.getText()”行中,请检查代码。删除对未定义方法的引用将生成一个运行的示例。查阅
    BoxLayout:
    padding: root.width * .02, root.height * .02
    Label:
        text: app.getText()
        halign: "center"
        markup: True
        font_size: root.height / 20
        text_size: self.width, None
        center_y: .5
        on_ref_press: app.on_ref_press(*args)
    BotonAtras:
        on_press: app.root.current = "intro"
class Calculator(App):
def build(self):
    return kivyfile

def getText(self):
    return ("Hola esta es nuestra aplicacion que fue echa usando [b][ref=kivy]kivy[/ref][/b]\n"
            "grupo esta compuesto por: \n"
            "Ruben Perez \n"
            "Anthony Cambridge \n")