Class ExcelDrawingGradientFillColorList
A collection of colors and their positions used for a gradiant fill.
Inheritance
Implements
Inherited Members
Namespace: OfficeOpenXml.Drawing.Style.Fill
Assembly: EPPlus.dll
Syntax
public class ExcelDrawingGradientFillColorList : IEnumerable<ExcelDrawingGradientFillColor>, IEnumerable
Properties
Count
Number of items in the collection
Declaration
public int Count { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Item[Double]
Gets the first occurance with the color with the specified position
Declaration
public ExcelDrawingGradientFillColor this[double position] { get; }
Parameters
Type | Name | Description |
---|---|---|
System.Double | position | The position in percentage |
Property Value
Type | Description |
---|---|
ExcelDrawingGradientFillColor | The color |
Item[Int32]
Indexer for the collection
Declaration
public ExcelDrawingGradientFillColor this[int index] { get; }
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | The index in the collection |
Property Value
Type | Description |
---|---|
ExcelDrawingGradientFillColor | The color |
Methods
AddHsl(Double, Double, Double, Double)
Adds a HSL color at the specified position
Declaration
public void AddHsl(double position, double hue, double saturation, double luminance)
Parameters
Type | Name | Description |
---|---|---|
System.Double | position | The position |
System.Double | hue | The hue part. Ranges from 0-360 |
System.Double | saturation | The saturation part. Percentage |
System.Double | luminance | The luminance part. Percentage |
AddPreset(Double, ePresetColor)
Adds a HSL color at the specified position
Declaration
public void AddPreset(double position, ePresetColor color)
Parameters
Type | Name | Description |
---|---|---|
System.Double | position | The position |
ePresetColor | color | The preset color |
AddRgb(Double, Color)
Adds a RGB color at the specified position
Declaration
public void AddRgb(double position, Color color)
Parameters
Type | Name | Description |
---|---|---|
System.Double | position | The position |
System.Drawing.Color | color | The Color |
AddRgbPercentage(Double, Double, Double, Double)
Adds a RGB percentage color at the specified position
Declaration
public void AddRgbPercentage(double position, double redPercentage, double greenPercentage, double bluePercentage)
Parameters
Type | Name | Description |
---|---|---|
System.Double | position | The position |
System.Double | redPercentage | The percentage of red |
System.Double | greenPercentage | The percentage of green |
System.Double | bluePercentage | The percentage of blue |
AddScheme(Double, eSchemeColor)
Adds a theme color at the specified position
Declaration
public void AddScheme(double position, eSchemeColor color)
Parameters
Type | Name | Description |
---|---|---|
System.Double | position | The position |
eSchemeColor | color | The theme color |
AddSystem(Double, eSystemColor)
Adds a system color at the specified position
Declaration
public void AddSystem(double position, eSystemColor color)
Parameters
Type | Name | Description |
---|---|---|
System.Double | position | The position |
eSystemColor | color | The system color |
GetEnumerator()
Gets the enumerator for the collection
Declaration
public IEnumerator<ExcelDrawingGradientFillColor> GetEnumerator()
Returns
Type | Description |
---|---|
System.Collections.Generic.IEnumerator<ExcelDrawingGradientFillColor> | The enumerator |
Explicit Interface Implementations
IEnumerable.GetEnumerator()
Declaration
IEnumerator IEnumerable.GetEnumerator()
Returns
Type | Description |
---|---|
System.Collections.IEnumerator |