Color structure is a value type that
represents a point in the RGB color space, with optional support for
a transparency alpha channel.
You can obtain the value of a particular
using one of the static properties that return a well-known web
FromArgb() allows you to
define a specific color from its red, green, blue, and alpha
FromKnownColor() allows you to create
Color from an entry in
KnownColor enumeration, and
FromName() takes a string containing the name of well-known color.
There is also a special field,
represents a null color. This is necessary because
Color is a value type, and therefore nullness
cannot be represented by a null reference. It is usually used when a
class can optionally inherit its color from an ambient property
ForeColor of a
Control is inherited from its
Parent if set to
IsEmpty property allows you to check for nullness.
There are properties that allow you to retrieve the
B values of the color, and the
Name (either the
well-known name or a string description of the ARGB values as
appropriate). In addition, there are methods—
GetBrightness()—to transform the values to
the HSB color space.
If you need to know whether a color is well-known, you can use the
Color structure is used pervasively throughout
the framework wherever color is needed.
public struct ...