Python 3.x 向纹理添加文本-Kivy

Python 3.x 向纹理添加文本-Kivy,python-3.x,textures,kivy,Python 3.x,Textures,Kivy,我想在图像中添加一些由用户定义的文本字段,并将其导出为一个.png文件。 我曾想过只制作整个小部件的屏幕截图,但质量很低,这不是我真正想要的。 现在我有代码: kv = ''' PageLayout: orientation: 'vertical' RelativeLayout: Image: pos:10,10 id: template source: 'template.png'

我想在图像中添加一些由用户定义的文本字段,并将其导出为一个
.png
文件。 我曾想过只制作整个小部件的屏幕截图,但质量很低,这不是我真正想要的。 现在我有代码:

kv = '''

PageLayout:
    orientation: 'vertical'
    RelativeLayout:
        Image:
            pos:10,10
            id: template
            source: 'template.png'

        Label: 
            pos: 50,50
            markup: True
            text: 'Test'           

    BoxLayout:
        Button:
            text: 'Configure'
            on_release: app.open_settings()
        Button:
            id: savebtn      
            text: 'Save' 
            on_release: app.sc()
'''
用kv语言还是python编写更好

谢谢你的意见