What is the size of the icons in the system tray?

2019-03-16 21:27发布

This question already has an answer here:

I want to change the notification icon of my application but don't know what is the size so as to make it properly displayed. Currently it is automatically resized and break my pixels! Please help!

7条回答
别忘想泡老子
2楼-- · 2019-03-16 22:06

For XP it's 16 x 16

查看更多
Viruses.
3楼-- · 2019-03-16 22:08

In fact the size of the icon will vary according to the system DPI.

WPF exposes the recommended pixel width and height of small icons with SystemParameters.SmallIconWidth and SystemParameters.SmallIconHeight. (WinForms exposes the equivalent SystemInformation.SmallIconSize - both just wrap around GetSystemMetrics and SM_CXSMICON/SM_CYSMICON.)

Microsoft recommends including 16x16 and 32x32 pixel icons.

查看更多
够拽才男人
4楼-- · 2019-03-16 22:08

I believe it has always been 16x16, but at some point between 98 and XP (Maybe it was CE vs NT?) they learned to support full color and alpha transparency. If you can, try to include a 256 color palleted version in the ICO for safe mode if not older versions of Windows.

查看更多
等我变得足够好
5楼-- · 2019-03-16 22:10

Outlook has an 16*16 pixels icon.

查看更多
疯言疯语
6楼-- · 2019-03-16 22:10

Windows 7 has 16*16 pixels icons in system tray.

查看更多
混吃等死
7楼-- · 2019-03-16 22:11

It's 16x16. If you create a .ico file that supports 16, 32, 48 and 256 sizes, you're covered.

查看更多
登录 后发表回答