Page 1 of 1

Question on CustomDraw

Posted: Thu Mar 22, 2007 8:51 am
by 8571714
Hello!

I have a chart with custom drawn bottomaxes and I have a couple of questions:

1) If I allow vertical scrolling the series will scroll but I don't know how to scroll the custom drawn axes.

2) The marks in my series will sometime overlap the custom drawn axes but because I draw the axes in OnAfterDraw event the axes will be overwriting the marks. How can I make the marks stay above the axes?

In the same chart I have several custom vertical axes but since the horizontal axis should be the same for all the series I use CustomDraw for this.

Regards,
Erik

Posted: Thu Mar 22, 2007 9:44 am
by narcis
Hi guzial,
1) If I allow vertical scrolling the series will scroll but I don't know how to scroll the custom drawn axes.
You could use axes SetMinMax method to scroll them.
2) The marks in my series will sometime overlap the custom drawn axes but because I draw the axes in OnAfterDraw event the axes will be overwriting the marks. How can I make the marks stay above the axes?
Maybe you can try drawing them in earlier events like OnBeforeDraw, OnBeforeDrawAxes, OnBeforeDrawSeries, etc.
In the same chart I have several custom vertical axes but since the horizontal axis should be the same for all the series I use CustomDraw for this.
Why don't you use the default horizontal axis then? For more information on using axes please read Tutorial 4 - Axis Control. You'll also find some examples at the new features demo. Demo and tutorials can be found at TeeChart's program group.