TWorldSeries - Pacific centered map
Posted: Mon May 21, 2018 2:06 pm
How can I use the TWorldSeries for a Pacific centered map, so that it uses 0 to 360 degrees instead of -180 to +180 degrees?
Steema Software - Customer Support Forums
http://teechart.com/support/
Code: Select all
uses TeeWorldSeries;
var Series1: TWorldSeries;
procedure TForm1.FormCreate(Sender: TObject);
var tmpSeries: TWorldSeries;
begin
Chart1.View3D:=False;
Chart1.Legend.Hide;
Series1:=Chart1.AddSeries(TWorldSeries) as TWorldSeries;
Series1.FillSampleValues();
with Chart1.Axes.Bottom do
begin
EndPosition:=50;
SetMinMax(0, 180);
end;
tmpSeries:=CloneChartSeries(Series1) as TWorldSeries;
with Chart1.CustomAxes.Add do
begin
Horizontal:=True;
StartPosition:=50;
SetMinMax(-180, 0);
end;
tmpSeries.CustomHorizAxis:=Chart1.CustomAxes[0];
tmpSeries.ParentChart:=nil;
Chart1.AddSeries(tmpSeries);
end;