Use .ico or .png as the image source for controls?

I am developing a WPF application with MS Ribbon Controls. I don’t know which image file format should be used for ribbon controls - mainly between png and ico files, and MSDN does not offer any preferences or recommendations.

Take below as an example:

<ribbon:RibbonButton LargeImageSource="Images\foo.png" Label="Open Foo"/>

OR

<ribbon:RibbonButton LargeImageSource="Images\foo.ico" Label="Open Foo"/>

If I have foo.png (32x32) and foo.ico containing one (32x32) icon, both seem to work the same.

I know that .ico can contain an array of images, and the difference in size (.ico is much larger than .png even if it contains only one icon), so my concern is about rendering it in a different version of the window (XP, Vista , 7, ME, 2000, etc.) And other differences that may affect the user experience that I don’t know about. Somebody knows?

+5
source share
1 answer

I would go with .png because it’s easier to work with, and there are much more tools available that support creating good .png files. I usually use .ico files for the application icon.

I spent some time trying to figure out the shadows and alpha blending on the icons ... Without the right tools, this is nothing more than a disappointment.

, .

+4

All Articles