Skip to content

color.Name returns a hex code instead of the corresponding color name for known colors #14175

@Amy-Li03

Description

@Amy-Li03

.NET version

.NET SDK 11.0.100-alpha.1.25619.109

Did it work in .NET Framework?

No

Did it work in any of the earlier releases of .NET Core or .NET 5+?

No

Issue description

Original feedback: 2671627

In a WinForms app, when the color under the cursor is retrieved, the color name is to be displayed using color.Name. When the color is a known color, say Red, the name displayed is “ffff0000” rather than “red”.

Image

Steps to reproduce

  1. Extract and run the WinForms app
    WinFormsApp56.zip
  2. Click button on form designer
  3. Observe the value of color.Name

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions