Show More
@@ -1,7 +1,6 b'' | |||||
1 | from os.path import abspath, dirname, join |
|
1 | from os.path import abspath, dirname, join | |
2 |
|
2 | |||
3 | from IPython.terminal.interactiveshell import KeyBindingManager |
|
3 | from IPython.terminal.shortcuts import create_ipython_shortcuts | |
4 |
|
||||
5 |
|
4 | |||
6 | def name(c): |
|
5 | def name(c): | |
7 | s = c.__class__.__name__ |
|
6 | s = c.__class__.__name__ | |
@@ -42,8 +41,14 b' def multi_filter_str(flt):' | |||||
42 | log_filters = {'_AndList': 'And', '_OrList': 'Or'} |
|
41 | log_filters = {'_AndList': 'And', '_OrList': 'Or'} | |
43 | log_invert = {'_Invert'} |
|
42 | log_invert = {'_Invert'} | |
44 |
|
43 | |||
45 | kbm = KeyBindingManager.for_prompt() |
|
44 | class _DummyTerminal(object): | |
46 | ipy_bindings = kbm.registry.key_bindings |
|
45 | """Used as a buffer to get prompt_toolkit bindings | |
|
46 | """ | |||
|
47 | handle_return = None | |||
|
48 | input_splitter = None | |||
|
49 | display_completions = None | |||
|
50 | ||||
|
51 | ipy_bindings = create_ipython_shortcuts(_DummyTerminal()).bindings | |||
47 |
|
52 | |||
48 | dummy_docs = [] # ignore bindings without proper documentation |
|
53 | dummy_docs = [] # ignore bindings without proper documentation | |
49 |
|
54 |
General Comments 0
You need to be logged in to leave comments.
Login now