@@ -2619,18 +2619,25 @@ def show(self, warn=True):
2619
2619
may only be shown briefly or not shown at all if you or your
2620
2620
environment are not managing an event loop.
2621
2621
2622
- Proper use cases for `.Figure.show` include running this from a
2623
- GUI application or an IPython shell.
2624
-
2625
- If you're running a pure python shell or executing a non-GUI
2626
- python script, you should use `matplotlib.pyplot.show` instead,
2627
- which takes care of managing the event loop for you.
2622
+ Use cases for `.Figure.show` include running this from a GUI
2623
+ application (where there is persistently an event loop running) or
2624
+ from a shell, like IPython, that install an input hook to allow the
2625
+ interactive shell to accept input while the figure is also being
2626
+ shown and interactive. Some, but not all, GUI toolkits will
2627
+ register an input hook on import. See :ref:`cp_integration` for
2628
+ more details.
2629
+
2630
+ If you're in a shell without input hook integration or executing a
2631
+ python script, you should use `matplotlib.pyplot.show` with
2632
+ ``block=True`` instead, which takes care of starting and running
2633
+ the event loop for you.
2628
2634
2629
2635
Parameters
2630
2636
----------
2631
2637
warn : bool, default: True
2632
2638
If ``True`` and we are not running headless (i.e. on Linux with an
2633
2639
unset DISPLAY), issue warning when called on a non-GUI backend.
2640
+
2634
2641
"""
2635
2642
if self .canvas .manager is None :
2636
2643
raise AttributeError (
0 commit comments