PyCrust updates
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@13341 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -193,7 +193,7 @@ class Shell(wxStyledTextCtrl):
|
||||
self.autoCompleteIncludeDouble = 1
|
||||
self.autoCompleteCaseInsensitive = 1
|
||||
self.AutoCompSetIgnoreCase(self.autoCompleteCaseInsensitive)
|
||||
# De we want to automatically pop up command argument help?
|
||||
# Do we want to automatically pop up command argument help?
|
||||
self.autoCallTip = 1
|
||||
self.CallTipSetBackground(wxColour(255, 255, 232))
|
||||
|
||||
@@ -313,37 +313,41 @@ class Shell(wxStyledTextCtrl):
|
||||
|
||||
Prevents modification of previously submitted commands/responses."""
|
||||
key = event.KeyCode()
|
||||
controlDown = event.ControlDown()
|
||||
altDown = event.AltDown()
|
||||
shiftDown = event.ShiftDown()
|
||||
currpos = self.GetCurrentPos()
|
||||
stoppos = self.promptPos[1]
|
||||
# Return is used to submit a command to the interpreter.
|
||||
if key == WXK_RETURN:
|
||||
if self.AutoCompActive(): self.AutoCompCancel()
|
||||
if self.CallTipActive: self.CallTipCancel()
|
||||
if self.CallTipActive(): self.CallTipCancel()
|
||||
self.processLine()
|
||||
# If the auto-complete window is up let it do its thing.
|
||||
elif self.AutoCompActive():
|
||||
event.Skip()
|
||||
# Let Ctrl-Alt-* get handled normally.
|
||||
elif controlDown and altDown:
|
||||
event.Skip()
|
||||
# Cut to the clipboard.
|
||||
elif event.ControlDown() and key in (ord('X'), ord('x')):
|
||||
elif controlDown and key in (ord('X'), ord('x')):
|
||||
self.Cut()
|
||||
# Copy to the clipboard.
|
||||
elif event.ControlDown() and not event.ShiftDown() \
|
||||
and key in (ord('C'), ord('c')):
|
||||
elif controlDown and not shiftDown and key in (ord('C'), ord('c')):
|
||||
self.Copy()
|
||||
# Copy to the clipboard, including prompts.
|
||||
elif event.ControlDown() and event.ShiftDown() \
|
||||
and key in (ord('C'), ord('c')):
|
||||
elif controlDown and shiftDown and key in (ord('C'), ord('c')):
|
||||
self.CopyWithPrompts()
|
||||
# Paste from the clipboard.
|
||||
elif event.ControlDown() and key in (ord('V'), ord('v')):
|
||||
elif controlDown and key in (ord('V'), ord('v')):
|
||||
self.Paste()
|
||||
# Retrieve the previous command from the history buffer.
|
||||
elif (event.ControlDown() and key == WXK_UP) \
|
||||
or (event.AltDown() and key in (ord('P'), ord('p'))):
|
||||
elif (controlDown and key == WXK_UP) \
|
||||
or (altDown and key in (ord('P'), ord('p'))):
|
||||
self.OnHistoryRetrieve(step=+1)
|
||||
# Retrieve the next command from the history buffer.
|
||||
elif (event.ControlDown() and key == WXK_DOWN) \
|
||||
or (event.AltDown() and key in (ord('N'), ord('n'))):
|
||||
elif (controlDown and key == WXK_DOWN) \
|
||||
or (altDown and key in (ord('N'), ord('n'))):
|
||||
self.OnHistoryRetrieve(step=-1)
|
||||
# Search up the history for the text in front of the cursor.
|
||||
elif key == WXK_F8:
|
||||
@@ -374,6 +378,12 @@ class Shell(wxStyledTextCtrl):
|
||||
# Don't toggle between insert mode and overwrite mode.
|
||||
elif key == WXK_INSERT:
|
||||
pass
|
||||
# Don't allow line deletion.
|
||||
elif controlDown and key in (ord('L'), ord('l')):
|
||||
pass
|
||||
# Don't allow line transposition.
|
||||
elif controlDown and key in (ord('T'), ord('t')):
|
||||
pass
|
||||
# Protect the readonly portion of the shell.
|
||||
elif not self.CanEdit():
|
||||
pass
|
||||
|
@@ -6,5 +6,5 @@ __author__ = "Patrick K. O'Brien <pobrien@orbtech.com>"
|
||||
__cvsid__ = "$Id$"
|
||||
__version__ = "$Revision$"[11:-2]
|
||||
|
||||
VERSION = '0.7'
|
||||
VERSION = '0.7.1'
|
||||
|
Reference in New Issue
Block a user