コード例 #1
0
ファイル: cursor.py プロジェクト: kelvin13/Knockout
 def expand_cursors_word(self):
     if len(self.i) == 2:
         a, b = expand_cursors_word(self._blocks[self.i[0]].content, self.i[1])
         self.i = (self.i[0], a)
         self.j = (self.i[0], b)
     else:
         self.j = (self.i[0] + 1,)
コード例 #2
0
 def expand_cursors_word(self):
     if len(self.i) == 2:
         a, b = expand_cursors_word(self._blocks[self.i[0]].content,
                                    self.i[1])
         self.i = (self.i[0], a)
         self.j = (self.i[0], b)
     else:
         self.j = (self.i[0] + 1, )
コード例 #3
0
 def dpress(self):
     self._i, self._j = expand_cursors_word(self._CHARS, self._i)
コード例 #4
0
 def dpress(self):
     if self._active:
         self._i, self._j = expand_cursors_word(self._LIST, self._i)
         self._j = min(self._j, len(self._LIST) - 1)