Page 1 of 1

Plot annotation

Posted: Fri Mar 20, 2009 9:02 pm
by 10545848
When I upgraded to v8.04, I started seeing a thin grey line being drawn beneath my plot annotation that I can't seem to prevent. This was not there in my previous version..which was v8.something.

I display the annotation to the right of my plot with the following code:

PlotAnnotation := TAnnotationTool.Create(Self);
PlotAnnotation.ParentChart := Chart1;
PlotAnnotation.Shape.Color := PlotCfg.BackgroundColor;
PlotAnnotation.Shape.ShadowColor := PlotCfg.BackgroundColor;
PlotAnnotation.Shape.Frame.Visible := False;
PlotAnnotation.Text := AnnotationStr;
PlotAnnotation.Shape.CustomPosition := True;
Chart1.MarginRight := 25;
PlotAnnotation.Shape.ShapeBounds.TopLeft.X := Chart1.ChartRect.BottomRight.X + 15;
PlotAnnotation.Shape.ShapeBounds.TopLeft.Y := Chart1.ChartRect.TopLeft.Y;
PlotAnnotation.Visible := True;

I can send a screen shot if you tell me how.
Any thoughts?

Posted: Fri Mar 20, 2009 9:31 pm
by 10545848
I found how to fix this issue "for me". I added the following line of code:

PlotAnnotation.Shape.Transparent := True;

I think the bug is still there, but is now transparrent. If the annotation shape is not the same color as the background, I think you will still see the issue.

Thanks...

Posted: Mon Mar 23, 2009 9:47 am
by yeray
Hi dpatch,

The only line I see using your code with v8.04 is the shadow. In case you want to hide it, add the following:

Code: Select all

PlotAnnotation.Shape.Shadow.Visible := False;