Hi
I have a legend on the graphs that I am printing.
If the title belonging to the TLineSeries that I am adding to the TChart has more than 65 characters, the legend is not displayed (even if it is just one of the titles is over the limit) if all the titles are shorter than 65 characters then the legend is displayed correctly.
is there any way round this limit?
I am using Delphi 7 and TeeChart Pro 7.07
Thanks in advance.
Legend Width
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Corbie,
This happens either when legend's position is set to top or bottom and the legend is wider that ChartRect. Try making the chart wider and you'll see it admits more characters in the legend.
This happens either when legend's position is set to top or bottom and the legend is wider that ChartRect. Try making the chart wider and you'll see it admits more characters in the legend.
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 |
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Corbie,
You can manually parse the text in the OnGetLegendText event. For example:
You can manually parse the text in the OnGetLegendText event. For example:
Code: Select all
procedure TForm1.Chart1GetLegendText(Sender: TCustomAxisPanel;
LegendStyle: TLegendStyle; Index: Integer; var LegendText: String);
var tmpStr: String;
begin
if (Length(LegendText) > 60) then
begin
LegendText:=copy(LegendText,0,60);
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 |