Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

In Sublime Text 2, I'm able to transpose two words by placing the cursor on the space between them and pressing Ctrl+T. However, in Sublime Text 3 (build 3059 on OS X Mavericks), I get the default OS X behavior of just transposing two characters. This is the case even if I choose Edit > Text > Transpose through the status bar.

Is this a bug, or by design? Is there a way to bring back the old behavior?

share|improve this question
I'm quite sure this is by design. How would Sublime know that you want to transpose words? ⌃T has always transposed adjacent characters in Emacs-style keybindings. – slhck Jan 24 '14 at 22:03
@slhck If I open Sublime Text 2 on the same machine, enter the text "foo bar", put my cursor on either side of that space character and press ⌃T, I get "bar foo". It's a useful feature for everyday coding tasks like swapping function arguments around. – Trevor Burnham Jan 24 '14 at 22:59
@TrevorBurnham - I'm trying to figure out how to reinstate the ST2 behavior in ST3, but I'm running into snags. Basically, there were changes to Packages/Default/ between 2 and 3, but even when I revert the script back to the ST2 version it's still not working (at least on XP). I'm guessing there must have been some change in the ST3 API that's causing problems, but I'm having trouble tracking it down. It might be easier in the long run to just write a separate plugin that only transposes words. – MattDMo Jan 25 '14 at 2:27
As a temporary workaround, if you select the two words by multi-selecting them, Ctrl-T will transpose them in ST3. – MattDMo Jan 25 '14 at 2:28

The TransposeCharacter plugin offers more intelligent transposing, see readme for details, and maybe even this screencast. It goes really well with the MarkAndMove plugin.

While this doesn't answer your question, I hope it can render it obsolete :)

share|improve this answer
I gave it a try, but that plugin doesn't appear to solve my problem: transposing two words without selecting them first. – Trevor Burnham Jul 1 '14 at 20:50

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .