From 85e255bc470d5b0127c270ada82f31e5c533d188 2010-09-09 05:50:59 From: Fernando Perez Date: 2010-09-09 05:50:59 Subject: [PATCH] Renamed 'payload-svg' matplotlib backend to 'inline'. --- diff --git a/IPython/frontend/qt/console/ipythonqt.py b/IPython/frontend/qt/console/ipythonqt.py index cae3f0a..c720c88 100644 --- a/IPython/frontend/qt/console/ipythonqt.py +++ b/IPython/frontend/qt/console/ipythonqt.py @@ -88,7 +88,7 @@ def main(): const='auto', help = \ "Pre-load matplotlib and numpy for interactive use. If GUI is not \ given, the GUI backend is matplotlib's, otherwise use one of: \ - ['tk', 'gtk', 'qt', 'wx', 'payload-svg'].") + ['tk', 'gtk', 'qt', 'wx', 'inline'].") wgroup = parser.add_argument_group('widget options') wgroup.add_argument('--paging', type=str, default='inside', diff --git a/IPython/lib/pylabtools.py b/IPython/lib/pylabtools.py index 44d204f..416f04e 100644 --- a/IPython/lib/pylabtools.py +++ b/IPython/lib/pylabtools.py @@ -28,7 +28,7 @@ backends = {'tk': 'TkAgg', 'wx': 'WXAgg', 'qt': 'Qt4Agg', # qt3 not supported 'qt4': 'Qt4Agg', - 'payload-svg' : 'module://IPython.zmq.pylab.backend_payload_svg'} + 'inline' : 'module://IPython.zmq.pylab.backend_inline'} #----------------------------------------------------------------------------- # Main classes and functions @@ -41,12 +41,12 @@ def find_gui_and_backend(gui=None): Parameters ---------- gui : str - Can be one of ('tk','gtk','wx','qt','qt4','payload-svg'). + Can be one of ('tk','gtk','wx','qt','qt4','inline'). Returns ------- A tuple of (gui, backend) where backend is one of ('TkAgg','GTKAgg', - 'WXAgg','Qt4Agg','module://IPython.zmq.pylab.backend_payload_svg'). + 'WXAgg','Qt4Agg','module://IPython.zmq.pylab.backend_inline'). """ import matplotlib @@ -108,11 +108,11 @@ def import_pylab(user_ns, backend, import_all=True, shell=None): # If using our svg payload backend, register the post-execution # function that will pick up the results for display. This can only be # done with access to the real shell object. - if backend == backends['payload-svg']: - from IPython.zmq.pylab.backend_payload_svg import flush_svg + if backend == backends['inline']: + from IPython.zmq.pylab.backend_inline import flush_svg shell.register_post_execute(flush_svg) else: - from IPython.zmq.pylab.backend_payload_svg import paste + from IPython.zmq.pylab.backend_inline import paste from matplotlib import pyplot # Add 'paste' to pyplot and to the user's namespace user_ns['paste'] = pyplot.paste = paste diff --git a/IPython/zmq/ipkernel.py b/IPython/zmq/ipkernel.py index e34bf84..b2e0f5c 100755 --- a/IPython/zmq/ipkernel.py +++ b/IPython/zmq/ipkernel.py @@ -550,7 +550,7 @@ def main(): const='auto', help = \ "Pre-load matplotlib and numpy for interactive use. If GUI is not \ given, the GUI backend is matplotlib's, otherwise use one of: \ -['tk', 'gtk', 'qt', 'wx', 'payload-svg'].") +['tk', 'gtk', 'qt', 'wx', 'inline'].") namespace = parser.parse_args() kernel_class = Kernel @@ -558,7 +558,7 @@ given, the GUI backend is matplotlib's, otherwise use one of: \ kernel_classes = { 'qt' : QtKernel, 'qt4': QtKernel, - 'payload-svg': Kernel, + 'inline': Kernel, 'wx' : WxKernel, 'tk' : TkKernel, 'gtk': GTKKernel, diff --git a/IPython/zmq/pylab/backend_payload_svg.py b/IPython/zmq/pylab/backend_inline.py similarity index 100% rename from IPython/zmq/pylab/backend_payload_svg.py rename to IPython/zmq/pylab/backend_inline.py