Grid overlays pen traces

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
BenW
Advanced
Posts: 119
Joined: Wed Aug 10, 2005 4:00 am

Grid overlays pen traces

Post by BenW » Fri Jun 01, 2007 11:28 pm

Hi.

I'm having a problem, where the vertical and horizontal lines of the grid, overlay the lines and markers of the pen traces. It seems like a drawing order issue.

Is there a way to control the drawing order such that the grid is drawn first and then all pen traces/markers are drawn subsequent to that?

thanks,
Ben.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Mon Jun 04, 2007 7:37 am

Hi Ben,

Sorry but I don't understand which is the exact problem you are having. Could you please send us a screen-shot or a simple example project we can run "as-is" to reproduce the problem here?

You can post your files at news://www.steema.net/steema.public.attachments newsgroup or at our upload page.

Thanks in advance.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

BenW
Advanced
Posts: 119
Joined: Wed Aug 10, 2005 4:00 am

Post by BenW » Mon Jun 04, 2007 6:03 pm

Hi Narcís,

I've uploaded a bitmap (GridOverlayIssue) that illustrates the problem.

On the bitmap please look at the pen trace of the first pen (ANKTN IP). It's color should be red. You'll notice that when it's value changes such that if falls on the horizontal grid lines (e.g. values of 50 and 55), you can see the red triangular markers being displayed, but the pen trace line cannot be seen; instead, it looks as though the yellow grid line has overlayed the red pen trace.

Any thoughts on what causes this and what might be done so that the red line can be seen for values that fall on the horizontal grid line?

Regards,
Ben.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Mon Jun 04, 2007 6:55 pm

Hi Ben,

Thanks for the image. In that case I'd try settin axes DrawBehind property to true:

Code: Select all

            tChart1.Axes.DrawBehind = true;
Hope this helps!
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

BenW
Advanced
Posts: 119
Joined: Wed Aug 10, 2005 4:00 am

Post by BenW » Mon Jun 04, 2007 7:37 pm

Hi Narcís,

Well, once again that did help. Thanks!!


I do have another topic for discussion, specifically in relation to controlling the precision for y-axis labels (for plots and trends). For example:

If I have a data value that is fluctuating between 88.111111111 and 88.9999999999, then if I set the y-axis min to 88.1111111111 and the y-axis maximum to 88.9999999999, (automatic is false), how can I get the y-axis labels on the ticks to be displayed according to a pre-specified format value? For example if the customer wanted to specify a precsion format value string of say "##.#####", so that maximum and minimum y-axis labels could be drawn as 88.11111 and 88.99999 respectively, wth tick labels in between of say 88.22222, 88.33333, etc - then what is the best practice in terms of coding up the Teechart to achieve this, without the customer having to specify too many parameters? Can the Teechart be told to automatically produce the y-axis labeling as described above, through minimal config?

Note if automatic is set to true for the y-axis, then for a series where values are fluctuating between 88.1111111111 and 88.9999999999, sometimes the y-axis labels are not drawn, or just a single label of 90 is drawn. Is it possible to get the autoscaling capability to prduce a nice evenly spread set of labels on the y-axis between and including 88.1111111111 and 88.9999999999?

thanks,
Ben.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Tue Jun 05, 2007 7:15 am

Hi Ben,

You can use labels ValueFormat property as told in Tutorial 4 - Axis Control. You'll find the tutorials at TeeChart's program group.

This can also be configured at design-time using the chart editor at the Axes tab.
Note if automatic is set to true for the y-axis, then for a series where values are fluctuating between 88.1111111111 and 88.9999999999, sometimes the y-axis labels are not drawn, or just a single label of 90 is drawn. Is it possible to get the autoscaling capability to prduce a nice evenly spread set of labels on the y-axis between and including 88.1111111111 and 88.9999999999?
In that case you may be interested in doing something as shown in the What's New?\Welcome !\New in Axis\First and Last labels example in the features demo or use custom labels as in the All Features\Welcome !\Axes\Labels\Custom labels example.

The features demo can be found at TeeChart's program group as well.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply