Caption/Title in the middle of a TDonutSeries
Posted: Fri Mar 30, 2018 7:41 pm
How do I put a caption/title in the middle of a TDonutSeries? I think I am missing the obvious.
Ed Dressel
Ed Dressel
Steema Software - Customer Support Forums
http://teechart.com/support/
Code: Select all
uses TeeDonut, TeeTools;
var donut1: TDonutSeries;
annot1: TAnnotationTool;
procedure TForm1.FormCreate(Sender: TObject);
begin
Chart1.Legend.Hide;
Chart1.View3D:=False;
donut1:=Chart1.AddSeries(TDonutSeries) as TDonutSeries;
donut1.FillSampleValues;
annot1:=Chart1.Tools.Add(TAnnotationTool) as TAnnotationTool;
annot1.Text:='Annotation';
Chart1.Draw;
annot1.Left:=donut1.CircleXCenter -(annot1.Width div 2);
annot1.Top:=donut1.CircleYCenter -(annot1.Height div 2);
end;