User forums > Using Code::Blocks
Application icon wxWidgets/Windows
(1/1)
jeancf:
Hi,
I have written a wxWidgets application under MS Windows. I would like to compile it with a custom icon for the application (i.e. I want my own icon visible in the file manager on the .exe file) but I can't find out how to do it with CodeBlocks.
Can you let me know where to specify that option?
Thanks,
/~jc
Biplab:
Did you use wxWidgets wizard?
If, yes open the resource.rc file in C::B. Change the following line
--- Code: ---aaaa ICON "wx/msw/std.ico"
--- End code ---
To
--- Code: ---aaaa ICON "<Path_to_your_icon>/<Your_icon>.ico"
--- End code ---
If not, then create a file with the above content and above name and add it to your project.
Regards,
Biplab :)
jeancf:
Thanks! It worked.
I thought it was an option that needed to be set in the C::B project. I am a bit puzzled by the "aaaa" though. what does that correspond to?
/~jc
Biplab:
AFAIK, if there are multiple icons in a resource file Windows sets the first Icon as Program Icon. Windows determines this by Icon Names (Alphabetically). Thus aaaa will ensure that this comes first in search and thus I've used that peculiar one. ;)
Regards,
Biplab
jeancf:
It makes sense. Thanks a lot for your help.
Navigation
[0] Message Index
Go to full version