221 if (colorIndex < 0 || colorIndex > 65)
223 throw new StyleException(
"Indexed color value must be between 0 and 65.");
274 switch (indexedValue)
289 case Value.BrightGreen3:
290 case Value.BrightGreen:
300 case Value.StrongYellow:
305 case Value.StrongMagenta:
310 case Value.StrongCyan:
315 case Value.DarkMaroon:
318 case Value.DarkGreen:
329 case Value.DarkViolet:
336 case Value.LightGray:
342 case Value.LightCornflowerBlue:
346 case Value.DarkRoseDuplicate:
349 case Value.LightYellow:
352 case Value.LightCyan:
356 case Value.DarkPurple:
362 case Value.MediumBlue:
365 case Value.LightLavender:
371 case Value.LightMint:
374 case Value.PastelYellow:
377 case Value.LightSkyBlue:
389 case Value.RoyalBlue:
392 case Value.Turquoise:
395 case Value.LightOlive:
404 case Value.DarkOrange:
410 case Value.MediumGray:
413 case Value.DarkSlateBlue:
419 case Value.VeryDarkGreen:
422 case Value.DarkOlive:
431 case Value.VeryDarkGray:
434 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.