dotnet / dotnet/dotnet-api-docs
Icon constructor has confusing remarks
- Dominant language
- C#
- Stars
- 949
- Forks
- 1.7k
- Avg merge
- 3d 27m
- Merged PRs (30d)
- 49
Description
https://learn.microsoft.com/en-us/dotnet/api/system.drawing.icon.-ctor
https://github.com/dotnet/dotnet-api-docs/blob/main/xml/System.Drawing/Icon.xml
The remarks for constructors without size specified states:
> # Remarks
> An icon resource can contain multiple icon images. One icon file may contain images in several sizes and color depths. The image that is used in an application depends on the operating system and settings. The following list details the typical sizes for an icon:
> * 16 pixels x 16 pixels
> * 32 pixels x 32 pixels
> * 48 pixels x 48 pixels
>
> This constructor returns the smallest image that is contained in the specified stream.
But some statements are in conflict:
1. The image that is used in an application depends on the operating system and settings.
2. This constructor returns the smallest image that is contained in the specified stream.
If you have a file with sizes specified above and instantiate it on an operating system with **32 pixels x 32 pixels**, the instantiated icon will be **32 pixels x 32 pixels** and not **16 pixels x 16 pixels**. So, **1.** is satisfied, but not **2**.
Contributor guide
Assessment
This issue has not been assessed yet.