Teechart WPF - Improving performance of Cursor tool

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Priya Hatipkar
Newbie
Newbie
Posts: 46
Joined: Wed Jan 28, 2009 12:00 am

Teechart WPF - Improving performance of Cursor tool

Post by Priya Hatipkar » Tue Mar 10, 2009 12:06 pm

Hi,
I compared the performance of CursorTool for WPF Teechart and Windows Teechart.
The Windows Teechart cursor moves very smoothly with mouse. It sticks to the mouse point.
While for WPF Teechart, there does not stick with the mouse point. Is there any way we can improve on the performance for CursorTool ?

Below is the code snippet i used for testing:
public partial class CursorTest : Window
{
private Tstyle.Line lineSeries1 = new Tstyle.Line();
private CursorTool cursorSRC = new CursorTool();
public CursorTest()
{
InitializeComponent();

tChart1.Series.Add(lineSeries1);
tChart1.Aspect.View3D = false;


this.lineSeries1.FillSampleValues(200);


tChart1.Tools.Add(cursorSRC);
this.cursorSRC.FollowMouse = true;
this.cursorSRC.Series = this.lineSeries1;

}
}

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 Mar 10, 2009 3:40 pm

Hi Priya,

This works fine for me here using code below. Could you please check if it works fine at your end? If not, could you please let us know the your testing environment specifications?

Code: Select all

	public partial class Window1 : Window
	{
		public Window1()
		{
			InitializeComponent();
			InitializeChart();
		}

		private Steema.TeeChart.WPF.Styles.Line lineSeries1 = new Steema.TeeChart.WPF.Styles.Line();
		private Steema.TeeChart.WPF.Tools.CursorTool cursorSRC = new Steema.TeeChart.WPF.Tools.CursorTool(); 
		
		private void InitializeChart()
		{
			tChart1.Series.Add(lineSeries1);
			tChart1.Aspect.View3D = false;

			this.lineSeries1.FillSampleValues(200);

			tChart1.Tools.Add(cursorSRC);
			this.cursorSRC.FollowMouse = true;
			this.cursorSRC.Series = this.lineSeries1; 
		}
	}
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

Priya Hatipkar
Newbie
Newbie
Posts: 46
Joined: Wed Jan 28, 2009 12:00 am

Post by Priya Hatipkar » Thu Mar 12, 2009 4:45 am

Hi Narcis,

I have used same code. CursorTool functions correctly. But my concern is to improve the performance of it. The cursor should stick to the Mouse position. There should not be any time lag between you move the mouse and curor locates to the point you move.
I have checked the Windows CursorTool. It works flawlessly. Cursor sticks to the mouse position.


Regards,
Priya

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

Post by Narcís » Thu Mar 12, 2009 12:38 pm

Hi Priya,

I'm not able to reproduce this lag you mention with the code I posted. Can you reproduce it? Should I make any change to the code for reproducing it? Which are the characteristics of the machine where you can reproduce the issue?

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

Priya Hatipkar
Newbie
Newbie
Posts: 46
Joined: Wed Jan 28, 2009 12:00 am

Post by Priya Hatipkar » Mon Mar 23, 2009 4:00 am

Sample 'WpfApplication1.zip' has been uploaded at Steema upload page.
The performance of the cursor has serious performance problems. The cursor lags behind the mouse cursor. This does not account for a good user experience. Do let me know if there are any properties that need to be changed. The config of my machine is Intel Core 2 CPU 2 CPU 6300,1 GB Ram , Windows XP 2

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 Mar 23, 2009 3:38 pm

Hi Priya,

Thanks for the example project. I could reproduce the issue here. Same happens in WinForms application an it's solved using FastCursor=true:

Code: Select all

		public Form1()
		{
			InitializeComponent();
			InitializeChart();
		}

		private void InitializeChart()
		{
			tChart1.Dock = DockStyle.Fill;
			tChart1.Aspect.View3D = false;

			Steema.TeeChart.Styles.Line lineSeries1 = new Steema.TeeChart.Styles.Line(tChart1.Chart);
			lineSeries1.FillSampleValues(2000);

			Steema.TeeChart.Tools.CursorTool cursorSRC = new Steema.TeeChart.Tools.CursorTool(tChart1.Chart);
			cursorSRC.FollowMouse = true;
			cursorSRC.Series = lineSeries1;
			cursorSRC.FastCursor = true;
		}
Optimization for CursorTool is code that runs when FastCursor=true so I guess the solution with WPF will be making this property working there too. As you may already know this is a bug listed on our defect list with ID TW16013965.
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

rodneyt
Newbie
Newbie
Posts: 1
Joined: Wed Aug 16, 2006 12:00 am

Re: Teechart WPF - Improving performance of Cursor tool

Post by rodneyt » Mon Apr 04, 2011 9:00 am

Hi there, sorry to drag up an old thread but I promise it is relevant.

We are in the process of porting an old Borland C++ application into C# / WPF and part of that includes updating our charts (TeeChart 7.08!). I'm attempting to use the new .NET library within WPF and encountered a few issues, one of which is the poor performance of the CursorTool.

I see that the defect TW16013965 was labeled as 'fixed' in TeeChart.NET version 2009 - Build 4.0.2009.21355. However, the fix was to remove the FastCursor property from the CursorTool for WPF.

This is hiding the problem, NOT fixing it.

Are there any plans to enable FastCursor for CursorTool for WPF .NET 2010?

Also, it is a shame that Evaluation licence accounts are unable to post on the newsgroups as I could have used some help the last couple of weeks! Luckily out TeeChart 7.08 account is still active!

Cheers

Rod

Sandra
Site Admin
Site Admin
Posts: 3132
Joined: Fri Nov 07, 2008 12:00 am

Re: Teechart WPF - Improving performance of Cursor tool

Post by Sandra » Tue Apr 05, 2011 2:23 pm

Hello Rod,
We are in the process of porting an old Borland C++ application into C# / WPF and part of that includes updating our charts (TeeChart 7.08!). I'm attempting to use the new .NET library within WPF and encountered a few issues, one of which is the poor performance of the CursorTool.

I see that the defect TW16013965 was labeled as 'fixed' in TeeChart.NET version 2009 - Build 4.0.2009.21355. However, the fix was to remove the FastCursor property from the CursorTool for WPF.

This is hiding the problem, NOT fixing it.

Are there any plans to enable FastCursor for CursorTool for WPF .NET 2010?
I am afraid that TeeChart.WPF doesn't support FastCursor. I have added request in wish-list with number(TW16015473) to be considered inclusion in new versions of TeeChart.Net if it is possible find a solution.
Also, it is a shame that Evaluation licence accounts are unable to post on the newsgroups as I could have used some help the last couple of weeks! Luckily out TeeChart 7.08 account is still active!
If you use Evalutation license you could put your post it at news://www.steema.net/steema.public.attachments newsgroup.

Thanks,
Best Regards,
Sandra Pazos / 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