Show More
@@ -0,0 +1,27 b'' | |||
|
1 | #!/usr/bin/env python | |
|
2 | # encoding: utf-8 | |
|
3 | """ | |
|
4 | Extra capabilities for IPython | |
|
5 | """ | |
|
6 | ||
|
7 | #----------------------------------------------------------------------------- | |
|
8 | # Copyright (C) 2008-2009 The IPython Development Team | |
|
9 | # | |
|
10 | # Distributed under the terms of the BSD License. The full license is in | |
|
11 | # the file COPYING, distributed as part of this software. | |
|
12 | #----------------------------------------------------------------------------- | |
|
13 | ||
|
14 | #----------------------------------------------------------------------------- | |
|
15 | # Imports | |
|
16 | #----------------------------------------------------------------------------- | |
|
17 | ||
|
18 | from IPython.lib.inputhook import ( | |
|
19 | enable_wx, disable_wx, | |
|
20 | enable_gtk, disable_gtk, | |
|
21 | enable_qt4, disable_qt4, | |
|
22 | enable_tk, disable_tk | |
|
23 | ) | |
|
24 | ||
|
25 | #----------------------------------------------------------------------------- | |
|
26 | # Code | |
|
27 | #----------------------------------------------------------------------------- No newline at end of file |
@@ -60,7 +60,7 b' class InputHookManager(object):' | |||
|
60 | 60 | return original |
|
61 | 61 | |
|
62 | 62 | def enable_wx(self): |
|
63 |
from IPython.lib. |
|
|
63 | from IPython.lib.inputhookwx import inputhook_wx | |
|
64 | 64 | self.set_inputhook(inputhook_wx) |
|
65 | 65 | |
|
66 | 66 | def disable_wx(self): |
@@ -86,7 +86,7 b' class InputHookManager(object):' | |||
|
86 | 86 | gtk.set_interactive(True) |
|
87 | 87 | except AttributeError: |
|
88 | 88 | # For older versions of gtk, use our own ctypes version |
|
89 |
from IPython.lib. |
|
|
89 | from IPython.lib.inputhookgtk import inputhook_gtk | |
|
90 | 90 | add_inputhook(inputhook_gtk) |
|
91 | 91 | |
|
92 | 92 | def disable_gtk(self): |
@@ -107,3 +107,5 b' enable_qt4 = inputhook_manager.enable_qt4' | |||
|
107 | 107 | disable_qt4 = inputhook_manager.disable_qt4 |
|
108 | 108 | enable_gtk = inputhook_manager.enable_gtk |
|
109 | 109 | disable_gtk = inputhook_manager.disable_gtk |
|
110 | enable_tk = inputhook_manager.enable_tk | |
|
111 | disable_tk = inputhook_manager.disable_tk No newline at end of file |
General Comments 0
You need to be logged in to leave comments.
Login now