Skip to main content
All docs
V24.1

TdxChartCustomSecondaryAxisCollectionItem.Title Property

Specifies the axis title, and its appearance and position.

Declaration

property Title: TdxChartAxisTitle read; write;

Property Value

Type Description
TdxChartAxisTitle

Stores an axis title and its settings.

Remarks

Use the Title.Text property to specify the axis title. Title.Appearance and Title.Position properties define the title’s appearance and position, respectively.

Refer to the TdxChartAxisTitle class description for detailed information on all available options.

Code Example

The following code example creates a secondary axis of values and associates it with the first series in an XY diagram:

var
  ADiagram: TdxChartXYDiagram;
  AAxisY: TdxChartSecondaryAxisYCollectionItem;
  AXYSeries: TdxChartXYSeries;
begin
  if dxChartControl1.DiagramCount = 0 then Exit;
  ADiagram := dxChartControl1.Diagrams[0] as TdxChartXYDiagram;
  if ADiagram.SeriesCount = 0 then Exit;
  AXYSeries := ADiagram.Series[0];
  AAxisY := ADiagram.SecondaryAxes.AxesY.Add;
  AXYSeries.View.AxisY := AAxisY.Axis;
  AAxisY.Title.Text := 'Income (USD)';
  AAxisY.Title.Alignment := TdxAlignment.Center;
  AAxisY.Appearance.Color := TdxAlphaColors.Gray;
end;
See Also