From df192f12d281893d5a9c75e17f3df52bf75c3654 2016-06-06 21:33:57 From: Sylvain Corlay Date: 2016-06-06 21:33:57 Subject: [PATCH] page_dumb mime bundle --- diff --git a/IPython/core/page.py b/IPython/core/page.py index ec2e077..6d213c9 100644 --- a/IPython/core/page.py +++ b/IPython/core/page.py @@ -38,7 +38,7 @@ def display_page(strng, start=0, screen_lines=25): else: if start: strng = u'\n'.join(strng.splitlines()[start:]) - data = {'text/plain': strng} + data = { 'text/plain': strng } display(data, raw=True) @@ -56,8 +56,10 @@ def page_dumb(strng, start=0, screen_lines=25): """Very dumb 'pager' in Python, for when nothing else works. Only moves forward, same interface as page(), except for pager_cmd and - mode.""" - + mode. + """ + if isinstance(strng, dict): + strng = strng.get('text/plain', '') out_ln = strng.splitlines()[start:] screens = chop(out_ln,screen_lines-1) if len(screens) == 1: