Color Structure

Represents an ARGB (alpha, red, green, blue) color.

Namespace:  System.Drawing
Assembly:  Aspose.Drawing (in Aspose.Drawing.dll) Version: 20.9.0.0 (20.9.0)
Syntax
C#
public struct Color : IEquatable<Color>

The Color type exposes the following members.

Properties
  NameDescription
Public propertyA
Gets the alpha component value of this Color structure.
Public propertyStatic memberAliceBlue
Gets a system-defined color that has an ARGB value of #FFF0F8FF.
Public propertyStatic memberAntiqueWhite
Gets a system-defined color that has an ARGB value of #FFFAEBD7.
Public propertyStatic memberAqua
Gets a system-defined color that has an ARGB value of #FF00FFFF.
Public propertyStatic memberAquamarine
Gets a system-defined color that has an ARGB value of #FF7FFFD4.
Public propertyStatic memberAzure
Gets a system-defined color that has an ARGB value of #FFF0FFFF.
Public propertyB
Gets the blue component value of this Color structure.
Public propertyStatic memberBeige
Gets a system-defined color that has an ARGB value of #FFF5F5DC.
Public propertyStatic memberBisque
Gets a system-defined color that has an ARGB value of #FFFFE4C4.
Public propertyStatic memberBlack
Gets a system-defined color that has an ARGB value of #FF000000.
Public propertyStatic memberBlanchedAlmond
Gets a system-defined color that has an ARGB value of #FFFFEBCD.
Public propertyStatic memberBlue
Gets a system-defined color that has an ARGB value of #FF0000FF.
Public propertyStatic memberBlueViolet
Gets a system-defined color that has an ARGB value of #FF8A2BE2.
Public propertyStatic memberBrown
Gets a system-defined color that has an ARGB value of #FFA52A2A.
Public propertyStatic memberBurlyWood
Gets a system-defined color that has an ARGB value of #FFDEB887.
Public propertyStatic memberCadetBlue
Gets a system-defined color that has an ARGB value of #FF5F9EA0.
Public propertyStatic memberChartreuse
Gets a system-defined color that has an ARGB value of #FF7FFF00.
Public propertyStatic memberChocolate
Gets a system-defined color that has an ARGB value of #FFD2691E.
Public propertyStatic memberCoral
Gets a system-defined color that has an ARGB value of #FFFF7F50.
Public propertyStatic memberCornflowerBlue
Gets a system-defined color that has an ARGB value of #FF6495ED.
Public propertyStatic memberCornsilk
Gets a system-defined color that has an ARGB value of #FFFFF8DC.
Public propertyStatic memberCrimson
Gets a system-defined color that has an ARGB value of #FFDC143C.
Public propertyStatic memberCyan
Gets a system-defined color that has an ARGB value of #FF00FFFF.
Public propertyStatic memberDarkBlue
Gets a system-defined color that has an ARGB value of #FF00008B.
Public propertyStatic memberDarkCyan
Gets a system-defined color that has an ARGB value of #FF008B8B.
Public propertyStatic memberDarkGoldenrod
Gets a system-defined color that has an ARGB value of #FFB8860B.
Public propertyStatic memberDarkGray
Gets a system-defined color that has an ARGB value of #FFA9A9A9.
Public propertyStatic memberDarkGreen
Gets a system-defined color that has an ARGB value of #FF006400.
Public propertyStatic memberDarkKhaki
Gets a system-defined color that has an ARGB value of #FFBDB76B.
Public propertyStatic memberDarkMagenta
Gets a system-defined color that has an ARGB value of #FF8B008B.
Public propertyStatic memberDarkOliveGreen
Gets a system-defined color that has an ARGB value of #FF556B2F.
Public propertyStatic memberDarkOrange
Gets a system-defined color that has an ARGB value of #FFFF8C00.
Public propertyStatic memberDarkOrchid
Gets a system-defined color that has an ARGB value of #FF9932CC.
Public propertyStatic memberDarkRed
Gets a system-defined color that has an ARGB value of #FF8B0000.
Public propertyStatic memberDarkSalmon
Gets a system-defined color that has an ARGB value of #FFE9967A.
Public propertyStatic memberDarkSeaGreen
Gets a system-defined color that has an ARGB value of #FF8FBC8F.
Public propertyStatic memberDarkSlateBlue
Gets a system-defined color that has an ARGB value of #FF483D8B.
Public propertyStatic memberDarkSlateGray
Gets a system-defined color that has an ARGB value of #FF2F4F4F.
Public propertyStatic memberDarkTurquoise
Gets a system-defined color that has an ARGB value of #FF00CED1.
Public propertyStatic memberDarkViolet
Gets a system-defined color that has an ARGB value of #FF9400D3.
Public propertyStatic memberDeepPink
Gets a system-defined color that has an ARGB value of #FFFF1493.
Public propertyStatic memberDeepSkyBlue
Gets a system-defined color that has an ARGB value of #FF00BFFF.
Public propertyStatic memberDimGray
Gets a system-defined color that has an ARGB value of #FF696969.
Public propertyStatic memberDodgerBlue
Gets a system-defined color that has an ARGB value of #FF1E90FF.
Public propertyStatic memberFirebrick
Gets a system-defined color that has an ARGB value of #FFB22222.
Public propertyStatic memberFloralWhite
Gets a system-defined color that has an ARGB value of #FFFFFAF0.
Public propertyStatic memberForestGreen
Gets a system-defined color that has an ARGB value of #FF228B22.
Public propertyStatic memberFuchsia
Gets a system-defined color that has an ARGB value of #FFFF00FF.
Public propertyG
Gets the green component value of this Color structure.
Public propertyStatic memberGainsboro
Gets a system-defined color that has an ARGB value of #FFDCDCDC.
Public propertyStatic memberGhostWhite
Gets a system-defined color that has an ARGB value of #FFF8F8FF.
Public propertyStatic memberGold
Gets a system-defined color that has an ARGB value of #FFFFD700.
Public propertyStatic memberGoldenrod
Gets a system-defined color that has an ARGB value of #FFDAA520.
Public propertyStatic memberGray
Gets a system-defined color that has an ARGB value of #FF808080.
Public propertyStatic memberGreen
Gets a system-defined color that has an ARGB value of #FF008000.
Public propertyStatic memberGreenYellow
Gets a system-defined color that has an ARGB value of #FFADFF2F.
Public propertyStatic memberHoneydew
Gets a system-defined color that has an ARGB value of #FFF0FFF0.
Public propertyStatic memberHotPink
Gets a system-defined color that has an ARGB value of #FFFF69B4.
Public propertyStatic memberIndianRed
Gets a system-defined color that has an ARGB value of #FFCD5C5C.
Public propertyStatic memberIndigo
Gets a system-defined color that has an ARGB value of #FF4B0082.
Public propertyIsEmpty
Gets a value indicating whether this Color structure is uninitialized.
Public propertyIsKnownColor
Gets a value indicating whether this Color structure is a predefined color. Predefined colors are represented by the elements of the KnownColor enumeration.
Public propertyIsNamedColor
Gets a value indicating whether this Color structure is a named color or a member of the KnownColor enumeration.
Public propertyIsSystemColor
Gets a value indicating whether this Color structure is a system color. A system color is a color that is used in a Windows display element. System colors are represented by elements of the KnownColor enumeration.
Public propertyStatic memberIvory
Gets a system-defined color that has an ARGB value of #FFFFFFF0.
Public propertyStatic memberKhaki
Gets a system-defined color that has an ARGB value of #FFF0E68C.
Public propertyStatic memberLavender
Gets a system-defined color that has an ARGB value of #FFE6E6FA.
Public propertyStatic memberLavenderBlush
Gets a system-defined color that has an ARGB value of #FFFFF0F5.
Public propertyStatic memberLawnGreen
Gets a system-defined color that has an ARGB value of #FF7CFC00.
Public propertyStatic memberLemonChiffon
Gets a system-defined color that has an ARGB value of #FFFFFACD.
Public propertyStatic memberLightBlue
Gets a system-defined color that has an ARGB value of #FFADD8E6.
Public propertyStatic memberLightCoral
Gets a system-defined color that has an ARGB value of #FFF08080.
Public propertyStatic memberLightCyan
Gets a system-defined color that has an ARGB value of #FFE0FFFF.
Public propertyStatic memberLightGoldenrodYellow
Gets a system-defined color that has an ARGB value of #FFFAFAD2.
Public propertyStatic memberLightGray
Gets a system-defined color that has an ARGB value of #FFD3D3D3.
Public propertyStatic memberLightGreen
Gets a system-defined color that has an ARGB value of #FF90EE90.
Public propertyStatic memberLightPink
Gets a system-defined color that has an ARGB value of #FFFFB6C1.
Public propertyStatic memberLightSalmon
Gets a system-defined color that has an ARGB value of #FFFFA07A.
Public propertyStatic memberLightSeaGreen
Gets a system-defined color that has an ARGB value of #FF20B2AA.
Public propertyStatic memberLightSkyBlue
Gets a system-defined color that has an ARGB value of #FF87CEFA.
Public propertyStatic memberLightSlateGray
Gets a system-defined color that has an ARGB value of #FF778899.
Public propertyStatic memberLightSteelBlue
Gets a system-defined color that has an ARGB value of #FFB0C4DE.
Public propertyStatic memberLightYellow
Gets a system-defined color that has an ARGB value of #FFFFFFE0.
Public propertyStatic memberLime
Gets a system-defined color that has an ARGB value of #FF00FF00.
Public propertyStatic memberLimeGreen
Gets a system-defined color that has an ARGB value of #FF32CD32.
Public propertyStatic memberLinen
Gets a system-defined color that has an ARGB value of #FFFAF0E6.
Public propertyStatic memberMagenta
Gets a system-defined color that has an ARGB value of #FFFF00FF.
Public propertyStatic memberMaroon
Gets a system-defined color that has an ARGB value of #FF800000.
Public propertyStatic memberMediumAquamarine
Gets a system-defined color that has an ARGB value of #FF66CDAA.
Public propertyStatic memberMediumBlue
Gets a system-defined color that has an ARGB value of #FF0000CD.
Public propertyStatic memberMediumOrchid
Gets a system-defined color that has an ARGB value of #FFBA55D3.
Public propertyStatic memberMediumPurple
Gets a system-defined color that has an ARGB value of #FF9370DB.
Public propertyStatic memberMediumSeaGreen
Gets a system-defined color that has an ARGB value of #FF3CB371.
Public propertyStatic memberMediumSlateBlue
Gets a system-defined color that has an ARGB value of #FF7B68EE.
Public propertyStatic memberMediumSpringGreen
Gets a system-defined color that has an ARGB value of #FF00FA9A.
Public propertyStatic memberMediumTurquoise
Gets a system-defined color that has an ARGB value of #FF48D1CC.
Public propertyStatic memberMediumVioletRed
Gets a system-defined color that has an ARGB value of #FFC71585.
Public propertyStatic memberMidnightBlue
Gets a system-defined color that has an ARGB value of #FF191970.
Public propertyStatic memberMintCream
Gets a system-defined color that has an ARGB value of #FFF5FFFA.
Public propertyStatic memberMistyRose
Gets a system-defined color that has an ARGB value of #FFFFE4E1.
Public propertyStatic memberMoccasin
Gets a system-defined color that has an ARGB value of #FFFFE4B5.
Public propertyName
Gets the name of this Color.
Public propertyStatic memberNavajoWhite
Gets a system-defined color that has an ARGB value of #FFFFDEAD.
Public propertyStatic memberNavy
Gets a system-defined color that has an ARGB value of #FF000080.
Public propertyStatic memberOldLace
Gets a system-defined color that has an ARGB value of #FFFDF5E6.
Public propertyStatic memberOlive
Gets a system-defined color that has an ARGB value of #FF808000.
Public propertyStatic memberOliveDrab
Gets a system-defined color that has an ARGB value of #FF6B8E23.
Public propertyStatic memberOrange
Gets a system-defined color that has an ARGB value of #FFFFA500.
Public propertyStatic memberOrangeRed
Gets a system-defined color that has an ARGB value of #FFFF4500.
Public propertyStatic memberOrchid
Gets a system-defined color that has an ARGB value of #FFDA70D6.
Public propertyStatic memberPaleGoldenrod
Gets a system-defined color that has an ARGB value of #FFEEE8AA.
Public propertyStatic memberPaleGreen
Gets a system-defined color that has an ARGB value of #FF98FB98.
Public propertyStatic memberPaleTurquoise
Gets a system-defined color that has an ARGB value of #FFAFEEEE.
Public propertyStatic memberPaleVioletRed
Gets a system-defined color that has an ARGB value of #FFDB7093.
Public propertyStatic memberPapayaWhip
Gets a system-defined color that has an ARGB value of #FFFFEFD5.
Public propertyStatic memberPeachPuff
Gets a system-defined color that has an ARGB value of #FFFFDAB9.
Public propertyStatic memberPeru
Gets a system-defined color that has an ARGB value of #FFCD853F.
Public propertyStatic memberPink
Gets a system-defined color that has an ARGB value of #FFFFC0CB.
Public propertyStatic memberPlum
Gets a system-defined color that has an ARGB value of #FFDDA0DD.
Public propertyStatic memberPowderBlue
Gets a system-defined color that has an ARGB value of #FFB0E0E6.
Public propertyStatic memberPurple
Gets a system-defined color that has an ARGB value of #FF800080.
Public propertyR
Gets the red component value of this Color structure.
Public propertyStatic memberRed
Gets a system-defined color that has an ARGB value of #FFFF0000.
Public propertyStatic memberRosyBrown
Gets a system-defined color that has an ARGB value of #FFBC8F8F.
Public propertyStatic memberRoyalBlue
Gets a system-defined color that has an ARGB value of #FF4169E1.
Public propertyStatic memberSaddleBrown
Gets a system-defined color that has an ARGB value of #FF8B4513.
Public propertyStatic memberSalmon
Gets a system-defined color that has an ARGB value of #FFFA8072.
Public propertyStatic memberSandyBrown
Gets a system-defined color that has an ARGB value of #FFF4A460.
Public propertyStatic memberSeaGreen
Gets a system-defined color that has an ARGB value of #FF2E8B57.
Public propertyStatic memberSeaShell
Gets a system-defined color that has an ARGB value of #FFFFF5EE.
Public propertyStatic memberSienna
Gets a system-defined color that has an ARGB value of #FFA0522D.
Public propertyStatic memberSilver
Gets a system-defined color that has an ARGB value of #FFC0C0C0.
Public propertyStatic memberSkyBlue
Gets a system-defined color that has an ARGB value of #FF87CEEB.
Public propertyStatic memberSlateBlue
Gets a system-defined color that has an ARGB value of #FF6A5ACD.
Public propertyStatic memberSlateGray
Gets a system-defined color that has an ARGB value of #FF708090.
Public propertyStatic memberSnow
Gets a system-defined color that has an ARGB value of #FFFFFAFA.
Public propertyStatic memberSpringGreen
Gets a system-defined color that has an ARGB value of #FF00FF7F.
Public propertyStatic memberSteelBlue
Gets a system-defined color that has an ARGB value of #FF4682B4.
Public propertyStatic memberTan
Gets a system-defined color that has an ARGB value of #FFD2B48C.
Public propertyStatic memberTeal
Gets a system-defined color that has an ARGB value of #FF008080.
Public propertyStatic memberThistle
Gets a system-defined color that has an ARGB value of #FFD8BFD8.
Public propertyStatic memberTomato
Gets a system-defined color that has an ARGB value of #FFFF6347.
Public propertyStatic memberTransparent
Gets a system-defined color.
Public propertyStatic memberTurquoise
Gets a system-defined color that has an ARGB value of #FF40E0D0.
Public propertyStatic memberViolet
Gets a system-defined color that has an ARGB value of #FFEE82EE.
Public propertyStatic memberWheat
Gets a system-defined color that has an ARGB value of #FFF5DEB3.
Public propertyStatic memberWhite
Gets a system-defined color that has an ARGB value of #FFFFFFFF.
Public propertyStatic memberWhiteSmoke
Gets a system-defined color that has an ARGB value of #FFF5F5F5.
Public propertyStatic memberYellow
Gets a system-defined color that has an ARGB value of #FFFFFF00.
Public propertyStatic memberYellowGreen
Gets a system-defined color that has an ARGB value of #FF9ACD32.
Methods
  NameDescription
Public methodEquals(Object)
Tests whether the specified object is equivalent to this color.
(Overrides ValueTypeEquals(Object).)
Public methodEquals(Color)
Tests whether the specified color is equivalent to this color.
Public methodStatic memberFromArgb(Int32)
Creates a Color structure from a 32-bit ARGB value.
Public methodStatic memberFromArgb(Int32, Color)
Creates a Color structure from the specified Color structure, but with the new specified alpha value. Although this method allows a 32-bit value to be passed for the alpha value, the value is limited to 8 bits.
Public methodStatic memberFromArgb(Int32, Int32, Int32)
Creates a Color structure from the specified 8-bit color values (red, green, and blue). The alpha value is implicitly 255 (fully opaque). Although this method allows a 32-bit value to be passed for each color component, the value of each component is limited to 8 bits.
Public methodStatic memberFromArgb(Int32, Int32, Int32, Int32)
Creates a Color structure from the four ARGB component (alpha, red, green, and blue) values. Although this method allows a 32-bit value to be passed for each component, the value of each component is limited to 8 bits.
Public methodStatic memberFromKnownColor
Creates a Color structure from the specified predefined color.
Public methodStatic memberFromName
Creates a Color structure from the specified name of a predefined color.
Public methodGetBrightness
Gets the hue-saturation-brightness (HSB) brightness value for this Color structure.
Public methodGetHashCode
Returns a hash code for this instance.
(Overrides ValueTypeGetHashCode.)
Public methodGetHue
Gets the hue-saturation-brightness (HSB) hue value, in degrees, for this Color structure.
Public methodGetSaturation
Gets the hue-saturation-brightness (HSB) saturation value for this Color structure.
Public methodGetType (Inherited from Object.)
Public methodToArgb
Gets the 32-bit ARGB value of this Color structure.
Public methodToKnownColor
Gets the KnownColor value of this Color structure.
Public methodToString
Returns a String that represents this instance.
(Overrides ValueTypeToString.)
Operators
  NameDescription
Public operatorStatic memberEquality
Tests whether two specified Color structures are equivalent.
Public operatorStatic memberInequality
Tests whether two specified Color structures are different.
Fields
  NameDescription
Public fieldStatic memberEmpty
Represents a color that is null.
See Also