Class WordColor
The class WordColor implements routines working with Color.
Inheritance
Namespace: Syncfusion.DocIO.DLS
Assembly: Syncfusion.DocIO.Base.dll
Syntax
public class WordColor : Object
Constructors
WordColor(Byte)
Initializes a new instance of the WordColor class with known color index.
Declaration
public WordColor(byte index)
Parameters
Type | Name | Description |
---|---|---|
System.Byte | index | The byte index represents the index of the known color. |
Properties
Black
Gets Black color. Read-only.
Declaration
public static WordColor Black { get; }
Property Value
Type |
---|
WordColor |
Blue
Gets Blue color. Read-only.
Declaration
public static WordColor Blue { get; }
Property Value
Type |
---|
WordColor |
Color
Gets the system Color. Read-only.
Declaration
public Color Color { get; }
Property Value
Type |
---|
System.Drawing.Color |
ColorId
Gets the byte value for a Color. Read-only.
Declaration
public byte ColorId { get; }
Property Value
Type |
---|
System.Byte |
Cyan
Gets Cyan color. Read-only.
Declaration
public static WordColor Cyan { get; }
Property Value
Type |
---|
WordColor |
DarkBlue
Gets DarkBlue color. Read-only.
Declaration
public static WordColor DarkBlue { get; }
Property Value
Type |
---|
WordColor |
DarkCyan
Gets DarkCyan color. Read-only.
Declaration
public static WordColor DarkCyan { get; }
Property Value
Type |
---|
WordColor |
DarkGray
Gets DarkGray color. Read-only.
Declaration
public static WordColor DarkGray { get; }
Property Value
Type |
---|
WordColor |
DarkGreen
Gets DarkGreen color. Read-only.
Declaration
public static WordColor DarkGreen { get; }
Property Value
Type |
---|
WordColor |
DarkMagenta
Gets DarkMagenta color. Read-only.
Declaration
public static WordColor DarkMagenta { get; }
Property Value
Type |
---|
WordColor |
DarkRed
Gets DarkRed color. Read-only.
Declaration
public static WordColor DarkRed { get; }
Property Value
Type |
---|
WordColor |
DarkYellow
Gets DarkYellow color. Read-only.
Declaration
public static WordColor DarkYellow { get; }
Property Value
Type |
---|
WordColor |
Empty
Gets the a null color.
Declaration
public static WordColor Empty { get; }
Property Value
Type |
---|
WordColor |
Green
Gets Green color. Read-only.
Declaration
public static WordColor Green { get; }
Property Value
Type |
---|
WordColor |
LightGray
Gets LightGray color. Read-only.
Declaration
public static WordColor LightGray { get; }
Property Value
Type |
---|
WordColor |
Magenta
Gets Magenta color. Read-only.
Declaration
public static WordColor Magenta { get; }
Property Value
Type |
---|
WordColor |
Red
Gets Red color. Read-only.
Declaration
public static WordColor Red { get; }
Property Value
Type |
---|
WordColor |
RGB
Gets RGB Color. Read-only.
Declaration
public int RGB { get; }
Property Value
Type |
---|
System.Int32 |
White
Gets White color. Read-only.
Declaration
public static WordColor White { get; }
Property Value
Type |
---|
WordColor |
Yellow
Gets Yellow color. Read-only.
Declaration
public static WordColor Yellow { get; }
Property Value
Type |
---|
WordColor |
Methods
ColorToId(Color)
Converts the Color value as an integer value.
Declaration
public static int ColorToId(Color color)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Color | color | Specifies Color value. |
Returns
Type | Description |
---|---|
System.Int32 | Returns the corresponding ID value of the color. |
ConvertColorToId(Color)
Converts the Color as a color ID.
Declaration
public static int ConvertColorToId(Color color)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Color | color | Specifies Color value. |
Returns
Type | Description |
---|---|
System.Int32 | Returns color ID. |
ConvertColorToRGB(Color)
Converts the color to RGB.
Declaration
public static uint ConvertColorToRGB(Color color)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Color | color | Specifies the Color value. |
Returns
Type | Description |
---|---|
System.UInt32 | Returns the converted RGB value. |
ConvertColorToRGB(Color, Boolean)
Converts the color to RGB.
Declaration
public static uint ConvertColorToRGB(Color color, bool ignoreAlpha)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Color | color | The color. |
System.Boolean | ignoreAlpha | If set to |
Returns
Type | Description |
---|---|
System.UInt32 | Returns the converted RGB value. |
ConvertIdToColor(Int32)
Gets the Color value for a specified ID.
Declaration
public static Color ConvertIdToColor(int id)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | id | Specifies Color ID value. |
Returns
Type | Description |
---|---|
System.Drawing.Color | Returns Color value/. |
ConvertIdToRGB(Int32)
Converts the specified ID value as RGB value.
Declaration
public static uint ConvertIdToRGB(int colorId)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | colorId | Color identification value. |
Returns
Type | Description |
---|---|
System.UInt32 | Returns RGB value. |
ConvertRGBToColor(UInt32)
Converts the RGB as Color value.
Declaration
public static Color ConvertRGBToColor(uint rgb)
Parameters
Type | Name | Description |
---|---|---|
System.UInt32 | rgb | RGB Value. |
Returns
Type | Description |
---|---|
System.Drawing.Color | Returns Color value. |
ConvertRGBToId(UInt32)
Converts RGB value as int value.
Declaration
public static int ConvertRGBToId(uint rgb)
Parameters
Type | Name | Description |
---|---|---|
System.UInt32 | rgb | Specifies RGB value. |
Returns
Type | Description |
---|---|
System.Int32 | Returns the ID value for a specified RGB. |
IdToColor(Int32)
Returns the Color value for the specified color ID.
Declaration
public static Color IdToColor(int wordColorId)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | wordColorId | Specifies color ID. |
Returns
Type | Description |
---|---|
System.Drawing.Color | Returns the Color value. |
InverseColor(Color)
Inverses the color.
Declaration
public static Color InverseColor(Color color)
Parameters
Type | Name | Description |
---|---|---|
System.Drawing.Color | color | The color. |
Returns
Type |
---|
System.Drawing.Color |