StudioCherno / Walnut

Walnut is a simple application framework for Vulkan and Dear ImGui apps
MIT License
1.99k stars 367 forks source link

How to change icon?? #61

Open boshkaoff opened 9 months ago

boshkaoff commented 9 months ago

help pls...

Acromatic commented 9 months ago

in visual studio press ctrl+shift+e, this will bring up resource view... now select walnnutapp on the left, right click that and add->resource... this will create an icon1.ico and a few other files in your source folder (move them into your source folder and re-add if needed). it contains binding files with linking directives to the .ico image file, which is really just a bitmap with different icon resolution sizes 256, 128, 64, 32, 16, etc.. once you get it compiled and working with your edited images change the size of the icons in windows with ctrl+scroll wheel to see the different sizes so yours can appear, you'll need a properly formed one to get windows icons fully working. you can edit that file any way you like as long as you don't rename it without changing the linking in walnutapp.rc also you might have trouble viewing that files code, right click on it and "view code" for that.

boshkaoff commented 9 months ago

i mean i want to change logo in app, not icon in windows that shows in taskbar

Acromatic commented 7 months ago

replace the image file with same name, or you can code a new name.

auzden commented 7 months ago

I wrote a Python script to convert a PNG to a Walnut-Icon.embed file that you can replace in Platform/GUI/Walnut/Embed

https://gist.github.com/auzden/9bea709c4fb1985849a3dcc46cdcb4e4