221 if (colorIndex < 0 || colorIndex > 65)
223 throw new StyleException(
"Indexed color value must be between 0 and 65.");
253 switch (indexedValue)
268 case Value.BrightGreen3:
269 case Value.BrightGreen:
279 case Value.StrongYellow:
284 case Value.StrongMagenta:
289 case Value.StrongCyan:
294 case Value.DarkMaroon:
297 case Value.DarkGreen:
308 case Value.DarkViolet:
315 case Value.LightGray:
321 case Value.LightCornflowerBlue:
325 case Value.DarkRoseDuplicate:
328 case Value.LightYellow:
331 case Value.LightCyan:
335 case Value.DarkPurple:
341 case Value.MediumBlue:
344 case Value.LightLavender:
350 case Value.LightMint:
353 case Value.PastelYellow:
356 case Value.LightSkyBlue:
368 case Value.RoyalBlue:
371 case Value.Turquoise:
374 case Value.LightOlive:
383 case Value.DarkOrange:
389 case Value.MediumGray:
392 case Value.DarkSlateBlue:
398 case Value.VeryDarkGreen:
401 case Value.DarkOlive:
410 case Value.VeryDarkGray:
413 case Value.SystemBackground:
Class representing an indexed color from the legacy OOXML / Excel indexed color palette.
IndexedColor()
Default constructor with default indexed color.
Value ColorValue
Value of the indexed color.
IndexedColor(Value color)
Constructor with specified indexed color value.
string GetArgbValue()
Gets the ARGB hex code representation of the indexed color.
string StringValue
String representation of the indexed color value.
const string DefaultSystemBackgroundColorArgb
Default ARGB value for system background color.
static string GetArgbValue(Value indexedValue)
Maps the indexed color value to its ARGB hex code representation.
override int GetHashCode()
Gets the hash code of the instance.
Value
Legacy OOXML / Excel indexed color palette.
@ Magenta6
Magenta (duplicate of index 14).
@ DarkOrange
Dark orange (FF6600).
@ Cyan
Cyan / Aqua (#00FFFF).
@ DarkSlateBlue
Dark slate blue (#003366).
@ Yellow5
Yellow (duplicate of index 13).
@ Rose
Rose pink (FF99CC).
@ Cyan7
Cyan (duplicate of index 15).
@ Navy
Dark navy blue (#000080).
@ MediumGray
Medium gray (#969696).
@ White1
White (duplicate of index 9).
@ Blue4
Blue (duplicate of index 12).
@ SeaGreen
Sea green (#339966).
@ VeryDarkGray
Very dark gray (#333333).
@ Black0
Black (duplicate of index 8).
@ RoyalBlue
Royal blue (#3366FF).
@ PureBlue
Pure blue (#0000FF).
@ DarkRoseDuplicate
Dark rose (duplicate of index 25).
@ PastelYellow
Light pastel yellow (FFFF99).
@ SystemBackground
System background color.
@ SystemForeground
System foreground color.
@ LightLavender
Light lavender blue (CCCCFF).
@ LightOlive
Light olive green (#99CC00).
@ PaleCyan
Pale cyan (CCFFFF).
@ StrongCyan
Strong cyan (#00FFFF).
@ DarkRed
Dark red / maroon (#800000).
@ DarkBlue
Dark blue / navy (#000080).
@ Indigo
Indigo / dark blue-purple (#333399).
@ DarkOlive
Dark olive (#333300).
@ Gray
Medium gray (#808080).
@ DarkTeal
Dark teal (#008080).
@ BrightGreen3
Bright green (duplicate of index 11).
@ LightMint
Light mint green (CCFFCC).
@ MediumBlue
Medium blue (#0066CC).
@ BrightGreen
Bright green (#00FF00).
@ Magenta
Magenta / Fuchsia (FF00FF).
@ Purple
Purple (#800080).
@ DarkPurple
Dark purple (#660066).
@ LightCyan
Light cyan (CCFFFF).
@ DarkRose
Dark rose (#993366).
@ SkyBlue
Sky blue (#00CCFF).
@ BlueGray
Blue gray (#666699).
@ Turquoise
Turquoise (#33CCCC).
@ LightSkyBlue
Light sky blue (#99CCFF).
@ Salmon
Salmon pink (FF8080).
@ Lavender
Lavender (CC99FF).
@ Red2
Red (duplicate of index 10).
@ StrongYellow
Strong yellow (FFFF00).
@ StrongMagenta
Strong magenta (FF00FF).
@ VeryDarkGreen
Very dark green (#003300).
@ DarkGreen
Dark green (#008000).
@ LightYellow
Light yellow (FFFFCC).
@ DarkViolet
Dark violet (#800080).
@ LightGray
Light gray / silver (C0C0C0).
@ DarkMaroon
Dark maroon (#800000).
@ LightCornflowerBlue
Light cornflower blue (#9999FF).
SrgbColor GetSrgbColor()
Gets the sRGB color representation of the indexed color.
const Value DefaultIndexedColor
Default indexed color (system foreground color).
IndexedColor(int colorIndex)
Constructor with specified indexed color index.
override bool Equals(object obj)
Determines whether the specified object is equal to the current object.
const string DefaultSystemForegroundColorArgb
Default ARGB value for system foreground color.
Class representing a generic sRGB color (with or without alpha channel).
Class for exceptions regarding Style incidents.
Class providing static methods to parse string values to specific types or to print object as languag...
static string ToString(int input)
Transforms an integer to an invariant sting.