QScintilla/Shell.py

branch
maintenance
changeset 5680
b93cb6353cc0
parent 5633
1a767ca5bbf3
parent 5631
d0beabfaad42
child 5730
6422afc7adc4
equal deleted inserted replaced
5655:884cd9c9ce05 5680:b93cb6353cc0
1511 while idx >= 0 and \ 1511 while idx >= 0 and \
1512 not self.history[idx].startswith(txt): 1512 not self.history[idx].startswith(txt):
1513 idx -= 1 1513 idx -= 1
1514 return idx 1514 return idx
1515 1515
1516 def focusNextPrevChild(self, next): 1516 def focusNextPrevChild(self, nextChild):
1517 """ 1517 """
1518 Public method to stop Tab moving to the next window. 1518 Public method to stop Tab moving to the next window.
1519 1519
1520 While the user is entering a multi-line command, the movement to 1520 While the user is entering a multi-line command, the movement to
1521 the next window by the Tab key being pressed is suppressed. 1521 the next window by the Tab key being pressed is suppressed.
1522 1522
1523 @param next next window 1523 @param nextChild next window
1524 @return flag indicating the movement 1524 @return flag indicating the movement
1525 """ 1525 """
1526 if next and self.inContinue: 1526 if nextChild and self.inContinue:
1527 return False 1527 return False
1528 1528
1529 return QsciScintillaCompat.focusNextPrevChild(self, next) 1529 return QsciScintillaCompat.focusNextPrevChild(self, nextChild)
1530 1530
1531 def contextMenuEvent(self, ev): 1531 def contextMenuEvent(self, ev):
1532 """ 1532 """
1533 Protected method to show our own context menu. 1533 Protected method to show our own context menu.
1534 1534
1619 if text != "": 1619 if text != "":
1620 txt = txt.replace(text, "") 1620 txt = txt.replace(text, "")
1621 self.__insertText(txt) 1621 self.__insertText(txt)
1622 self.completionText = "" 1622 self.completionText = ""
1623 1623
1624 def __completionListSelected(self, id, txt): 1624 def __completionListSelected(self, listId, txt):
1625 """ 1625 """
1626 Private slot to handle the selection from the completion list. 1626 Private slot to handle the selection from the completion list.
1627 1627
1628 @param id the ID of the user list (should be 1) (integer) 1628 @param listId the ID of the user list (should be 1) (integer)
1629 @param txt the selected text (string) 1629 @param txt the selected text (string)
1630 """ 1630 """
1631 if id == 1: 1631 if listId == 1:
1632 if self.completionText != "": 1632 if self.completionText != "":
1633 txt = txt.replace(self.completionText, "") 1633 txt = txt.replace(self.completionText, "")
1634 self.__insertText(txt) 1634 self.__insertText(txt)
1635 self.completionText = "" 1635 self.completionText = ""
1636 1636

eric ide

mercurial