SciChart® the market leader in Fast WPF Charts, WPF 3D Charts, iOS Chart, Android Chart and JavaScript Chart Components

0
0

I want to apply a Style that has removed the horizontal lines of the CursorModifier.

private void ExecuteLoadedCommand(StackGraphViewer parameter)
    {
        if (root == null) root = parameter;

        root.sciChart.ViewportManager = _scrollManager;

        // Remove CrosshairsHorizLine
        root.sciChart.MouseMove += RemoveCrosshairsHorizLine;
    }

    private void RemoveCrosshairsHorizLine(object sender, MouseEventArgs e)
    {
        Line crosshairsHorizLine = root.sciChart.ModifierSurface.Children.OfType<Line>().FirstOrDefault(line => line.X1.CompareTo(0d) == 0);
        if (root.sciChart.ModifierSurface.Children.Contains(crosshairsHorizLine))
        {
            root.sciChart.ModifierSurface.Children.Remove(crosshairsHorizLine);
            root.sciChart.MouseMove -= RemoveCrosshairsHorizLine;
        }
    }

I want to solve it in View XAML, not ViewModel Code.

What should I do?

Version
6.3.0.13476
  • You must to post comments
0
0

Hi Park Seong Gyu,

Thanks for your inquiry.
As an option, you can create a Style for the CursorModifier Crosshair Lines and set the StrokeThickness property to 0 or Stroke property to Transparent.
Please take a look at the “Styling the CursorModifier Crosshair Lines” section of the following article for more info:
https://www.scichart.com/documentation/win/current/webframe.html#CursorModifier.html

Please let me know if this helps.

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.