Pre loader

Highlight point markers and show tooltip with X value and Y value

Welcome to the SciChart Forums!

  • Please read our Question Asking Guidelines for how to format a good question
  • Some reputation is required to post answers. Get up-voted to avoid the spam filter!
  • We welcome community answers and upvotes. Every Q&A improves SciChart for everyone

WPF Forums | JavaScript Forums | Android Forums | iOS Forums

1
0

Hello,
I am currently evaluating the chart library, and plotting a FastLineRenderableSeries with an Ellipse PointMarker.
This displays exactly the graph I want. However, I would like that when the user hovers over a point, the point would highlight and he can see a tooltip showing what is the exact X value and the exact Y value.
Example of what I would like : http://www.highcharts.com/demo/line-basic
Would be even better if when hovering over the line the “nearest” actual point were highlighted with the tooltip.
I have tried a quick search and haven’t come up with the solution yet, note I am new to the library.
Thanks

  • You must to post comments
0
0

Hi Jean-Jacques,

Thank you for your enquiry! SciChart has a rich ChartModifier API which allows you to tag modifiers (behaviours) on to a chart to give it different actions on mouse move, mouse down etc…

The first ChartModifier you need to add is the TooltipModifier. This will give you mouse-over tooltips on a point-marker.

To achieve highlighting of the line on mouse over, we don’t support this out of the box but we do support something quite similar. The SeriesSelectionModifier allows applying a custom style to a line on mouse-up (selection) of a series. I’m sure it could be re-worked to try-select on mouse move not mouse up.

 public class SeriesSelectionModifierEx : SeriesSelectionModifier 
 {
      public override void OnModifierMouseUp(ModifierMouseArgs e) 
      { 
      }

      public override void OnModifierMouseMove(ModifierMouseArgs e) 
      { 
            base.OnModifierMouseUp(e);
      }
 }

Let me know if this helps

  • You must to post comments
0
0

Thanks, I have done the first part (tooltip modifier) , will do the second one but works perfectly.

  • Andrew Burnett-Thompson
    Great, let me know if you need anything else. Please be advised, continuous selection on mouse-move will add some CPU load to your application. There are other solutions like it may be possible to modify TooltipModifier (which does the hit-test already) to perform both actions: Highlighting AND tooltip
  • Jean-Jacques Bouzaglou
    How should I modify the tooltip modifier?I can try to implement and monitor the CPU usage anyway. I haven’t asked the question but to give context I will want to do something when a point is clicked according to it’s X/Y coordinates (the idea will be to provide context on that point, maybe with another chart).
  • You must to post comments
Showing 2 results
Your Answer

Please first to submit.

Try SciChart Today

Start a trial and discover why we are the choice
of demanding developers worldwide

Start TrialCase Studies