Class representing a Fill (background) entry. The Fill entry is used to define background colors and fill patterns.
More...
|
| | Fill () |
| | Default constructor.
|
| | Fill (string foreground, string background) |
| | Constructor with foreground and background color.
|
| | Fill (string value, FillType fillType) |
| | Constructor with color value and fill type.
|
| override string | ToString () |
| | Override toString method.
|
| override AbstractStyle | Copy () |
| | Method to copy the current object to a new one without casting.
|
| override int | GetHashCode () |
| | Returns a hash code for this instance.
|
| override bool | Equals (object obj) |
| | Returns whether two instances are the same.
|
| Fill | CopyFill () |
| | Method to copy the current object to a new one with casting.
|
| void | SetColor (string value, FillType fillType) |
| | Sets the color and the depending on fill type.
|
| AbstractStyle | Copy () |
| | Abstract method to copy a component (dereferencing).
|
| int | CompareTo (AbstractStyle other) |
| | Method to compare two objects for sorting purpose.
|
| bool | Equals (AbstractStyle other) |
| | Method to compare two objects for sorting purpose.
|
|
| string | BackgroundColor [get, set] |
| | Gets or sets the background color of the fill. The value is expressed as hex string with the format AARRGGBB. AA (Alpha) is usually FF. If set, the value will be cast to upper case.
|
| string | ForegroundColor [get, set] |
| | Gets or sets the foreground color of the fill. The value is expressed as hex string with the format AARRGGBB. AA (Alpha) is usually FF. If set, the value will be bast to upper case.
|
| int | IndexedColor [get, set] |
| | Gets or sets the indexed color (Default is 64).
|
| PatternValue | PatternFill [get, set] |
| | Gets or sets the pattern type of the fill (Default is none).
|
| int? | InternalID [get, set] |
| | Gets or sets the internal ID for sorting purpose in the Excel style document (nullable).
|
Class representing a Fill (background) entry. The Fill entry is used to define background colors and fill patterns.
Definition at line 17 of file Fill.cs.
◆ FillType
Enum for the type of the color, used by the Fill class.
| Enumerator |
|---|
| PatternColor | Color defines a pattern color.
|
| FillColor | Color defines a solid fill color.
|
Definition at line 39 of file Fill.cs.
◆ PatternValue
Enum for the pattern values, used by the Fill class.
| Enumerator |
|---|
| None | No pattern (default).
|
| Solid | Solid fill (for colors).
|
| DarkGray | Dark gray fill.
|
| MediumGray | Medium gray fill.
|
| LightGray | Light gray fill.
|
| Gray0625 | 6.25% gray fill
|
| Gray125 | 12.5% gray fill
|
Definition at line 49 of file Fill.cs.
◆ Fill() [1/3]
| NanoXLSX.Styles.Fill.Fill |
( |
| ) |
|
Default constructor.
Definition at line 131 of file Fill.cs.
◆ Fill() [2/3]
| NanoXLSX.Styles.Fill.Fill |
( |
string | foreground, |
|
|
string | background ) |
Constructor with foreground and background color.
- Parameters
-
| foreground | Foreground color of the fill |
| background | Background color of the fill |
Definition at line 143 of file Fill.cs.
◆ Fill() [3/3]
| NanoXLSX.Styles.Fill.Fill |
( |
string | value, |
|
|
FillType | fillType ) |
Constructor with color value and fill type.
- Parameters
-
| value | Color value |
| fillType | Fill type (fill or pattern) |
Definition at line 156 of file Fill.cs.
◆ Copy()
Method to copy the current object to a new one without casting.
- Returns
- Copy of the current object without the internal ID
Definition at line 196 of file Fill.cs.
◆ CopyFill()
| Fill NanoXLSX.Styles.Fill.CopyFill |
( |
| ) |
|
Method to copy the current object to a new one with casting.
- Returns
- Copy of the current object without the internal ID
Definition at line 245 of file Fill.cs.
◆ Equals()
| override bool NanoXLSX.Styles.Fill.Equals |
( |
object | obj | ) |
|
Returns whether two instances are the same.
- Parameters
-
- Returns
- True if this instance and the other are the same
Definition at line 232 of file Fill.cs.
◆ GetHashCode()
| override int NanoXLSX.Styles.Fill.GetHashCode |
( |
| ) |
|
Returns a hash code for this instance.
- Returns
- A hash code for this instance, suitable to be used in hashing algorithms and data structures like a hash table.
Definition at line 214 of file Fill.cs.
◆ SetColor()
| void NanoXLSX.Styles.Fill.SetColor |
( |
string | value, |
|
|
FillType | fillType ) |
Sets the color and the depending on fill type.
- Parameters
-
| value | color value |
| fillType | fill type (fill or pattern) |
Definition at line 255 of file Fill.cs.
◆ ToString()
| override string NanoXLSX.Styles.Fill.ToString |
( |
| ) |
|
Override toString method.
- Returns
- String of a class
Definition at line 179 of file Fill.cs.
◆ DefaultColor
| readonly string NanoXLSX.Styles.Fill.DefaultColor = "FF000000" |
|
static |
Default Color (foreground or background).
Definition at line 23 of file Fill.cs.
◆ DefaultIndexedColor
| readonly int NanoXLSX.Styles.Fill.DefaultIndexedColor = 64 |
|
static |
Default index color.
Definition at line 27 of file Fill.cs.
◆ DefaultPatternFill
Default pattern.
Definition at line 31 of file Fill.cs.
◆ BackgroundColor
| string NanoXLSX.Styles.Fill.BackgroundColor |
|
getset |
Gets or sets the background color of the fill. The value is expressed as hex string with the format AARRGGBB. AA (Alpha) is usually FF. If set, the value will be cast to upper case.
Definition at line 83 of file Fill.cs.
◆ ForegroundColor
| string NanoXLSX.Styles.Fill.ForegroundColor |
|
getset |
Gets or sets the foreground color of the fill. The value is expressed as hex string with the format AARRGGBB. AA (Alpha) is usually FF. If set, the value will be bast to upper case.
Definition at line 102 of file Fill.cs.
◆ IndexedColor
| int NanoXLSX.Styles.Fill.IndexedColor |
|
getset |
Gets or sets the indexed color (Default is 64).
Definition at line 119 of file Fill.cs.
◆ PatternFill
Gets or sets the pattern type of the fill (Default is none).
Definition at line 124 of file Fill.cs.
The documentation for this class was generated from the following file: