##// END OF EJS Templates
Add better keybindings.
Gael Varoquaux -
Show More
@@ -241,6 +241,7 b' class ConsoleWidget(editwindow.EditWindow):'
241 self.CmdKeyClear(ord('D'), stc.STC_SCMOD_CTRL)
241 self.CmdKeyClear(ord('D'), stc.STC_SCMOD_CTRL)
242 self.CmdKeyClear(ord('L'), stc.STC_SCMOD_CTRL)
242 self.CmdKeyClear(ord('L'), stc.STC_SCMOD_CTRL)
243 self.CmdKeyClear(ord('T'), stc.STC_SCMOD_CTRL)
243 self.CmdKeyClear(ord('T'), stc.STC_SCMOD_CTRL)
244 self.CmdKeyClear(ord('A'), stc.STC_SCMOD_CTRL)
244
245
245 self.SetEOLMode(stc.STC_EOL_CRLF)
246 self.SetEOLMode(stc.STC_EOL_CRLF)
246 self.SetWrapMode(stc.STC_WRAP_CHAR)
247 self.SetWrapMode(stc.STC_WRAP_CHAR)
@@ -312,6 +313,14 b' class ConsoleWidget(editwindow.EditWindow):'
312 self.scroll_to_bottom()
313 self.scroll_to_bottom()
313 elif event.KeyCode == ord('K') and event.ControlDown() :
314 elif event.KeyCode == ord('K') and event.ControlDown() :
314 self.input_buffer = ''
315 self.input_buffer = ''
316 elif event.KeyCode == ord('A') and event.ControlDown() :
317 self.GotoPos(self.GetLength())
318 self.SetSelectionStart(self.current_prompt_pos)
319 self.SetSelectionEnd(self.GetCurrentPos())
320 catched = True
321 elif event.KeyCode == ord('E') and event.ControlDown() :
322 self.GotoPos(self.GetLength())
323 catched = True
315 elif event.KeyCode == wx.WXK_PAGEUP:
324 elif event.KeyCode == wx.WXK_PAGEUP:
316 self.ScrollPages(-1)
325 self.ScrollPages(-1)
317 elif event.KeyCode == wx.WXK_PAGEDOWN:
326 elif event.KeyCode == wx.WXK_PAGEDOWN:
@@ -343,7 +352,7 b' class ConsoleWidget(editwindow.EditWindow):'
343 self.GotoPos(self.current_prompt_pos)
352 self.GotoPos(self.current_prompt_pos)
344 catched = True
353 catched = True
345
354
346 elif event.Modifiers in (wx.MOD_SHIFT, wx.MOD_WIN) :
355 elif event.Modifiers == wx.MOD_SHIFT:
347 # FIXME: This behavior is not ideal: if the selection
356 # FIXME: This behavior is not ideal: if the selection
348 # is already started, it will jump.
357 # is already started, it will jump.
349 self.SetSelectionStart(self.current_prompt_pos)
358 self.SetSelectionStart(self.current_prompt_pos)
General Comments 0
You need to be logged in to leave comments. Login now