TDrawLine Tool

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
info
Newbie
Newbie
Posts: 6
Joined: Fri Oct 09, 2015 12:00 am

TDrawLine Tool

Post by info » Wed Oct 28, 2015 10:31 pm

Hello,

We are trying to use the TDrawLine Tool (Teechart Pro V2015 and Delphi XE6) to add lines over a "Pie" chart, but it is not working properly.
Could you tell us if it's possible to do this? Could you provide us back an example on how to do it?
If we change the Chart style from "Pie" to "Pyramid" and create a line using TDrawLine and change back the chart style to "Pie", then the TDrawLine Tool can be used.

Thanks,

Yeray
Site Admin
Site Admin
Posts: 9534
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Re: TDrawLine Tool

Post by Yeray » Fri Oct 30, 2015 2:53 pm

Hello,

The TPieSeries doesn't use the regular axes (Bottom and Left), so both axes have Minimum and Maximum = 0. This makes the TDrawLineTool unusable with it if you don't set a range manually. Ie:

Code: Select all

  Chart1.Axes.Left.SetMinMax(0, Series1.YValues.Total);
  Chart1.Axes.Bottom.SetMinMax(-0.5, 0.5);
In the code above I've set the same ranges the TPyramidSeries will use, in case you change to it later.
Alternatively, you can use any Minimum and Maximum for the TPieSeries and then make sure to set both axes Automatic:=true if you change to another series. But then the lines drawn will change their position in the screen.
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

info
Newbie
Newbie
Posts: 6
Joined: Fri Oct 09, 2015 12:00 am

Re: TDrawLine Tool

Post by info » Tue Nov 17, 2015 7:12 pm

Thank you

Post Reply