user3248874
user3248874

Reputation: 1

TeeChart RAD Studio XE4 C++Builder // Change Horizsize/VertSize

I want to change the Horizsize/VertSize of my Series Points in a TChart.

I can change it on a manual way, but not in the c++-code itself.

Upvotes: 0

Views: 237

Answers (1)

HvS
HvS

Reputation: 514

The series Pointer sub-component property is only available in certain series-type classes, such as the TLineSeries class.

Hence you need to cast your series-pointers to the appropriate derived-type first.

For a standard line chart:

// TChart * pChart    - pointer to your chart component.

// Cast to appropriate derived series-type.
TLineSeries* pLineSeries = dynamic_cast<TLineSeries*>( pChart->Series[index_of_series]);

// Now you can reach the Pointer sub-component property: pLineSeries->Pointer
// Seems like each individual point(TSeriesPointer) on the series can be accessed.

// Set Vertical size and Horizontal size:
pLineSeries->Pointer->operator [](index_of_point)->VertSize  = 5;
pLineSeries->Pointer->operator [](index_of_point)->HorizSize = 5;

Upvotes: 2

Related Questions