Pause/play bitmap not showing

Pause/play bitmap don’t show up in the widget even though I believe I have put the correct path of the images.

Here is the formula I use: $if(mi(state)=PLAYING,file:/storage/emulated/0/Kustom/icons/Pause.png,file:/storage/emulated/0/Kustom/icons/Play.png)$

Device is Xiaomi 13T, HyperOS 2 (Android 15). KWGT version is 3.77b435216.

Hi there,

A tips on using an image as a button:

  • Use a global variable of Image type, to store the bitmap data in the preset.
  • Point the image path to that global variable using gv() function, instead of typing the URI of the image path.

By the way, from your code snippet,

$if(mi(state)=PLAYING,file:/storage/emulated/0/Kustom/icons/Pause.png,file:/storage/emulated/0/Kustom/icons/Play.png)$

I think you should write:

file:///storage/ …

Also, make sure the image file does exist in the folder you’re using, and you write the filename correctly.

I hope this would help.
:smiling_face::+1:

1 Like

I made the images global just as you suggested and it works. Haha. Thank you very much for the help.:grin:

1 Like