Being fair, one of these lines isn't bogus yet, but would be if I
indented it one more step, and I intend to do just that now.
else:
reg = pt.application.key_bindings_registry
try: bind = reg.add_binding
else:
reg = pt.application.key_bindings_registry
try: bind = reg.add_binding
- except AttributeError: bind = PTK.key_binding.bindings.utils.create_handle_decorator(reg)
+ except AttributeError:
+ bind = PTK.key_binding.bindings.utils.create_handle_decorator(reg)
def inhibit_history_search(buf, fn):
def inhibit_history_search(buf, fn):
- searchp, searchtext = buf.enable_history_search, buf.history_search_text
+ searchp, searchtext = \
+ buf.enable_history_search, buf.history_search_text
buf.enable_history_search = F.Never()
try:
fn()
finally:
buf.enable_history_search = F.Never()
try:
fn()
finally:
- buf.enable_history_search, buf.history_search_text = searchp, searchtext
+ buf.enable_history_search, buf.history_search_text = \
+ searchp, searchtext
@bind(K.ControlP)
def prev_line(ev):
buf = ev.current_buffer
@bind(K.ControlP)
def prev_line(ev):
buf = ev.current_buffer