Xceed Chart for WinForms v4.4 Documentation
GradientVariant Property
Example 


Xceed.Chart.Standard.v4.4 Assembly > Xceed.Chart.Standard Namespace > FillEffect Class : GradientVariant Property
The gradient variant of the FillEffectBase.
Syntax
'Declaration
 
Public Property GradientVariant As GradientVariant
'Usage
 
Dim instance As FillEffect

Dim value As GradientVariant

 

instance.GradientVariant = value

 

value = instance.GradientVariant
public GradientVariant GradientVariant {get; set;}
Remarks
Each gradient style has different sub variants. For example the horizontal gradient style has four variants that indicate how the control will merge the Color1 and Color2 properties. The possible values are Variant1, Variant2, Variant3, Variant4. The default value for this property is Variant1. All gradient styles support four variants except the FromCenter one which supports only two.
Example
The following example applies a black and white diagonal gradient of the right chart wall.
Dim chart As Chart = CType((ChartControl.Charts(0)), Chart)

Dim fillEffect As FillEffectBase =  chart.Wall(ChartWallType.Back).FillEffect 

fillEffect.Type = FillEffectType.Gradient

fillEffect.GradientStyle = GradientStyle.DiagonalDown

fillEffect.GradientVariant = GradientVariant.Variant1

fillEffect.BeginColor = Color.White

fillEffect.EndColor = Color.Black
Chart chart = (Chart)(ChartControl.Charts[0]);

FillEffectBase fillEffect = chart.Wall(ChartWallType.Back).FillEffect;

fillEffect.Type = FillEffectType.Gradient;

fillEffect.GradientStyle = GradientStyle.DiagonalDown;

fillEffect.GradientVariant = GradientVariant.Variant1;

fillEffect.BeginColor = Color.White;

fillEffect.EndColor = Color.Black;
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

FillEffect Class
FillEffect Members