Some work was done in the ns-3 project to update the embedding of IPython into GTK-2, from around 2014. That code looks like it might be compatible with IPython 4.x but not with 5.x. As of IPython 5.x, everything seems to have changed: see the new documentation. But there is also a rough patch that makes this work in IPython 5, at least in a basic way.
From the above, a patched and working version of ipython_view.py
is at:
http://code.ascend4.org/ascend/trunk/pygtk/ipython_view.py?view=markup
Test it using:
python python-iview.py
It seems to work OK on both Ubuntu 17.10 (IPython 5.1.0) and Ubuntu 16.04 (IPython 2.4.1). The color prompt is not enabled (yet) with the IPython 5.x version.