Controlling what gets plotted on top in a 2D plot

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Aaron Peronto
Newbie
Newbie
Posts: 38
Joined: Thu Feb 01, 2007 12:00 am

Controlling what gets plotted on top in a 2D plot

Post by Aaron Peronto » Mon Jun 11, 2007 3:30 pm

How does TeeChart determine what series gets plotted on top when you are plotting in a 2D chart?
My users have asked for a "Bring to Front" capability to be added so they can select a single series and force it to plot on top of all of the others so it is the more visible series.

Is there an easy way to control this?

I'll take a look through the feature demo again to see if I can find it there but I didn't remember seeing that in the demo previously.

Thanks for your help again.

Aaron

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 11, 2007 3:34 pm

Hi Aaron,

Yes, this is possible changing series' ZOrder as told here.
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

Aaron Peronto
Newbie
Newbie
Posts: 38
Joined: Thu Feb 01, 2007 12:00 am

Post by Aaron Peronto » Tue Jun 12, 2007 2:44 pm

Thanks for the quick reply.

In looking at my ZOrder properties on the series that have been added to my plot, all of them are 0.
I am not entirely sure how I should determine which one is the topmost series so that I know which one to to use in my Exchange call so that I can move the one I want up to the front.

I thought that the series with the Zorder of 0 would be the one plotted on top but when all of them have Zorder of 0, that doesn't really work.
This is a 2D plot and I have NOT previously explicitly assigned Zorder values to any of the series.

I was under the impression that I would not have more than 1 series with any particular Zorder value so if I found the one with ZOrder of 0, that would be my topmost series.
Is that idea incorrect?

Thanks again.

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 12, 2007 3:03 pm

Hi Aaron,

Yes, you are right, that only works when chart's view is set to 3D. In that case you can try those 2 options:

1. Set the chart to 3D view, use ZOrder and set it back to 2D view.
2. Instead of using ZOrder use the inverse of the series index, for example, the first series in the chart (series with index=0) will have the last ZOrder (series.count-1).
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

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 12, 2007 3:07 pm

Hi Aaron,

Forgot to mention that suggestion #2 should be combined with Exchange method usage.
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

Aaron Peronto
Newbie
Newbie
Posts: 38
Joined: Thu Feb 01, 2007 12:00 am

Post by Aaron Peronto » Tue Jun 12, 2007 3:46 pm

So in the 2D view, exchanging the series I want to be on TOP of the drawing with the index of the last series in my collection will get my desired series drawn over the rest.

That seems to be what I am seeing in my application now.
That works fine for me.

Thanks again for your help.

Post Reply