ISpeedometerScaleViews.Count

Syntax

Count: Double;

Description

The Count property determines the number of speedometer scales formatting styles.

Comments

One formatting style of speedometer scales is created in the component by default. If there is more than one scale in the component, specific formatting can be configured set up for each scale. To do this, specify in this property the number of formatting styles that are created. The formatting style of the first scale is used for all scales, for which the individual formatting style was not created.

Example

Executing the 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;

ScaleView, ScaleView1: ISpeedometerScaleView;

Begin

s := SpeedometerBox1.Speedometer;

v := s.View;

s.BeginUpdate;

s.Scales.Count := 2;

v.ScaleViews.Count := 2;

ScaleView := v.ScaleViews.Item(0);

ScaleView1 := v.ScaleViews.Item(1);

//The first design

ScaleView.StartAngle := 0;

ScaleView.DeltaAngle := 180;

//The second design

ScaleView1.FontColor := GxColor.FromName("Green");

ScaleView1.TextPlacement := SpeedometerTextPlacementType.OutsideRotated;

s.EndUpdate;

End Sub Button1OnClick;

After executing the example, on clicking the button, two speedometers are displayed in the SpeedometerBox1 component. Each speedometer has Its own formatting.

See also:

ISpeedometerScaleViews