WinForms .NET 2.0: How to paint the proper sized icon?
问题 i have an ico file that contains a 48x48 and a 256x256 Vista PNG version (as well as the 32x32 and 16x16 versions). i want to draw the icon using the appropriate internal size version. i've tried: Icon ico = Properties.Resources.TestIcon; e.Graphics.DrawIcon(ico, new Rectangle(0, 0, 48, 48)); e.Graphics.DrawIcon(ico, new Rectangle(48, 0, 256, 256)); But they draw the 32x32 version blown up to 48x48 and 256x256 respectively. i've tried: Icon ico = Properties.Resources.TestIcon; e.Graphics