The linear transform worked -- I finally figured out how to implement it. The chart is almost where it should be, except for the X-axis labels. I need to dynamically define which of two options to use:

J F M A M J J A S O N D (MnthNHLabels) for northern hemisphere sites, and
J A S O N D J F M A M J (MnthSHLabels) for southern hemisphere sites.

The compiler seemed to have no problem with my code:

  if lat < 0 then ClimateDataChart.BottomAxis.Marks.Source := MnthSHLabels
    else ClimateDataChart.BottomAxis.Marks.Source := MnthNHLabels;

The data source options I have tried, however (TListChartSource and TUserDefinedChartSource) seem determined to convert the strings to numbers -- primarily 0. What kind of chart source would allow me to use the strings above instead? Or is there something else I would need to do?

Thanks again,

Dave

On 7/29/2011 1:45 AM, David M. Lawrence wrote:

On 7/29/2011 1:21 AM, Alexander Klenin wrote:
I see now -- so you actually do NOT want auto-scale, but a fixed scale.
In this case, simply use linear transformation and then Chart.Extent property.

You will have to calculate scale and offset yourself (once, at design-time).
(From my quick calculation, you should use scale=0.5 and offset=-90,
but check yourself)
I'll check the linear transform. Those values are what I was thinking they should be. I'll give them a shot.

--
------------------------------------------------------
 David M. Lawrence        | Home:  (804) 559-9786
 7471 Brook Way Court     | Fax:   (804) 559-9787
 Mechanicsville, VA 23111 | Email: d...@fuzzo.com
 USA                      | http:  http://fuzzo.com
------------------------------------------------------

"All drains lead to the ocean."  -- Gill, Finding Nemo

"We have met the enemy and he is us."  -- Pogo

"No trespassing
 4/17 of a haiku"  --  Richard Brautigan


--
_______________________________________________
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to