Skip to content

Class ExcelDrawingGradientFillColorList

Namespace: OfficeOpenXml.Drawing.Style.Fill
Assembly: EPPlus.dll

A collection of colors and their positions used for a gradiant fill.

public class ExcelDrawingGradientFillColorList : IEnumerable<ExcelDrawingGradientFillColor>, IEnumerable

Inheritance

object ← ExcelDrawingGradientFillColorList

Implements

IEnumerable
IEnumerable<ExcelDrawingGradientFillColor>

Inherited Members

object.Equals(object?, object?)
object.Equals(object?)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object?, object?)
object.ToString()

Properties

Count

Number of items in the collection

public int Count { get; }

Property Value

int

this[int]

Indexer for the collection

public ExcelDrawingGradientFillColor this[int index] { get; }

Property Value

ExcelDrawingGradientFillColor

this[double]

Gets the first occurance with the color with the specified position

public ExcelDrawingGradientFillColor this[double position] { get; }

Property Value

ExcelDrawingGradientFillColor

Methods

AddHsl(double, double, double, double)

Adds a HSL color at the specified position

public void AddHsl(double position, double hue, double saturation, double luminance)

Parameters

position double

The position

hue double

The hue part. Ranges from 0-360

saturation double

The saturation part. Percentage

luminance double

The luminance part. Percentage

AddPreset(double, ePresetColor)

Adds a HSL color at the specified position

public void AddPreset(double position, ePresetColor color)

Parameters

position double

The position

color ePresetColor

The preset color

AddRgb(double, Color)

Adds a RGB color at the specified position

public void AddRgb(double position, Color color)

Parameters

position double

The position

color Color

The Color

AddRgbPercentage(double, double, double, double)

Adds a RGB percentage color at the specified position

public void AddRgbPercentage(double position, double redPercentage, double greenPercentage, double bluePercentage)

Parameters

position double

The position

redPercentage double

The percentage of red

greenPercentage double

The percentage of green

bluePercentage double

The percentage of blue

AddScheme(double, eSchemeColor)

Adds a theme color at the specified position

public void AddScheme(double position, eSchemeColor color)

Parameters

position double

The position

color eSchemeColor

The theme color

AddSystem(double, eSystemColor)

Adds a system color at the specified position

public void AddSystem(double position, eSystemColor color)

Parameters

position double

The position

color eSystemColor

The system color

GetEnumerator()

Gets the enumerator for the collection

public IEnumerator<ExcelDrawingGradientFillColor> GetEnumerator()

Returns

IEnumerator<ExcelDrawingGradientFillColor>

The enumerator