IPPSpeedometerBorder.Background

Syntax

Background: IGxBrush;

Description

The Background property determines a brush for rendering border.

Example

Executing the example requires that the repository contains a database with the ADHOC identifier. A dashboard must contain a speedometer.

Add links to the Adhoc, Drawing, Express, Metabase, Speedometer system assemblies.

Sub UserProc;
Var
    Speedometer: IPPSpeedometer;
    MB: IMetabase;
    AdhocReport: IAdhocReport;
    EaxSpeedometer: IEaxSpeedometer;
    Enalyzer: IEaxAnalyzer;
    DsObjs: IAdhocDataSourceObjects;
    Borders: IPPSpeedometerBorders;
    Border: IPPSpeedometerBorder;
    SolidBrush: IGxSolidBrush;
    Color: IGxColor;
Begin
    MB := MetabaseClass.Active;
    // Get dashboard 
    AdhocReport := MB.ItemById("ADHOC").Edit As IAdhocReport;
    // Get dashboard data sources
    DsObjs := AdhocReport.DataSourceObjects;
    // Get speedometer
    Enalyzer := DsObjs.Item(0).GetSourceObject As IEaxAnalyzer;
    EaxSpeedometer := Enalyzer.Speedometer;
    // Get speedometer parameters
    Speedometer := EaxSpeedometer.Speedometer;
    Speedometer.EnableBorder := True;
    // Get speedometer border
    Borders := Speedometer.Borders;
    Border := Borders.Item(0);  
    // Set up border color
    Color := New GxColor.CreateRGB(255,0,0);
    SolidBrush := New GxSolidBrush.Create(Color);
    Border.Background := SolidBrush;
    // Set up rounding radius
    Border.BorderRadius.Bottom := 90;
    Border.BorderRadius.Top := 90;
    Border.BorderRadius.Right := 90;
    Border.BorderRadius.Left := 90;
    // Set up all border width
    Border.Width := 10;
    // Set up width of each border
    Border.Bottom := 15;
    Border.Top := 15;
    Border.Right := 20;
    Border.Left := 20;
    (Enalyzer As IMetabaseObject).Save;
End Sub UserProc;

After executing the example border rounding color, width and radius are set up.

See also:

IPPSpeedometerBorder