dahall / AeroWizard

Library for easy creation of custom and Aero Wizards. Aero Wizard strictly follows Microsoft guidelines and uses Visual Styles to get visual theming.
MIT License
112 stars 32 forks source link

TitleIcon selects wrong size icon. #50

Closed dahall closed 5 years ago

dahall commented 5 years ago

If icon that is specified for TitleIcon property has more sizes in it for example 64x64, 32x32, 24x24, 16x16, then the biggest size icon will be used and just resized. This results in crappy looking icon. Worked around that by creating a new icon object forcing to select 16x16 size icon from icon file.

    /// <summary>
    /// Gets or sets the optionally displayed icon next to the wizard title.
    /// </summary>
    /// <value>The title icon.</value>
    [Category("Wizard"), Localizable(true), Description("Icon next to the wizard title")]
    public Icon TitleIcon
    {
        get
        {
            return this.titleImageIcon;
        }

        set
        {
            this.titleImageIcon = value;
            this.titleImageList.Images.Clear();
            if (this.titleImageIcon != null)
            {
                this.titleImageList.Images.Add(new Icon(value, 16, 16));
                this.titleImage.ImageIndex = 0;
            }

            this.titleImageIconSet = true;
            this.Invalidate();
        }
    }

Originally posted: 2013-02-08T07:54:34

dahall commented 5 years ago

Thanks for catching this bug. I have implemented it in version 1.2.4.

Originally posted: 2013-02-08T08:58:58