I have a query that I hope someone can help me with.
One of my clients has commented that it is unhelpful when the ratio between the x and y axis is stretched, based around the shape of the underlying chart.
What he means is that for a simple graph where both x and y axis are meant to be, say, a fixed 0-100 scale he wants them to appear consistently the same length, regardless of how the surrounding margins, legends and other decorations are defined/positioned.
For TCircularSeries this seem to happen correctly i.e. the circle remains a circle rather than stretching into an ellipse. Is there an equivalent property for simple x/y graphs that I am failing to spot?
Cheers
DC
Fixed x to y ratio
Re: Fixed x to y ratio
Hi DC,
I think you are trying to achieve something similar to the demo at All features\Welcome !\Axes\Isometric Axis. You should find a shortcut to the "Feature demo" program through the Start Menu.
I think you are trying to achieve something similar to the demo at All features\Welcome !\Axes\Isometric Axis. You should find a shortcut to the "Feature demo" program through the Start Menu.
Best Regards,
Yeray Alonso Development & Support Steema Software Av. Montilivi 33, 17003 Girona, Catalonia (SP) | |
Please read our Bug Fixing Policy |
Re: Fixed x to y ratio
That wasn't entirely what I had in mind (as it seems to expand the "internal" graph dimensions rather than alter the surrounding space), but it at least lead me to my own solution where I artificially expand the left/right or top/bottom margins to maintain an "isometric" looking graph.
Thank you for your help
Thank you for your help
Re: Fixed x to y ratio
Hi Estechco,
You're welcome, and thanks to you for sharing your solution.
You're welcome, and thanks to you for sharing your solution.
Best Regards,
Yeray Alonso Development & Support Steema Software Av. Montilivi 33, 17003 Girona, Catalonia (SP) | |
Please read our Bug Fixing Policy |
Re: Fixed x to y ratio
Further to the query by Estechco of 23 August 2010, I am interested in the same solution. I have gone to the demo at All features\Welcome !\Axes\Isometric Axis, but there is no source code. Can you give more information as to how I can access the source code. I have Tee Chart Pro, but I cannot understand your instructions namely:
"Full source code of this demo and all the other TeeChart Pro examples can be found
inside TeeChart Pro Evaluation and Registered versions, downloadable from our web
site.
Once TeeChart Pro is installed, the path to this demo sources is stored at Windows
Registry.
Alternatively, click the Configure button to select the folder which contains this demo
sources."
Best regards
Errol
"Full source code of this demo and all the other TeeChart Pro examples can be found
inside TeeChart Pro Evaluation and Registered versions, downloadable from our web
site.
Once TeeChart Pro is installed, the path to this demo sources is stored at Windows
Registry.
Alternatively, click the Configure button to select the folder which contains this demo
sources."
Best regards
Errol
Re: Fixed x to y ratio
Hello Errol,
The demo source may have been installed to your TeeChart installation folder if you selected 'yes' to examples. But otherwise you can find the source to that demo here:
https://github.com/Steema/TeeChart-VCL- ... ter/TeeNew
(specifically https://github.com/Steema/TeeChart-VCL- ... metric.pas)
Regards,
Marc
The demo source may have been installed to your TeeChart installation folder if you selected 'yes' to examples. But otherwise you can find the source to that demo here:
https://github.com/Steema/TeeChart-VCL- ... ter/TeeNew
(specifically https://github.com/Steema/TeeChart-VCL- ... metric.pas)
Regards,
Marc
Steema Support
Re: Fixed x to y ratio
Hi Marc
Thanks for the directions to the examples. I found them anyway - I had moved them to a backup drive for some reason.
However, I have a problem. In the MakIsoAxis code snippet below, the values of ChartHeight and ChartWidth are always zero. Both Vertical and ParentChart are assigned. I have tried callng the procedure in an OnAfterDraw event but not improvement.
I would be grateful if you can give me some advice as to what to try.
Best regards
Errol
Thanks for the directions to the examples. I found them anyway - I had moved them to a backup drive for some reason.
However, I have a problem. In the MakIsoAxis code snippet below, the values of ChartHeight and ChartWidth are always zero. Both Vertical and ParentChart are assigned. I have tried callng the procedure in an OnAfterDraw event but not improvement.
Code: Select all
begin
with Vertical.ParentChart do
if (ChartHeight>0) and (ChartWidth>0) then
begin
Best regards
Errol
Re: Fixed x to y ratio
Hello Errol,
Check that your chart has had at least one proper repaint before running the method. For example, if I check this value, Series1.GetVertAxis.ParentChart.ChartHeight, in Form Create before the first paint, ChartHeight/Width return 0. If you run the code from the demo itself you may find some steps you can take to mimic it more closely to help hone-in on the cause of the problem.
Regards,
Marc
Check that your chart has had at least one proper repaint before running the method. For example, if I check this value, Series1.GetVertAxis.ParentChart.ChartHeight, in Form Create before the first paint, ChartHeight/Width return 0. If you run the code from the demo itself you may find some steps you can take to mimic it more closely to help hone-in on the cause of the problem.
Regards,
Marc
Steema Support
Re: Fixed x to y ratio
Hi Marc Thanks for your suggestions. However, I cannot run the demo itself as Base in uses, and class(TBaseForm) give an error.
Regards
Errol
Regards
Errol