Hi,
How can I calculate the maximum and minimum of an axis by taking account the MaximumOffset and MinimumuOffset ? My problem is that MaximumOffset and MinimumuOffset are in pixel unit.
Thanks
Franck
MaximumOffset and MinimumuOffset
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Franck,
You may obtain that value using something like:
You may obtain that value using something like:
Code: Select all
Chart1.Axes.Left.CalcPosPoint(Chart1.Axes.Left.IStartPos-Chart1.Axes.Left.MaximumOffset);
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Thanks for you quick reply, but even with this I do not find the solution of my pb.
Let me explain.... I posted a message in the forum in October 2005 (title of the message : "Print proportional") because I could not print a propotional graph with the function "MakeIsoXYAxes()" that you described in the forum. I always had an error of 2% between axes, which is not acceptable for my customers.
This morning I found an explanation of this ... I'm using the properties ChartAxis.MinimumOffset and ChartAxis.MaximumOffset for all the axes but your function "MakeIsoXYAxes()" did not take them into account. Since this morning I tried to modify your function to correct the problem but whithout success.
So could you help me to insert MinimumOffset and MaximumOffset in your function MakeIsoXYAxes() ? I'm not sure to understand the variables IStartPos and IEndPos.
Franck
Let me explain.... I posted a message in the forum in October 2005 (title of the message : "Print proportional") because I could not print a propotional graph with the function "MakeIsoXYAxes()" that you described in the forum. I always had an error of 2% between axes, which is not acceptable for my customers.
This morning I found an explanation of this ... I'm using the properties ChartAxis.MinimumOffset and ChartAxis.MaximumOffset for all the axes but your function "MakeIsoXYAxes()" did not take them into account. Since this morning I tried to modify your function to correct the problem but whithout success.
So could you help me to insert MinimumOffset and MaximumOffset in your function MakeIsoXYAxes() ? I'm not sure to understand the variables IStartPos and IEndPos.
Franck
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Franck,
Did you looked at the "Isometric Axis" example at the TeeChart features demo? That example already considers axes offset.
Did you looked at the "Isometric Axis" example at the TeeChart features demo? That example already considers axes offset.
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Yes the function I used is the function of the example of the TeeChart features demo but I'm sure it does n_o_t consider the MinimumOffset and MaximumOffset define on the axes.
When I set
LeftAxis.MinimumOffset := 0
LeftAxis.MaximumOffset := 0
BottomAxis.MinimumOffset := 0
BottomAxis.MaximumOffset := 0
then the function is correct, but when I set
LeftAxis.MinimumOffset := 10
LeftAxis.MaximumOffset := 10
BottomAxis.MinimumOffset := 10
BottomAxis.MaximumOffset := 10
then an error of 2% appears.
When I set
LeftAxis.MinimumOffset := 0
LeftAxis.MaximumOffset := 0
BottomAxis.MinimumOffset := 0
BottomAxis.MaximumOffset := 0
then the function is correct, but when I set
LeftAxis.MinimumOffset := 10
LeftAxis.MaximumOffset := 10
BottomAxis.MinimumOffset := 10
BottomAxis.MaximumOffset := 10
then an error of 2% appears.
Hi Frank,
to be considered you should change the code , for example in the Demo Features example :
to be considered you should change the code , for example in the Demo Features example :
Code: Select all
With Horizontal do XRange:=Maximum-MaximumOffset-Minimum-MinimumOffset;
With Vertical do YRange:=Maximum-MaximumOffset-Minimum-MinimumOffset;
Pep Jorge
http://support.steema.com
http://support.steema.com