Sublime Forum

Character classes other than "word_separators"

#1

I’m using ST3 for the first time for serious work programming in C++ and python for from 8 to ungodly numbers of hours per day for my job. And some fairly minor things are driving me crazy about it, and I’m trying to figure out ways to address them. The main thing currently is that the “word_separators” setting seems to control both:

  1. What gets selected when I double click some text
  2. How the cursor moves when jumping through text by word (like super+left/right)

For example, when I double click on a function name, I don’t want the () chars to be included. To make that happen I have to put them in “word_separators”. But then when I jump around by words, the cursor stops on the () chars.

Is there a way to have this work the way I prefer? If not directly, can this be done via plugins in a hopefully straightforward non-hacky way?

Oh, I should add that I REALLY LIKE ST! It has a wonderfully smooth feel when using it, with a sense of power about it that I really look forward to fully exploiting.

0 Likes

#2

I programmed my own custom replacement of Ctrl+left/right. You can modify the plugin to achieve the exact kind of cursor jumping behavior you might need.
move_to_contigboundary - Move to Contiguous Boundary

Also check out:
Expand Selection to Whitespace

0 Likes

#3

Thank you, I now have cursor word movement just how I like it! :smiley:

0 Likes