Page 1 of 1

Interference between CursorTool and DrawLineTool

Posted: Mon Apr 10, 2006 7:42 am
by 9343260
Hello,

I don't know if you can help me, but I can't find any way to solve a problem between CursorTool and DrawLineTool.

A customer asked me to put the coordinates of the current point near the cursorTool, which I did with adding a small annotation near the cursor point.

But now, when I have the cursorTool activated AND the drawLinetool in the same time, my drawlines look terrible during design time.

Here is a screenshot of the problem; you can see the annotation with the coordinates I added and the drawline I'm designing :

Image

And here is the code I added to draw the annotation (for this, I created an annotation called 'cursorToolAnnotation' which always exists). This code is in 'TeeTools -> TeeCursorTool -> chartMouseEvent -> MouseMouve' :

Code: Select all

form.CursorToolAnnotation.Shape.Transparency := 40 ;
form.CursorToolAnnotation.Left := IPoint.X + 5 ;
form.CursorToolAnnotation.Top  := IPoint.Y - 20 ;
form.CursorToolAnnotation.Text := 'X:'+floatToStrF(GetHorizAxis.CalcPosPoint(IPoint.X), FFGeneral, 3, 2)+',Y:'+floatToStrF(GetVertAxis.CalcPosPoint(IPoint.Y), FFGeneral, 3, 2) ;
I guess the problem must be that the annotation is drawn on the canvas in the same time than the drawline, and this causes problems...