IChartAxis.AutoTextSpacing

Fore Syntax

AutoTextSpacing: Boolean;

Fore.NET Syntax

AutoTextSpacing: System.Boolean;

Description

The AutoTextSpacing property determines the distance from a label to an axis line that is set automatically.

Comments

The default value of this property is True. The distance set automatically is equal to 2 mm. When the value is changed to False, the TextSpacing value is applied. This property is saved with the chart. If an object from the previous version is loaded, the TextAlignment, AutoTextSpacing, TextSpacing, TextVisible, and TextIsMultiline properties for the object are set to their default values.

Fore Example

To execute this example, create a form with a button named Button1 on the form, the ChartBox component and the UiChart component that is a data source.

Sub Button1OnClick(Sender: Object; Args: IMouseEventArgs);
Var
    ay: IChartAxis;
Begin
   ay:= UiChart1.Chart.AxisY;
   ay.TextSpacing:= 3.0;
    ay.AutoTextSpacing:= False;
End Sub Button1OnClick;

Clicking Button1 sets the minimum distance from the label to the  Y axis line that equals 3 mm.

Fore.NET Example

To execute this example, create a form with a button named Button1 on the form, the ChartBoxNet component and the UiChartNet component that is a data source.

...

Imports Prognoz.Platform.Forms.Net;
Imports Prognoz.Platform.Interop.Metabase;
Imports Prognoz.Platform.Interop.Chart;

Private Sub button1_Click( sender: System.Object; e: System.EventArgs );
Var
    ay: IChartAxis;
Begin
    ay:= UiChartNet1.ChartUi.Chart.AxisY;    
    ay.TextSpacing:= 3.0;   
    ay.AutoTextSpacing:= False;
End Sub;

Clicking Button1 sets the minimum distance from the label to the  Y axis line that equals 3 mm.

See also:

IChartAxis