New to Telerik UI for WinForms? Start a free 30-day trial

Creates the predefined radial-gauge brushes for RadialGaugeArc visuals.

Definition

Namespace:Telerik.WinControls.UI.Gauges

Assembly:Telerik.WinControls.UI.dll

Syntax:

C#
public class BrushFactory : IBrushFactory

Inheritance: objectBrushFactory

Implements: IBrushFactory

Constructors

C#
public BrushFactory()

Methods

Creates a radial-arc brush for the requested style. Unsupported owners return null, while Other and unknown values use the standard rainbow brush.

C#
public Brush CreateBrush(GaugeVisualElement owner, GaugeBrushType type)
Parameters:ownerGaugeVisualElement

The gauge visual to paint.

typeGaugeBrushType

The requested brush style.

Returns:

Brush

The created brush, or null when owner is not a RadialGaugeArc.

Implements: IBrushFactory.CreateBrush(GaugeVisualElement, GaugeBrushType)

Creates a radial gradient from a radial arc's configured colors and gradient percentages. Arcs configured with one color, or with a color count outside the supported two-to-four range, produce a solid brush using the arc's back color.

C#
public Brush CreateGradientBrush(RadialGaugeArc owner)
Parameters:ownerRadialGaugeArc

The radial arc whose color settings define the gradient.

Returns:

Brush

The configured radial gradient or a solid brush when the arc has no supported multi-color configuration.

Creates a radial path gradient with green, yellow, red, and magenta color regions around the arc.

C#
public Brush CreateRainbow2Brush(RadialGaugeArc owner)
Parameters:ownerRadialGaugeArc

The radial arc whose angles and gauge geometry define the gradient path.

Returns:

Brush

The generated path gradient brush.

Creates a radial path gradient with green, cyan, blue, and magenta color regions around the arc.

C#
public Brush CreateRainbow3Brush(RadialGaugeArc owner)
Parameters:ownerRadialGaugeArc

The radial arc whose angles and gauge geometry define the gradient path.

Returns:

Brush

The generated path gradient brush.

Creates a radial path gradient that transitions through red, yellow, green, cyan, and blue around the arc.

C#
public Brush CreateRainbowBrush(RadialGaugeArc owner)
Parameters:ownerRadialGaugeArc

The radial arc whose angles and gauge geometry define the gradient path.

Returns:

Brush

The generated path gradient brush.