I have my own icon (KO.png: 512x512 (also got in sizes 48, 72, 96, 144 and 192)) in the same folder as my main.py. I want to set it as a launcher icon (1), in ActionPrevious (2) and loading icon (3).
1) The first step is to put in main.py:
def build(self):
self.icon = 'KO.png'
At some point this worked, but can't get it to work again?
2) I also have an ActionBar with ActionPrevious. I want to set my own logo here. So I have in the appname.kv:
ActionPrevious:
app_icon: app.icon if app.icon else ''
This works in Linux, but not in Android. In Android I still have the Kivy logo. Also if I use the 512x512 icon, it is blurry on Linux. If I use the 92x92, it looks fine.
Edit: ActionPrevious does work, the app just didn't properly build because of the incorrect path in buildozer.spec (see 3)
3) Also I want the loader icon to be my own logo, so I have the following code in buildozer.spec:
icon.filename = KO.png
presplash.filename = KO.png
There was before '%(source.dir)s/', but this doesn't work either:
icon.filename = %(source.dir)s/KO.png
presplash.filename = %(source.dir)s/KO.png
Edit: However both these paths result in buildozer not building the .apk, what is the correct path?
Question
O wow... I was stuck on this so long because buildozer doesn't support in-line comments... I had it like this in my buildozer.spec:
icon.filename = %(source.dir)s/ko.png # %(source.dir)s/data/icon.png
This is what solved it:
# %(source.dir)s/data/icon.png
icon.filename = %(source.dir)s/ko.png
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With