Page 1 of 1

Drawing Shapes on TCharts

Posted: Mon Dec 10, 2012 3:43 pm
by 16561973
Hi, I'm struggling with the TChart framework to create a small application which draw quadratic functions. I am not very experienced with all the functionality of the framework. I hope the community can share some expertise.

My application:
Any 3 points form a quadratic/parabola. I managed to draw quadratic functions based on 3 points from user input using TLineSeries.

My problem:
Wat I would like to do is to create 3 shapes on the chart representing the 3 user input point. I would like to be able to move these points with the mouse and recalculate the quadratic. I have trouble with creating the 3 shapes on top of the chart. I have tried the DragMarks functionality, but these do not seem to work exactly as I would like to. Painting a square over the 3 points do display the points, but cannot be moved.

Somebody has a sugggestion?

Re: Drawing Shapes on TCharts

Posted: Tue Dec 11, 2012 11:23 am
by yeray
Hi,

Give it a try to the TRectangleTool. This tool supports drag and resize. I guess you aren't interested in resize, so you could disable it.

Re: Drawing Shapes on TCharts

Posted: Thu Dec 13, 2012 8:15 am
by 16561973
Thanks for the suggestion. I will give it a try.

Regards,
Oscar