• <bdo id='xLyvk'></bdo><ul id='xLyvk'></ul>
    <i id='xLyvk'><tr id='xLyvk'><dt id='xLyvk'><q id='xLyvk'><span id='xLyvk'><b id='xLyvk'><form id='xLyvk'><ins id='xLyvk'></ins><ul id='xLyvk'></ul><sub id='xLyvk'></sub></form><legend id='xLyvk'></legend><bdo id='xLyvk'><pre id='xLyvk'><center id='xLyvk'></center></pre></bdo></b><th id='xLyvk'></th></span></q></dt></tr></i><div id='xLyvk'><tfoot id='xLyvk'></tfoot><dl id='xLyvk'><fieldset id='xLyvk'></fieldset></dl></div>

      <small id='xLyvk'></small><noframes id='xLyvk'>

      <tfoot id='xLyvk'></tfoot><legend id='xLyvk'><style id='xLyvk'><dir id='xLyvk'><q id='xLyvk'></q></dir></style></legend>

        Android kivy 在哪里放置应用程序文件(ini、images d

        时间:2023-08-31

        1. <legend id='0CcbJ'><style id='0CcbJ'><dir id='0CcbJ'><q id='0CcbJ'></q></dir></style></legend>
        2. <tfoot id='0CcbJ'></tfoot>
            <bdo id='0CcbJ'></bdo><ul id='0CcbJ'></ul>

                <tbody id='0CcbJ'></tbody>

                <small id='0CcbJ'></small><noframes id='0CcbJ'>

                <i id='0CcbJ'><tr id='0CcbJ'><dt id='0CcbJ'><q id='0CcbJ'><span id='0CcbJ'><b id='0CcbJ'><form id='0CcbJ'><ins id='0CcbJ'></ins><ul id='0CcbJ'></ul><sub id='0CcbJ'></sub></form><legend id='0CcbJ'></legend><bdo id='0CcbJ'><pre id='0CcbJ'><center id='0CcbJ'></center></pre></bdo></b><th id='0CcbJ'></th></span></q></dt></tr></i><div id='0CcbJ'><tfoot id='0CcbJ'></tfoot><dl id='0CcbJ'><fieldset id='0CcbJ'></fieldset></dl></div>

                1. 本文介绍了Android kivy 在哪里放置应用程序文件(ini、images db 等)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  我已经使用 kivy 为 Android 创建了一个原型应用程序.它已在 buildozer 中编译,我已上传到 Android 设备.

                  I've created a prototype application for Android using kivy. It has compiled in buildozer and I've uploaded in to an Android device.

                  但我不确定将应用程序相关文件(如 ini 文件、图像数据库等)放在哪里.

                  But I'm nor sure where to put app dependent files like the ini file, images database etc.

                  非常感谢任何帮助

                  当我问这个问题时(很多个月前),我对 kivy 和 buildozer 的整个想法都是新手.

                  When I asked this question (many moons ago) I was new to kivy and the whole idea of buildozer.

                  我没有意识到以及对于初学者来说不明显的事情(见证这个问题被查看的次数)以及 @inclement 的答案没有解决的问题是 Buildozer 将整个 python/kivy 项目包装到一个可以包含所有 static 数据的文件.因此,您只需要确保您的 buildozer 规范能够接受它们.

                  What I didn't realise and what isn't obvious to a beginner (witness the number of times this question has been viewed) and which @inclement's answer does not address, is that Buildozer wraps the whole python/kivy project into a single file which can include all of your static data. So you just need to make sure your buildozer spec picks them up.

                  推荐答案

                  您可以安排他们品尝 - 只要您告诉 buildozer 包含它们 apk(即通过设置要包含的文件类型、目录等)并访问它们在您的代码中具有相对路径,它们将在设备上以相同的方式工作.

                  You can arrange them to taste - as long as you tell buildozer to include them apk (i.e. by setting the file types, directories etc to be included) and access them with relative paths in your code, they will work the same way on the device.

                  ini 文件可能是一个例外,我不确定 kivy 尝试从哪里加载它(但它可能位于外部数据目录中的某个位置).如果将它放在与 main.py 相同的目录不起作用,也许您可​​以使用相对路径手动加载它,或者如果它只有几个值,那么您可以在 main.py 文件中设置它们.

                  The ini file may be an exception, I'm not sure offhand where kivy tries to load it from (but it may be somewhere in the external data dir). If putting it in the same directory as main.py doesn't work, maybe you could load it manually with a relative path, or if it has just a few values then you could set them in the main.py file.

                  这篇关于Android kivy 在哪里放置应用程序文件(ini、images db 等)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:Buildozer 未知命令/目标 android_old 下一篇:如何在 android 中调试 kivy 应用程序?

                  相关文章

                  最新文章

                  <small id='TjUXy'></small><noframes id='TjUXy'>

                2. <legend id='TjUXy'><style id='TjUXy'><dir id='TjUXy'><q id='TjUXy'></q></dir></style></legend>
                  <i id='TjUXy'><tr id='TjUXy'><dt id='TjUXy'><q id='TjUXy'><span id='TjUXy'><b id='TjUXy'><form id='TjUXy'><ins id='TjUXy'></ins><ul id='TjUXy'></ul><sub id='TjUXy'></sub></form><legend id='TjUXy'></legend><bdo id='TjUXy'><pre id='TjUXy'><center id='TjUXy'></center></pre></bdo></b><th id='TjUXy'></th></span></q></dt></tr></i><div id='TjUXy'><tfoot id='TjUXy'></tfoot><dl id='TjUXy'><fieldset id='TjUXy'></fieldset></dl></div>

                      <tfoot id='TjUXy'></tfoot>

                        <bdo id='TjUXy'></bdo><ul id='TjUXy'></ul>