IVZIntervalsLegend.CellSpacing

Syntax

CellSpacing: IGxSizeF;

Description

The CellSpacing property determines horizontal and vertical indents of the elements within the legend with intervals.

Comments

To determine visualizer legend area, which contains items, use IVZIntervalsLegend.CellPadding.

Example

Executing the example requires that the repository contains an express report with the EXP identifier. The module containing the example should have links to Express, Drawing, Metabase and Visualizators assemblies. The specified procedure should be called from the Main entry point.

Before executing the example, the bubble tree legend with intervals looks as shown on the IVZDataScale interface description page. Set a triangular shaped marker, horizontal and vertical indentions of 50 pixels length and align their labels at center with -20 pixels indention for this legend. The elements are to be divided into two columns:

Sub UserProc;
Var
    Metabase: IMetabase; // Metabase
    EaxAnalyzer: IEaxAnalyzer; // Express report
    BubbleTree: IVZBubbleTree; // Bubble tree
    Legend: IVZIntervalsLegend;// Scale of legend with intervals
    CellSpacing: IGxSizeF; // Indentions between legend elements
Begin
    // Get metabase object
    Metabase := MetabaseClass.Active;
    // Open express report
    EaxAnalyzer := Metabase.ItemById("EXP").Edit As IEaxAnalyzer;
    // Get bubble tree
    BubbleTree := EaxAnalyzer.BubbleTree.BubbleTree;
    // Get legend    
    Legend := BubbleTree.Legends.Item(0As IVZIntervalsLegend;
    // Set triangular shaped elements of legend
    Legend.Marker.Marker := VisualizatorSizeMarkerShape.Trapezoid;
    // Set indents between elements of 50 pixels length
    CellSpacing := New GxSizeF.Create(5050);
    Legend.CellSpacing := CellSpacing;
    // Set text indent inside element
    Legend.TextSpacing := -20;
    // Set horizontal alignment of label in the center of element
    Legend.TextHorizontalAlignment := GxStringAlignment.Center;
    // Divide legend elements into two columns
    Legend.ColumnsCount := 2;
    // Save changes made in express report
    (EaxAnalyzer As IMetabaseObject).Save;
End Sub UserProc;

After executing the example, bubble tree legend elements obtain the triangular shaped marker, horizontal and vertical indents of 50 pixels length. Their labels are aligned at center with -20 pixels indent, and the elements are divided into two columns:

See also:

IVZIntervalsLegend