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

0 votes

I am working on the spectrogram (heatmap) that can be interacted with fingers. It can only pan horizontally, and the Z values from heatmap will be updated whenever panning stopped.

I override onUp function from ZoomPanModifier to fetch the latest x range, which is temporarily logged by VisiableRangeChangeListener. But the issue is, when I’m panning with the finger horizontally, the chart will always be moving a little bit after onUp() occurred. So there’s a difference between the desired x range and actual x range.

Is there a way to get the final x range after a panning action?


  • Gang Xu asked 1 year ago
  • last active 1 year ago
0 votes

It seems most of the modifiers bring up tooltip data with a pan, and then it goes away when the user lifts their finger. Is there any way to bring up tooltip data with a tap (and does not go away when the finger has lifted)? The main problem that we’re trying to solve is that we would like to be able to pan to look at the chart (and don’t want an axis pan), but would also like to bring up tooltip data.

  • Carolyn asked 2 years ago
  • last active 2 years ago
0 votes

I cannot get panning to work on the x axis which is a DateTimeAxis. I am databinding the visible range to a property on my view model and the zooming works ok. Also panning on the Y-axis works.

Here is my XAML:

<s:SciChartSurface x:Name="_sciChartSurface" Grid.Row="1" Grid.ColumnSpan="2" RenderableSeries="{s:SeriesBinding PlotViewModels}">
                <s:DateTimeAxis AxisTitle="{Binding HorizontalTitle}" VisibleRange="{Binding HorizontalRange, Mode=TwoWay}" AutoRange="Never"
                            IsStaticAxis="True" DrawMajorBands="False" TextFormatting="dd-MMM-yyyy" SubDayTextFormatting="H:mm:ss:tt"
                <s:NumericAxis AxisTitle="{Binding VerticalTitle}" AxisAlignment="Left"  VisibleRange="{Binding VerticalRange}"
                           AutoRange="{Binding AutoRange}" DrawMajorBands="False"/>

                    <s:RubberBandXyZoomModifier IsXAxisOnly="False" 
                                            RubberBandFill="#55FFFFFF" RubberBandStroke="#FFFFFFFF" RubberBandStrokeDashArray="2 2">

                    <s:ZoomPanModifier ExecuteOn="MouseRightButton" ClipModeX="None" XyDirection="XYDirection" IsEnabled="True" />
                    <!-- Allow Dragging YAxis to Scale -->
                    <s:YAxisDragModifier DragMode="Scale"/>
                    <!-- Allow Dragging XAxis to Pan -->
                    <s:XAxisDragModifier DragMode="Scale" IsEnabled="True"/>

                    <s:MouseWheelZoomModifier ActionType="Zoom" XyDirection="XYDirection"/>

                    <s:ZoomExtentsModifier IsAnimated="True" ExecuteOn="MouseDoubleClick"/>
0 votes


I’m trying to limit the x-axis panning up to an annotation that I’ve drawn on the graph. This annotation can be beyond the current data’s position (i.e. data’s timestamp is at 5/4/2017 11:00:00, annotation’s position is at 5/4/2017 16:00:00). Is there a method, or any way that I can use to limit the x-axis panning up to the annotation’s position instead of limiting it to the data series’ max X?


1 vote

How do I implement mouse wheel zooming so that the point under the mouse pointer (before zoom), will also be under the mouse pointer after the zoom?
The chart is a 2D chart with DateTime X axis and multiple value Y axes.

1 vote

Hi Scichart,

I am struggling with a ContextMenu on a SciChartSurface that wont be displayed.

The problem started when i added mouse panning with the right mouse-button which is the same button the ContextMenu is activated on.

So will this combination even work – with both a ContextMenu and mouse panning with the right mouse button?

To manually validate if the ContextMenu should open or if the panning should be enabled, I have tried to get the mouse coordinates manually in C# to see if the mouse was moved(panning) or if it was a click(ContextMenu). This did not work very well when i afterwards started to pan/zoom again.

Do you have a code example using both a ContextMenu and mouse panning using right mouse button?

Best regards,

Showing 6 results
This template supports the sidebar's widgets. Add one or use Full Width layout.