ISpeedometerBackground.GradientColor

Syntax

GradientColor: IGxColor;

Description

The GradientColor property determines the second color that is used for gradient filling.

Comments

It is used if SpeedometerBackgroundType.Gradient is set as background type. The first color used for the gradient filling is assigned in the Color property.

Example

Executing this example requires a form with the Button1 button and the SpeedometerBox component named SpeedometerBox1.

Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);

Var

s: ISpeedometer;

v: ISpeedometerView;

Back: ISpeedometerBackground;

Begin

s := SpeedometerBox1.Speedometer;

v := s.View;

s.BeginUpdate;

Back := v.Background;

Back.Type := SpeedometerBackgroundType.Gradient;

Back.Color := GxColor.FromName("Yellow");

Back.GradientColor := GxColor.FromName("Green");

Back.GradientAngle := 45;

s.EndUpdate;

End Sub Button1OnClick;

If the user presses the button after executing this example, the parameters of speedometer design that is displayed in the SpeedometerBox1 component are changed. The gradient filling is set for speedometer background.

See also:

ISpeedometerBackground