From d863907163e1dcf20007b1eee816866353a44057 Mon Sep 17 00:00:00 2001 From: bsobhani Date: Mon, 7 Jun 2021 00:19:23 -0400 Subject: [PATCH] add function to disable autoscaling (#1819) --- pyqtgraph/graphicsItems/HistogramLUTItem.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pyqtgraph/graphicsItems/HistogramLUTItem.py b/pyqtgraph/graphicsItems/HistogramLUTItem.py index 7306ebec..348684b9 100644 --- a/pyqtgraph/graphicsItems/HistogramLUTItem.py +++ b/pyqtgraph/graphicsItems/HistogramLUTItem.py @@ -268,6 +268,10 @@ class HistogramLUTItem(GraphicsWidget): """Enable auto-scaling on the histogram plot.""" self.vb.enableAutoRange(self.vb.XYAxes) + def disableAutoHistogramRange(self): + """Disable auto-scaling on the histogram plot.""" + self.vb.disableAutoRange(self.vb.XYAxes) + def setImageItem(self, img): """Set an ImageItem to have its levels and LUT automatically controlled by this HistogramLUTItem.