From 6694e3716ca18441d1ef7fc34ec605bf50830ba0 Mon Sep 17 00:00:00 2001 From: Kyle Sunden Date: Wed, 21 Dec 2022 11:04:30 -0600 Subject: [PATCH] Correct docstring of RangeSlider.on_changed The call is actually made with a tuple (vmin, vmax). Somebody expecting a numpy array may be surprised to find it is not actually an array. --- lib/matplotlib/widgets.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/matplotlib/widgets.py b/lib/matplotlib/widgets.py index a909b856951e..32be7c1b4aad 100644 --- a/lib/matplotlib/widgets.py +++ b/lib/matplotlib/widgets.py @@ -945,7 +945,7 @@ def on_changed(self, func): ---------- func : callable Function to call when slider is changed. The function - must accept a numpy array with shape (2,) as its argument. + must accept a 2-tuple of floats as its argument. Returns -------