Hi,
I want to do a so called spider diagram using the TPolarSeries, in a spider diagram the labels of the replies should be displayed where the circled labels are now. Is there anyway of changing theese labels?
I´ve read another post where Steema recommended overriding the default settings in the creation of theese labels, the problem is that theese labels aren´t the same everytime.
Best Regards,
Johan Ingemansson
Changing Circled labels in Polar Series
-
- Newbie
- Posts: 59
- Joined: Fri May 28, 2004 4:00 am
- Location: Sweden
Hi Johan,
the only way around this is to manually draw axis labels on chart Canvas. You could use the TCanvas.RotateLabel method to draw axis label at specific position (in the OnAfterDraw event). The trick is (obviously) to calculate correct position and (more importantly) check for overlaps. The first part is already done in TeePolar.pas (which you can update if you're source code customer) , the second part still has to be improved.
the only way around this is to manually draw axis labels on chart Canvas. You could use the TCanvas.RotateLabel method to draw axis label at specific position (in the OnAfterDraw event). The trick is (obviously) to calculate correct position and (more importantly) check for overlaps. The first part is already done in TeePolar.pas (which you can update if you're source code customer) , the second part still has to be improved.
Pep Jorge
http://support.steema.com
http://support.steema.com
-
- Newbie
- Posts: 59
- Joined: Fri May 28, 2004 4:00 am
- Location: Sweden
Calculating axis etc.
Hi Pep,
Ok, I´ll do that, already have an "anti" overlapping algorithm, which I should be able to apply here! Thx!
Best Regards,
Johan Ingemansson
Ok, I´ll do that, already have an "anti" overlapping algorithm, which I should be able to apply here! Thx!
Best Regards,
Johan Ingemansson
-
- Newbie
- Posts: 59
- Joined: Fri May 28, 2004 4:00 am
- Location: Sweden
Maybe a stupid "sub" question
Hi again,
One moore thing, I have set the PositionUnits:=muPixels on all axes. If I take for example:
Chart1.Axes.Bottom.IEndPos-Chart1.Axes.Bottom.IStartPos
and now I do the same for the left axis, then theese values are not the same, in my case there is a 3 pixel difference, shouldn´t theese axes be exactly the same if a symmetric circle should be created? I have also set ASerie.Circled:=True.
Best Regards,
Johan Ingemansson
One moore thing, I have set the PositionUnits:=muPixels on all axes. If I take for example:
Chart1.Axes.Bottom.IEndPos-Chart1.Axes.Bottom.IStartPos
and now I do the same for the left axis, then theese values are not the same, in my case there is a 3 pixel difference, shouldn´t theese axes be exactly the same if a symmetric circle should be created? I have also set ASerie.Circled:=True.
Best Regards,
Johan Ingemansson
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Johan,
It works fine for me here using latest TeeChart version (v7.04). Which version are you using?
Also notice that Chart1.Axes.Bottom.IAxisSize is the same as doing Chart1.Axes.Bottom.IEndPos-Chart1.Axes.Bottom.IStartPos:
It works fine for me here using latest TeeChart version (v7.04). Which version are you using?
Also notice that Chart1.Axes.Bottom.IAxisSize is the same as doing Chart1.Axes.Bottom.IEndPos-Chart1.Axes.Bottom.IStartPos:
Code: Select all
procedure TForm1.FormCreate(Sender: TObject);
begin
Series1.FillSampleValues();
Series1.Circled:=true;
Memo1.Clear;
end;
procedure TForm1.Chart1AfterDraw(Sender: TObject);
var i: Integer;
begin
for i:=0 to Chart1.Axes.Count - 1 do
With Chart1.Axes[i] do
begin
PositionUnits:=muPixels;
Memo1.Lines.Add(IntToStr(i) + ': ' + IntToStr(IAxisSize));
end;
end;
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 |
-
- Newbie
- Posts: 59
- Joined: Fri May 28, 2004 4:00 am
- Location: Sweden
Axis size
Hi,
Thanks for the advice of IAxisSize! I´m currently using TeeChartPro 7.01 with source code, I still get this problem that is, the right/left axis is three pixels longer then bottom/top axis, but then it must be a version difference. Thank you for your quick response!
Best Regards,
Johan Ingemansson
Thanks for the advice of IAxisSize! I´m currently using TeeChartPro 7.01 with source code, I still get this problem that is, the right/left axis is three pixels longer then bottom/top axis, but then it must be a version difference. Thank you for your quick response!
Best Regards,
Johan Ingemansson