##// END OF EJS Templates
Remove the "autoedit_syntax" feature....
Remove the "autoedit_syntax" feature. IPython used to (a long time ago, in a galaxy far far away) have the ability to automatically open an editor in case a wild syntax error appears. The configuration option to enable that was not working for a few years, and apparently we by mistake re enabled it, to discover that the feature is actually broken. So this plainly remove the code to support this feature, at the exception of the `fix_error_editor` hook. Indeed it is public API, so for now as it seem to be used only for this feature, we'll just raise a UserWarning (there is roughly 0 chance of this being tested as it's used mostly interactively, so DeprecationWarnings would be unseen). We'll remove later if no complaints Closes #9603

File last commit:

r21944:f34eb22e
r22576:b7d03ed6
Show More
gui-gtk3.py
37 lines | 773 B | text/x-python | PythonLexer
#!/usr/bin/env python
"""Simple Gtk example to manually test event loop integration.
This is meant to run tests manually in ipython as:
In [1]: %gui gtk3
In [2]: %run gui-gtk3.py
"""
from gi.repository import Gtk
def hello_world(wigdet, data=None):
print("Hello World")
def delete_event(widget, event, data=None):
return False
def destroy(widget, data=None):
Gtk.main_quit()
window = Gtk.Window(type=Gtk.WindowType.TOPLEVEL)
window.connect("delete_event", delete_event)
window.connect("destroy", destroy)
button = Gtk.Button(label="Hello World")
button.connect("clicked", hello_world, None)
window.add(button)
button.show()
window.show()
try:
from IPython.lib.inputhook import enable_gui
enable_gui('gtk3')
except ImportError:
Gtk.main()