Beispiel #1
0
 def run(self, edit):
     blocks = [block_at(self.view, p) for p in list_cursors(self.view)]
     set_selection(self.view, blocks)
Beispiel #2
0
 def run(self, edit):
     for pos in list_cursors(self.view):
         word1 = word_at(self.view, pos)
         word2 = word_b(self.view, word1.begin())
         swap_regions(self.view, edit, word2, word1)
Beispiel #3
0
 def run(self, edit):
     # We go from right to left to correctly handle overlapping regions
     for pos in reversed(list_cursors(self.view)):
         word1 = word_at(self.view, pos)
         word2 = word_f(self.view, pos)
         swap_regions(self.view, edit, word1, word2)
 def run(self, edit):
    blocks = [block_at(self.view, p) for p in list_cursors(self.view)]
    set_selection(self.view, blocks)
 def run(self, edit):
     for pos in list_cursors(self.view):
         word1 = word_at(self.view, pos)
         word2 = word_b(self.view, word1.begin())
         swap_regions(self.view, edit, word2, word1)
 def run(self, edit):
     # We go from right to left to correctly handle overlapping regions
     for pos in reversed(list_cursors(self.view)):
         word1 = word_at(self.view, pos)
         word2 = word_f(self.view, pos)
         swap_regions(self.view, edit, word1, word2)