Page 1 of 1

TLegend.Title problem solved in latest patch??

Posted: Tue Dec 06, 2005 10:03 am
by 9232649
Hi,

I posted a question regarding that the legend.title overlaps the legend border( last year I think), is this fixed in the latest version? This is really important to me since this problem has and are still causing major problems in my application. Would be grateful if anyone can propose a workaround.

Best Regards,

Johan Ingemansson

Posted: Wed Dec 07, 2005 9:40 am
by narcis
Hi Johan,

This bug hasn't been fixed yet. I increased its priority. In the meantime, a workaround is using:

Code: Select all

  Chart1.Legend.ColumnWidthAuto:=false;
  Chart1.Legend.ColumnWidths[0]:=70;

Title in TChartLegend

Posted: Thu Dec 08, 2005 9:20 am
by 9232649
Hi again,

sry, but setting the ColumnWidths[0]:=70, doesnt work, the only workaround I´ve managed is to set the ColumnWidths[0]:=LegendTitleSize(I calculate this myself), and if the title width is greater then the chartwidth, its width is set to the chartwidht(otherwise it wont be displayed) and title is "choped" to fit.

The problem with this workaround is that since columnwidths[0] is rather wide, I only get one series title per row, if I have for example 8 series in chart, then the legend will be big and since I have a constant chart height, the size for the graphical display is reduced significantly :(

Best Regards,

Johan Ingemansson

Posted: Sat Dec 17, 2005 1:18 pm
by Pep
Hi Johan,

it's working fine now, using the latest TeeChart Pro v7.06 available to download from the customers download page on our web site.

TLegend.Title

Posted: Mon Dec 19, 2005 1:27 pm
by 9232649
Hi again,

You said that this bug was fixed in 7.06 but I have installed this patch and my conclusions is that TLegend.Title doesnt adjust for the TLegend.border, i.e if the title is wider then the border, it will overlap the border. If anyone have any solid workaround for this bug, I would be grateful.

Best Regards,

Johan Ingemansson

Posted: Tue Dec 27, 2005 10:37 am
by Pep
Hi Johan,

how can you reproduce the problem ? Would you be so kink to post post the code you're using ?

Posted: Mon Jan 02, 2006 10:17 am
by 9232649
This is the code I use for creating the legend:

with Legend do
begin
Alignment:=laBottom;
Font.Size:=10;
Font.Pitch:=fpFixed;
LegendStyle:=lsSeries;
Font.Name:='Arial';
ShadowColor:=clNone;
ShadowSize:=0;
Title.Text.Text

Title in TChartLegend

Posted: Mon Jan 02, 2006 10:22 am
by 9232649
Hi again,

This is the code I use for creating the legend:

with Legend do
begin
Alignment:=laBottom;
Font.Size:=10;
Font.Pitch:=fpFixed;
LegendStyle:=lsSeries;
Font.Name:='Arial';
ShadowColor:=clNone;
ShadowSize:=0;
Title.Text.Text:=ATextString(will max be 255 char long)
end;

[/img]

Posted: Mon Jan 02, 2006 11:46 am
by Pep
Hi Johan,

yes, you're correct, I'm sorry, did not test it with the alignment. It's a bug which we'll try to fix asap, for the next maintenance release.
In meantime if the workaround you said does not help you so much, another option could be to hide the Frame of the Legend and draw it manually in the OnBeforeDrawChart event, using similar code to the following :

Code: Select all

procedure TForm1.FormCreate(Sender: TObject);
begin
with Chart1.Legend do
begin
Alignment:=laBottom;
Font.Size:=10;
Font.Pitch:=fpFixed;
LegendStyle:=lsSeries;
Font.Name:='Arial';
ShadowColor:=clNone;
ShadowSize:=0;
Frame.Visible := false;
title.Text.Text:='aaaaaa  a a  a aa a  aaaa aa a  a a aaaaaaaa aaaaaaaaaaaaa  aaaaa a a a  aaaaaaaaaa';
Chart1.Draw();
end;

end;

procedure TForm1.Chart1BeforeDrawChart(Sender: TObject);
var rl : trect;
begin
Chart1.Canvas.Pen.Color := clblue;
Chart1.Canvas.Brush.Style := bsSolid;
rl :=Chart1.Legend.RectLegend;
rl.Top := rl.Top -1;
rl.Right := rl.Right +75;
rl.left := rl.left -1;
Chart1.Canvas.Rectangle(rl);
end;

Next Release?

Posted: Wed Jan 04, 2006 11:04 am
by 9232649
Hi again,

One quick question, what date is the next release scheduled for?

Best Regards,

Johan Ingemansson

Posted: Thu Jan 05, 2006 10:02 am
by Pep
Hi Johan,

I cannot tell a fixed date, but I think the new v7.07 will be out on this month (Jan), which will include some fixes, and sure thing is that will include the fix for this problem as it has been fixed yet.

When is patch 7.07 coming?

Posted: Fri Feb 17, 2006 8:28 am
by 9232649
Hi again,

Just wondering, in previous post it was said that the next patch should be out in end of Jan, I still havent seen it. Has this patch been delayed, and when is it scheduled for?

Best Regards,

Johan Ingemansson

Posted: Fri Feb 17, 2006 10:07 am
by narcis
Hi Johan,

Yes, there is a TeeTree installing issue that needs to be fixed before and we are currently working on it. As soon as this is fixed the next maintenance release will be published.

Please be aware at those forums for further news.