Trackball Closest Horizontal Only

4 posts, 0 answers
  1. Steven
    Steven avatar
    37 posts
    Member since:
    Jul 2012

    Posted 10 Jun 2015 Link to this post

    Hi,

    I was wondering if there was a way to get the trackball to snap to the closest point by taking only the horizontal distance into consideration?

     We have a chart with a number of series which all have the same set of x values. We have the trackball behavior enabled and what we would like to be able to do is to show details about each series but for one x value at a time. The default behavior seems to get the closest points for each series by taking the closest point to the mouse. This means, depending on mouse location, that the trackball can be showing values from 2 points which have different x values. Is there a way to stop this and to get the trackball to snap only to x values?

     

    Thanks,

     

    Steven

  2. Petar Marchev
    Admin
    Petar Marchev avatar
    968 posts

    Posted 11 Jun 2015 Link to this post

    Hi Steven,

    I am a little confused. What you describe as a desired result is exactly what the chart offers out-of-the-box as a trackball behavior. I have attached a project demonstrating this. In the image I attached, you can see where the mouse cursor was (much closer to the point with XValue 2) and the trackball shows information about XValue 3 because it is closer horizontally.

    Please share more details if you think that I have misunderstood something.

    Regards,
    Petar Marchev
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. UI for WPF is Visual Studio 2017 Ready
  4. Steven
    Steven avatar
    37 posts
    Member since:
    Jul 2012

    Posted 11 Jun 2015 Link to this post

    Hi Petar,

    That is interesting as that is not what we see. I have attached a picture of what we see. As you can see the mouse is much closer horizontally to the blue square with the red circle than the blue square with the yellow circle, yet the point with the yellow circle is selected. We haven't modified the trackball behavior at all.

    Sorry, I should have attached the picture yesterday.

    Thanks,

    Steven

  5. Petar Marchev
    Admin
    Petar Marchev avatar
    968 posts

    Posted 12 Jun 2015 Link to this post

    Hello Steven,

    Have you tried running the project I sent? What is the behavior of the track ball in it?

    You can examine the project I sent and look for differences with your actual code. Perhaps by finding the differences, you can find out what is causing this.

    Regards,
    Petar Marchev
    Telerik
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Back to Top