I wanted to see if anyone had any experience with trying to position the TeeChart embedded legend on a graph which contains multiple custom vertical axes.
We have the ability to generate a graph using 6 vertical axes. 3 on the left side and 3 of the right side.
When I try to place the TeeChart legend into the graph on either the left or the right side, the legend draws on top of the custom vertical axes.
I have looked at and tried to use many of the different properties on the legend itself to change its positioning with respect to the currently visible vertical axes but I cannot seem to get the placement correct.
Any assistance or recommendations with the placement of the legend would be greatly appreciated.
Thanks.
Aaron Peronto
Legend Positioning with custom vertical axes?
-
- Newbie
- Posts: 29
- Joined: Wed Jun 20, 2007 12:00 am
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Aaron,
Yes, you need to set the legend to a custom position as shown here. You can use axes properties, for example:
You may also need to set panel margins:
Hope this helps!
Yes, you need to set the legend to a custom position as shown here. You can use axes properties, for example:
Code: Select all
tChart1.Axes.Right.PositionUnits = Steema.TeeChart.PositionUnits.Pixels;
tChart1.Legend.Left = tChart1.Axes.Right.Position + 30;
Code: Select all
tChart1.Panel.MarginUnits = Steema.TeeChart.PanelMarginUnits.Pixels;
tChart1.Panel.MarginRight = tChart1.Legend.Width + 50;
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
-
- Newbie
- Posts: 29
- Joined: Wed Jun 20, 2007 12:00 am
Thanks as always for the quick response.
This got me started in the right direction to get my legend placed correctly.
I ended up having to use the RelativePosition property of the farthest outside axis on the side the legend was getting drawn on.
This plus a little more math to determine the margins needed seems to be working pretty well.
Thanks again.
This got me started in the right direction to get my legend placed correctly.
I ended up having to use the RelativePosition property of the farthest outside axis on the side the legend was getting drawn on.
This plus a little more math to determine the margins needed seems to be working pretty well.
Thanks again.