How to disable scroll in plotview?

Max S 5 year бұрын updated by Samuel Guedon 5 year бұрын 3

I would like to disable the possibility to scroll/zoom in my plotview. I dont want the user to scroll/zoom away from the graph by misstake.

Is this possible?

var linearAxis1 = new LinearAxis();
linearAxis1.IsZoomEnabled = false;
linearAxis1.IsPanEnabled = false;

Check examples there http://resources.oxyplot.org/examplebrowser/
Max, you can also set a maximum / minimum pan/zoom on each axis :

linearAxis1.AbsoluteMaximum = 63;
linearAxis1.AbsoluteMinimum = -17;

here your user will be able to zoom and pan but only in the -17 to 63 range on the specified axis.