locked
Custom Cursor RRS feed

  • Question

  • I managed to create a custom cursor on a canvas using the following blog advice:

    http://blogs.silverlight.net/blogs/msnow/archive/2010/03/16/81607.aspx

    But I have a strange problem, the canvas it's on has lots of shapes (rectangles, ellipses etc) and when the mouse moves over them I give them a border colour to indicate they are being hovered over.  However with the custom cursor if I am moving up or left it works fine but moving right or down intermittently triggers the shapes' mousemove event???

    Any ideas??

    Wednesday, September 14, 2011 9:12 AM

Answers

  • Hi,

    The solution is:

    public partial class Cursor : UserControl

        {

            public Cursor()

            {

                InitializeComponent();

                this.IsHitTestVisible = false;

            }

    }

    Hope it can help you

    Friday, September 16, 2011 3:49 AM
  • Hi,

    Here's another you can have a look at:

    Silverlight Behavior Modifications #9 - PointerBehavior

    http://www.dataartist.net/blog/post/Silverlight-Behavior-Modifications-9-PointerBehavior.aspx

    Online sample and source code are available from link above.

    If this answers your question, please Mark as an answer. Thank you. 

    Sunday, September 18, 2011 2:08 PM

All replies