diff options
| author | robot-piglet <[email protected]> | 2024-05-01 17:09:14 +0300 |
|---|---|---|
| committer | robot-piglet <[email protected]> | 2024-05-01 17:20:35 +0300 |
| commit | 03f7adb942a10897d7998b647057889c322347c6 (patch) | |
| tree | 0a6d351f47e0bd85356e72e7eb7dd925d7ef1587 /contrib/python/matplotlib-inline/matplotlib_inline/backend_inline.py | |
| parent | 5bc4b66b9854b20dc9d39e2640d7e96a11a33769 (diff) | |
Intermediate changes
Diffstat (limited to 'contrib/python/matplotlib-inline/matplotlib_inline/backend_inline.py')
| -rw-r--r-- | contrib/python/matplotlib-inline/matplotlib_inline/backend_inline.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/contrib/python/matplotlib-inline/matplotlib_inline/backend_inline.py b/contrib/python/matplotlib-inline/matplotlib_inline/backend_inline.py index 6bcc1d4a013..05554b0d223 100644 --- a/contrib/python/matplotlib-inline/matplotlib_inline/backend_inline.py +++ b/contrib/python/matplotlib-inline/matplotlib_inline/backend_inline.py @@ -176,7 +176,7 @@ def configure_inline_support(shell, backend): if cfg not in shell.configurables: shell.configurables.append(cfg) - if backend == 'module://matplotlib_inline.backend_inline': + if backend in ('inline', 'module://matplotlib_inline.backend_inline'): shell.events.register('post_execute', flush_figures) # Save rcParams that will be overwrittern @@ -211,7 +211,7 @@ def _enable_matplotlib_integration(): from matplotlib import get_backend ip = get_ipython() backend = get_backend() - if ip and backend == 'module://%s' % __name__: + if ip and backend in ('inline', 'module://matplotlib_inline.backend_inline'): from IPython.core.pylabtools import activate_matplotlib try: activate_matplotlib(backend) |
