IVZMapChartLayer.VisualsOffset

Fore syntax

VisualsOffset: Double;

Fore.NET syntax

VisualsOffset: double;

Description

The VisualsOffset property determines distance between visualizers of different types located on the same line on the map layer.

Comments

To set distance between vosualizers of different types, it is required that the IVZMapChartLayer.PlaceVisualsOneByOne property is set to True.

Types of visualizers on the map:

Fore example

Executing the example requires that the repository contains an express report with the EXPRESS identifier containing a chart with pie and bar factors.

Ad links to the Express, Metabase, Visualizators system assemblies.

Sub UserProc;
Var
    MB: IMetabase;
    Express: IEaxAnalyzer;
    Map: IVZMapChart;
    Layer: IVZMapChartLayer;
Begin
    // Get repository
    MB := MetabaseClass.Active;
    // Get express report
    Express := MB.ItemById("EXPRESS").Edit As IEaxAnalyzer;
    // Get map
    Map := Express.MapChart.MapChart;
    // Get map layer
    Layer := Map.RootLayer.SubLayers.Item(0);
    // Visualizers on the map are located on the same line
    If Not Layer.PlaceVisualsOneByOne Then
        Layer.PlaceVisualsOneByOne := True;
    End If;
    // Distance between visualizers
    Layer.VisualsOffset := 10;
    // Refresh and save report
    Express.RefreshAll;
    (Express As IMetabaseObject).Save;
End Sub UserProc;

After executing the example map visualizers are located on the same line, distance between them is 10 pixels.

Fore.NET example

The requirements and result of the Fore.NET example execution match with those in the Fore example.

Imports Prognoz.Platform.Interop.Express;
Imports Prognoz.Platform.Interop.Visualizators;

Public Shared Sub Main(Params: StartParams);
Var
    MB: IMetabase;
    Express: IEaxAnalyzer;
    Map: IVZMapChart;
    Layer: IVZMapChartLayer;
Begin
    // Get repository
    MB := Params.Metabase;
    // Get express report
    Express := MB.ItemById["Bars"].Edit() As IEaxAnalyzer;
    // Get map
    Map := Express.MapChart.MapChart;
    // Get map layer
    Layer := Map.RootLayer.SubLayers.Item[0];
    // Visualizers on the map are located on the same line
    If Not Layer.PlaceVisualsOneByOne Then
        Layer.PlaceVisualsOneByOne := True;
    End If;
    // Distance between visualizers
    Layer.VisualsOffset := 10;
    // Refresh and save report
    Express.RefreshAll();
    (Express As IMetabaseObject).Save();
End Sub;

See also:

IVZMapChartLayer