Page 1 of 1

Help - Series MouseLeave/MouseEnter

Posted: Sun Sep 07, 2008 12:58 pm
by 9092401
Hi
We are using a TeeChart Stack Bar Chart.
When you descend the stack bar from one series in the stack to the next series in the stack the Series.MouseLeave event is not called. However when you eventually leave the stack a Series.MouseLeave event for each series that you entered is raised. (its as if one series is contained within another)

Functionaly we wish to change Cursor whenever the mouse enters any of the series/bars and revert to default Cursor when the mouse is outside the series (bar). Presently due to the above bug we have to keep counter to track the number of series entered and left in order to implement this correctly.

Is there a fix for the above available or is there another mechanism of determining when the mouse is located over a bar or series.

Thanks

Posted: Mon Sep 08, 2008 7:36 am
by narcis
Hi qcrnd,

I could reproduce the issue here and added it (TF02013383) to the defect list to be enhanced for next releases.

In the meantime you could try using the MouseMove event and clicked method, for example:

Code: Select all

		private int index = -1;

		void tChart1_MouseMove(object sender, MouseEventArgs e)
		{
			for (int i = 0; i < tChart1.Series.Count; i++)
			{
				index = tChart1[i].Clicked(e.X,e.Y);

				if (index!=-1)
				{
					break;
				}
			}
		}

Thanks.

Posted: Tue Sep 09, 2008 8:48 am
by 9092401
your solution is good and it works well.
Thanks