TAChart axis scale question lazarus / 55-TAChart ---------------------------------------------------------------------- dkjMusic · 2011-01-22 15:59 I plot three values on a TAChart. The X,Y values are (1, -852280000),(2, -850980000), and (3, -176500000). The resulting graph shows a Y-axis ranging from -1.5 down to -8.5 with no indication of scaling, as shown in the attachment. What do I need to do to have the Y-axis show the correct magnitudes? ---------------------------------------------------------------------- Ask · 2011-01-22 23:37 Can you post a small test project demonstrating the problem? ---------------------------------------------------------------------- dkjMusic · 2011-01-23 12:43 Quote from: Ask on January 23, 2011, 12:37:17 amCan you post a small test project demonstrating the problem? I have attached such a project. No changes were made to TAChart's default properties. The project exhibits the behaviour described above. ---------------------------------------------------------------------- Ask · 2011-01-24 00:37 I re-created a project based on the part you have posted. The behaviour does not reproduce for me on Windows. Are you sure you use the latest snapshot? If yes, then maybe it is a GTK-specific bug, although I highly doubt it. Please see the attached demo project and screenshot. ---------------------------------------------------------------------- dkjMusic · 2011-01-24 01:30 Quote from: Ask on January 24, 2011, 01:37:15 amAre you sure you use the latest snapshot? I really appreciate your helping with this. I'm using from TAGraph1-4.zip from http://www.martinole.org/TAChart.html (I think). Where do I get the latest snapshot of TAChart? ---------------------------------------------------------------------- Ask · 2011-01-24 02:27 That is the reason I asked for a complete test project, not just one file from it -- it would be obvious from the project info file that you are not using built-in TAChart package. Quote from: dkjMusic on January 24, 2011, 02:30:54 amWhere do I get the latest snapshot of TAChart? From you signature I assumed that you already have it. If not, use "Daily snapshots" link on the left panel of this forum. There, you can access TAChart components from the "Chart" page of the component palette. ---------------------------------------------------------------------- dkjMusic · 2011-01-24 02:47 When I said "I'm using from TAGraph1-4.zip from http://www.martinole.org/TAChart.html (I think).", I was wrong. I am using the TAChart package that came with the Lazarus 0.9.31 source, which is only five days older than the current daily snapshot. So it sounds like I have to live with the incorrect magnitudes. Can you suggest a way that I can examine the Y-axis values produced by TAChart and adjust the label for that axis to reflect the "scaling" that has occurred? For example, if -852280000 shows as -852, then my Y-axis label would read "(*10^6)". ---------------------------------------------------------------------- Ask · 2011-01-24 02:54 Quote from: dkjMusic on January 24, 2011, 03:47:33 amWhen I said "I'm using from TAGraph1-4.zip from http://www.martinole.org/TAChart.html (I think).", I was wrong. I am using the TAChart package that came with the Lazarus 0.9.31 source, which is only five days older than the current daily snapshot. Ok, then can you open the project I have posted and see if the problem exists? If yes, then there is a problem in TAChart. If not, the problem is probably in the lfm file which you did not post. Quote from: dkjMusic on January 24, 2011, 03:47:33 amSo it sounds like I have to live with the incorrect magnitudes. Can you suggest a way that I can examine the Y-axis values produced by TAChart and adjust the label for that axis to reflect the "scaling" that has occurred? For example, if -852280000 shows as -852, then my Y-axis label would read "(*10^6)". I would prefer to find the problem and fix it. Note, however, that you can directly set the formatting of axis labels by modifying Marks.Format property. ---------------------------------------------------------------------- dkjMusic · 2011-01-24 03:36 I ran the test project you posted and the problem is still there. ---------------------------------------------------------------------- Ask · 2011-01-24 06:44 Too bad. So it is probably a GTK-specific bug. Please create a bug report so it will not be forgotten. Meanwhile, you can use OnMarkToText event to examine/modify the label text.