Fill
Overview
Fill is a class in Aspose.Words FOSS for .NET.
Represents fill formatting for an object.
This class provides 12 methods for working with Fill objects in .NET programs.
Available methods include: OneColorGradient, Patterned, PresetTextured, SetImage, Solid, TwoColorGradient.
All public members are accessible to any .NET application after installing the Aspose.Words FOSS for .NET package.
Properties: BackColor, BackThemeColor, BackTintAndShade, BaseForeColor, Color, FillType, and 15 more.
Properties
| Name | Type | Access | Description |
|---|---|---|---|
PresetTexture | PresetTexture | Read | Gets a PresetTexture for the fill. |
Pattern | PatternType | Read | Gets a PatternType for the fill. |
TextureAlignment | TextureAlignment | Read/Write | Gets or sets the alignment for tile texture fill. |
Color | Color | Read/Write | Gets or sets a Color object that represents the foreground color for the fill. |
Opacity | double | Read/Write | Gets or sets the degree of opacity of the specified fill as a value between 0.0 (clear) and 1.0 (opaque). |
ImageBytes | byte[] | Read | Gets the raw bytes of the fill texture or pattern. |
ForeColor | Color | Read/Write | Gets or sets a Color object that represents the foreground color for the fill. |
BaseForeColor | Color | Read | Gets a Color object that represents the base foreground color for the fill without any modifiers. |
BackColor | Color | Read/Write | Gets or sets a Color object that represents the background color for the fill. |
ForeThemeColor | ThemeColor | Read/Write | Gets or sets a ThemeColor object that represents the foreground color for the fill. |
BackThemeColor | ThemeColor | Read/Write | Gets or sets a ThemeColor object that represents the background color for the fill. |
ForeTintAndShade | double | Read/Write | Gets or sets a double value that lightens or darkens the foreground color. |
BackTintAndShade | double | Read/Write | Gets or sets a double value that lightens or darkens the background color. |
Visible | bool | Read/Write | Gets or sets value that is true if the formatting applied to this instance, is visible. |
Transparency | double | Read/Write | Gets or sets the degree of transparency of the specified fill as a value between 0.0 (opaque) and 1.0 (clear). |
RotateWithObject | bool | Read/Write | Gets or sets whether the fill rotates with the specified object. |
FillType | FillType | Read | Gets a fill type. |
GradientAngle | double | Read/Write | Gets or sets the angle of the gradient fill. |
GradientVariant | GradientVariant | Read | Gets the gradient variant GradientVariant for the fill. |
GradientStyle | GradientStyle | Read | Gets the gradient style GradientStyle for the fill. |
GradientStops | GradientStopCollection | Read | Gets a collection of GradientStop objects for the fill. |
Methods
| Signature | Description |
|---|---|
Solid() | Sets the fill to a uniform color. |
Solid(color: Color) | Sets the fill to a specified uniform color. |
PresetTextured(presetTexture: PresetTexture) | Sets the fill to a preset texture. |
Patterned(patternType: PatternType) | Sets the specified fill to a pattern. |
Patterned(patternType: PatternType, foreColor: Color, backColor: Color) | Sets the specified fill to a pattern. |
OneColorGradient(style: GradientStyle, variant: GradientVariant, degree: double) | Sets the specified fill to a one-color gradient. |
OneColorGradient(color: Color, style: GradientStyle, variant: GradientVariant, degree: double) | Sets the specified fill to a one-color gradient using the specified color. |
TwoColorGradient(style: GradientStyle, variant: GradientVariant) | Sets the specified fill to a two-color gradient. |
TwoColorGradient(color1: Color, color2: Color, style: GradientStyle, variant: GradientVariant) | Sets the specified fill to a two-color gradient. |
SetImage(fileName: string) | Changes the fill type to single image. |
SetImage(stream: Stream) | Changes the fill type to single image. |
SetImage(imageBytes: byte[]) | Changes the fill type to single image. |