Page 1 of 1

Problems with logarithmic axes and grids

Posted: Thu Mar 15, 2007 11:09 pm
by 9340549
Hello TeeChart-Team,

i have a problem with logarithmic axes.
When using logarithmic (base 10) scaling with minortickcount=9 (mistakable, don't use 10) you expect e.g. MAJOR ticks at 1E6, 1E7 and MINOR tick at 2E6, 3E6 and so on.
The points of a TImagePointSeries are located at the right positions (tested with cursor tool) but the minor grid is wrong !

I found in the source of TeeChart that the MINOR ticks are calculated from the canvasPOSITIONS and not from the VALUES of the MAJOR ticks - a very uncommon way because you accumulate exponential rounding errors.
Additional errors are : sometimes you get two adjacent grid lines and no grid at some parts of the chart.

I can send you a screenshot with this problems.

Here is the *.dfm snippet of the bottom axis :

BottomAxis.AxisValuesFormat = #13'#.0"x10" E-'
BottomAxis.ExactDateTime = False
BottomAxis.Grid.Style = psSolid
BottomAxis.LabelsExponent = True
BottomAxis.LabelsFont.Charset = ANSI_CHARSET
BottomAxis.LabelsFont.Name = 'Tahoma'
BottomAxis.LabelsSeparation = 0
BottomAxis.LabelsSize = 30
BottomAxis.LabelStyle = talValue
BottomAxis.Logarithmic = True
BottomAxis.MinorGrid.Color = clGray
BottomAxis.MinorGrid.SmallDots = True
BottomAxis.MinorGrid.Visible = True
BottomAxis.MinorTickCount = 9
BottomAxis.MinorTickLength = 3
BottomAxis.Ticks.Color = clBlack
BottomAxis.TickOnLabelsOnly = False
BottomAxis.Title.Caption = 'Schwingspielzahl'
BottomAxis.TitleSize = 1

I use the version 7.07 VCL under BDS2006 Win32.

I hope that i fixed all the problems in the source. Do yo need the altered units to check it (and build a new release ...) ?

Best regards

Axel Funke

SincoTec Bauteil-Prüftechnik GmbH
Freiberger Strasse 13
D-38678 Clausthal-Zellerfeld

a.funke(at)sincotec.de
www.sincotec.de

Posted: Fri Mar 16, 2007 7:57 am
by narcis
Hello Axel,

Would you be so kind to send us the files you modified so that we can review them an consider its inclusion in future releases?

You can post your files at our upload page.

Thanks in advance.