Ich habe eine .ico-Datei mit 5 eingebetteten Symbolgrößen, die als Hauptanwendungssymbol und System Tray-Symbol verwendet wird.Windows wählt falsches Symbol aus der Multi-Icon-Datei und rendert sich selbst auf die richtige Größe
Wenn es in der Taskleiste angezeigt wird, verwendet das Symbol das 16x16-Format, das gewünscht wird. Wenn das Symbol im Infobereich/in der Taskleiste angezeigt wird, verwendet es das 32x32-Format und Windows rendert es auf ein 16x16-Symbol herunter, das schrecklich aussieht.
Wie erzwinge ich Windows, die Symbolgröße 16 x 16 im Infobereich zu verwenden? Hier ist mein Code auf das Symbol in der Taskleiste zu setzen:
ContextMenu cmNotify = new ContextMenu();
MenuItem miNotify = new MenuItem(Properties.Resources.Notify_Text);
miNotify.DefaultItem = true;
miNotify.Click += new EventHandler(notifyHandler);
cmNotify.MenuItems.Add(miNotify);
notifyIcon = new NotifyIcon();
notifyIcon.Icon = this.Icon;
notifyIcon.Visible = true;
notifyIcon.ContextMenu = cmNotify;
notifyIcon.Text = AppConstants.APPLICATION_NAME;