LinearGradientBrush

Ecng.Drawing

Represents a brush that paints a gradient between multiple colors.

Herda de: Brush

Construtores

LinearGradientBrush
public LinearGradientBrush(Color[] linearColors, Rectangle rectangle)
linearGradientBrush = LinearGradientBrush(linearColors, rectangle)

Represents a brush that paints a gradient between multiple colors.

linearColors
An array of colors defining the gradient stops.
rectangle
The rectangle that defines the bounds of the gradient.
LinearGradientBrush
public LinearGradientBrush(Point stop0, Point stop1, Color color0, Color color1)
linearGradientBrush = LinearGradientBrush(stop0, stop1, color0, color1)

Initializes a new instance of the LinearGradientBrush class using two points and two colors.

stop0
The first point of the gradient.
stop1
The second point of the gradient.
color0
The color at the first point.
color1
The color at the second point.

Propriedades

LinearColors
public Color[] LinearColors { get; }
value = linearGradientBrush.LinearColors

Gets the array of colors defining the gradient stops.

Rectangle
public Rectangle Rectangle { get; }
value = linearGradientBrush.Rectangle

Gets the rectangle that defines the bounds of the gradient.