title: MouseEnter and MouseLeave processing in WPF (using VS2008 and .net 3.5) not working as expected
body: <p>It is not easy to explain the problem without an image and without code.  For those interested, I have made a sample C#/WPF project that can be downloaded from <a href="http://rapidshare.com/files/461745095/02.WPFControlEvents.rar" rel="nofollow">http://rapidshare.com/files/461745095/02.WPFControlEvents.rar</a></p>
  
  <p>It is a very small project (45KB).  The problem is as follows (with my apologies for the contorted description):</p>
  
  <p>A "fancy" (and rather ugly) button contains a stackpanel which in turn contains 1.) a label, 2.) a canvas, 3.) two (2) concentric ellipses, all laid out from left to right.</p>
  
  <p>There is a MouseEnter and a MouseLeave event handler for the stackpanel which displays a message in the title bar indicating whether the mouse is over the stackpanel or outside of it.</p>
  
  <p>The problem is: when the mouse is over the label (in turn contained in the stackpanel), the mouse is (correctly) reported as being over the stackpanel.  When the mouse is moved over the canvas (which is also contained in the stackpanel), the mouse is (incorrectly?) reported as <em>not</em> being over the stackpanel, yet when the mouse is moved a little further to the right (over the two ellipses, which are on the canvas), the mouse is reported to be over the stackpanel again.</p>
  
  <p>Why is it that when the mouse is over the canvas it is reported as not being over the stackpanel but when the mouse is over the ellipses (which are painted on the canvas) it is reported as being on the stackpanel ?.</p>
  
  <p>thank you for shedding light into the problem,</p>
  
  <p>John.</p>