How to draw the red axis on a graph?
Using c++builder。
How to draw an axis
-
- Newbie
- Posts: 27
- Joined: Wed Nov 09, 2022 12:00 am
How to draw an axis
- Attachments
-
- Snipaste_2023-08-16_16-00-10.png (16.23 KiB) Viewed 20112 times
Re: How to draw an axis
Hello,
you can do this by using the ColorLine Tool (two, one for vertical and another one for horizontal).
You can find an example of use of the ColorLine tool in the TeeNew examples features included with the installation.
Please, do not hesitate to contact us in the case we can be of a further help.
you can do this by using the ColorLine Tool (two, one for vertical and another one for horizontal).
You can find an example of use of the ColorLine tool in the TeeNew examples features included with the installation.
Please, do not hesitate to contact us in the case we can be of a further help.
Pep Jorge
http://support.steema.com
http://support.steema.com
-
- Newbie
- Posts: 27
- Joined: Wed Nov 09, 2022 12:00 am
Re: How to draw an axis
I can't find it. Can you give me a demo?
Re: How to draw an axis
Hello,
you can use the following code to add a colorline tool and then customize it.
Please, let us know in the case any help still needed.
you can use the following code to add a colorline tool and then customize it.
Code: Select all
//Now add colorlinetool outside the min/max range of the data
TColorLineTool *line = new TColorLineTool(TrendChart);
TrendChart->Tools->Add(line);
line->AllowDrag = false;
line->NoLimitDrag = false;
line->Axis = axisVert;
line->Pen->Color = clBlue;
line->Pen->Width = 2;
line->Value = 32;
Pep Jorge
http://support.steema.com
http://support.steema.com
-
- Newbie
- Posts: 27
- Joined: Wed Nov 09, 2022 12:00 am
Re: How to draw an axis
line->Axis = axisVert;
What is axisVert???
What is axisVert???
Re: How to draw an axis
Hello,
axisVert was used in the case you want to make use of a new custom axis, like:
but you can always use instead:
axisVert was used in the case you want to make use of a new custom axis, like:
Code: Select all
//Add vertical axis
TChartAxis *axisVert = new TChartAxis(TrendChart);
axisVert->Maximum = dblMax + 1;
axisVert->Minimum = dblMin - 1;
axisVert->Grid->Visible = true;
axisVert->Automatic = false;
axisVert->AutomaticMinimum = false;
axisVert->AutomaticMaximum = false;
axisVert->PositionPercent = 0;
axisVert->Horizontal = false;
axisVert->OtherSide = false;
axisVert->Visible = true;
axisVert->LabelsFont->Color = clRed;
Code: Select all
Chart->Axes->left
Pep Jorge
http://support.steema.com
http://support.steema.com