Hi.
I use MouseWheelZoomModifier. If some modifier key pressed (Ctrl, Shift, Alt) it produces scroll instead of zoom. My X axis is styled as follows:
<Style TargetType="s:DateTimeAxis">
<Setter Property="TextFormatting" Value="dd-MM-yyyy"/>
<Setter Property="SubDayTextFormatting" Value="HH:mm:ss"/>
<Setter Property="AutoRange" Value="Never"/>
<Setter Property="GrowBy" Value="0.1, 0.1"/>
<Setter Property="AxisAlignment" Value="Bottom"/>
<Setter Property="VisibleRangeLimitMode" Value="MinMax"/>
<Setter Property="VisibleRange" Value="{Binding Mode=OneWay, RelativeSource={RelativeSource Mode=Self}, Path=VisibleRangeLimit}"/>
</Style>
VisibleRangeLimit is set in code behind. So as you can see X axis can not go out of VisibleRangeLimit. So we came to my problem: with MouseWheelZoomModifier if I hold Ctrl button and scrolling, when X axis comes to limit it starts to zoom X axis.
The same happens with ZoomPanModifier, but in ZoomPanModifier it can be disabled by setting ClipModeX=”ClipAtExtents”, so when you approaches to the border and continue panning it simply do nothing – that’s what behavour I need in MouseWheelZoomModifier with Ctlr key pressed. I could not find anything like this in MouseWheelZoomModifier. Any ideas?
- Grigoriy Vasilchenko asked 2 years ago
- last active 2 years ago
I want to zoom the chart using mouse wheel. But not zoom at mouse point center, but at the specified point center I set.
How can I do it?
Is there any properties for MouseWheelZoomModifier?
- Hiroyuki Seki asked 4 years ago
- last active 4 years ago
I need MouseWheelZoomModifier to work only when I pressed mouse button. I wrote:
<s:MouseWheelZoomModifier ExecuteOn="MouseRightButton" />
But it all the same executing when I’m not pressing mouse button. Why?
- Denis Denis asked 5 years ago
- last active 5 years ago
Dear all,
Does anyone of you have a solution in order to avoid zooming out too much when using the mouse wheel button ?
What I means is that if you call the ZoomExtents the graph will zoom out to fit in chart viewport. By using the mouse wheel is there a way to stop zooming where we reach zoomextents range ?
regards
- sc sc asked 5 years ago
- last active 5 years ago
I have a Chart with two Y-Axes, one on the left and one on the right for a SeriesvalueModifier.
i need to bind the VisibleRange to a Property in the ViewModel. Everything works fine, except for if i zoom via the MouseWheelZoomModifier.
It looks like the Chart gets “stretched” in Y direction. I guess the modifier zooms on both axes, so the property they are both bound to gets two updates, one for each axis.
When i bind the VisibleRange of Axis[A] to theVisibleRange of Axis[B] which is bound to the property also won’t work.
Do you have any idea how this could be fixed ?
what i want to achieve is this behavior:
Axis[A]
<s:NumericAxis
x:Name="NumericAxis_Mass"
x:Key="NumericAxis_Mass"
Id="NumericAxis_Mass"
AxisTitle="{ext:Localization Chart_Axis_PartialPressure}"
GrowBy="0.1,0.1"
VisibleRange="{Binding YVisibleRange,
Mode=TwoWay,
UpdateSourceTrigger=PropertyChanged,
NotifyOnSourceUpdated=True,
NotifyOnTargetUpdated=True}"
AutoRange="{Binding AnalysesAutoRange_y,
Mode=TwoWay,
UpdateSourceTrigger=PropertyChanged,
NotifyOnSourceUpdated=True,
NotifyOnTargetUpdated=True}"
AxisAlignment="Left"
Style="{StaticResource Chart.NumericAxis.Style}" />
Axis[B]
<s:NumericAxis
x:Key="NumericAxis_Mass_Empty"
x:Name="NumericAxis_Mass_Empty"
GrowBy="0.1,0.1"
TextFormatting="0.00E+00"
VisibleRange="{Binding YVisibleRange,
Mode=TwoWay,
UpdateSourceTrigger=PropertyChanged,
NotifyOnSourceUpdated=True,
NotifyOnTargetUpdated=True}"
AutoRange="{Binding AnalysesAutoRange_y,
Mode=TwoWay,
UpdateSourceTrigger=PropertyChanged,
NotifyOnSourceUpdated=True,
NotifyOnTargetUpdated=True}"
AxisAlignment="Right"
Style="{StaticResource Chart.NumericAxis.Style}"
DrawLabels="False"
DrawMajorBands="False"
DrawMajorGridLines="False"
DrawMajorTicks="False"
DrawMinorGridLines="False"
DrawMinorTicks="False"
Margin="35,0,0,0"
Width="auto" />
- Dirk Heyne asked 6 years ago
- last active 6 years ago
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.
- Søren Bech Christensen asked 6 years ago
- last active 6 years ago
Due to the user often needing to select pre-specified ranges of data to view, I handle the X- and Y-axis VisibleRange manually in code.
I also have both RubberBandXyZoomModifier and MouseWheelZoomModifier enabled.
Instead of using a generic ZoomExtentsModifier (which would show all data), I handle a MouseDoubleClick in code and set the VisibleRanges to the bounds of the user-selected data area’s range.
Now if the RubberBand zoom is used followed by a double-click, the VisibleRange.SetMinMax function gets called with the correct values in my code, but that range does not appear on the chart. However if a MouseWheelZoom is used after the RubberBand zoom, it works fine. Is there something about the RubberBand zoom that is stopping the VisibleRange.SetMinMax function values from being recognized by the chart?
Thanks!
- Matthew Becker asked 7 years ago
- last active 7 years ago
Hi,
in a MVVM scenario, I bind the AnimatedVisibleRange to a property in the view model.
<s:SciChartSurface SeriesSource="{Binding ChartSeries}">
<s:SciChartSurface.XAxis>
<s:NumericAxis AxisTitle="x" AnimatedVisibleRange="{Binding XVisibleRange, Mode=TwoWay}" AutoRange="Never" />
</s:SciChartSurface.XAxis>
<s:SciChartSurface.YAxis>
<s:NumericAxis AxisTitle="y" AnimatedVisibleRange="{Binding YVisibleRange, Mode=TwoWay}" AutoRange="Never" />
</s:SciChartSurface.YAxis>
<s:SciChartSurface.ChartModifier>
<s:ModifierGroup>
<s:MouseWheelZoomModifier IsEnabled="True" XyDirection="XDirection"/>
</s:ModifierGroup>
</s:SciChartSurface.ChartModifier>
</s:SciChartSurface>
Setting the XVisibleRange property in the view model smoothly animates the view. However, when I zoom in the chart with the mouse wheel, the view model property receives no updates (so the XVisibleRange property in the view model always stays on the value initially set by the view model).
The same thing works when I bind he VisibleRange instead of the AnimatedVisibleRange, i.e. in that case I get an update of the view model property on every mouse wheel zoom.
Is this intendend, or a bug? Building a workaround would require additional bindings, which I would like to avoid.
Best regards,
Andree
- Andree Grosse asked 8 years ago
- last active 8 years ago
Hi~ supporter
On testing scichart for a migration of our chart library, I had a some problems.
Because I tested scichart for just two days so It maybe my mistakes..^^
- MouseWheelZoomModifier does not work.
– If There is no series on chart area, MouseWheellZoom works well but After add curve, It stop working.
- Rubber Band Zoom for Stacked bar chart
– After adding serveral stacked bar charts, When I try to do rubber band zoom for stacked bar chart, Stacked bar often disappear.
- ZoomExtants for Stacked bar chart
– After adding several stacked bar charts, When I call “ZoomExtants()”, all stacked bar charts does not fit in chart area.
I attached a sample program.
I will looking forward to your answer.
Regards,
Sunchul
- Sunchul Kim asked 8 years ago
- last active 8 years ago