From 68247b0c8596984c86f0cf046613419aeecdf35e 2008-07-15 06:45:29 From: Gael Varoquaux Date: 2008-07-15 06:45:29 Subject: [PATCH] Added "ctr-K" to delete current buffer. --- diff --git a/IPython/frontend/wx/console_widget.py b/IPython/frontend/wx/console_widget.py index e5e855d..a845a0b 100644 --- a/IPython/frontend/wx/console_widget.py +++ b/IPython/frontend/wx/console_widget.py @@ -325,17 +325,18 @@ class ConsoleWidget(editwindow.EditWindow): Return True if event as been catched. """ - catched = False + catched = True # Intercept some specific keys. if event.KeyCode == ord('L') and event.ControlDown() : - catched = True self.scroll_to_bottom() + if event.KeyCode == ord('K') and event.ControlDown() : + self.replace_current_edit_buffer('') elif event.KeyCode == wx.WXK_PAGEUP and event.ShiftDown(): - catched = True self.ScrollPages(-1) elif event.KeyCode == wx.WXK_PAGEDOWN and event.ShiftDown(): - catched = True self.ScrollPages(1) + else: + catched = False if self.AutoCompActive(): event.Skip()