i couldn’t find any information regarding system tray icons, what size should they be in to get the best possible quality. Should i use more than one size (16×16,32×32,64×64)?
I’m currently using 16×16 .ICO icons and they look disorted.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
They are small icons (
ICON_SMALL). You can find out the size by calling:I think it’s pretty safe to assume that they are square, but if you are paranoid then you can always inquire about
SM_CYSMICON.On my Windows 7 machine they are 16px in size. But if you are using font scaling then they will be larger. For a 125% font scaling (e.g. large fonts) you will need a 20px icon.
If you don’t have a 20px version at hand then the best approach is to generate one on the fly and put your 16px version in the middle of the new 20px icon.
Update
The documentation of
NOTIFYICONDATArecommends usingLoadIconMetricpassingLIM_SMALLwhich is equivalent to the approach I outline above.However, the
NOTIFYICONDATAtopic also says to use an icon resource containing just16px and 32px versions of the icon. That advice is bogus because, as anyone can see for themselves, notification icons under large fonts are 20px icons andLoadIconMetricwill have scale from 32 to 20. I would recommend supplying 16, 20, 24, 32px versions.On XP
LoadIconMetricdoesn’t exist so you’d need to implement a fallback routine.