Keyboard shortcut to "untab" (move a block of code to the left) in eclipse / aptana?

Viewed 278726

Well, hopefully the question is self-explanatory.

It's so easy to select a block of code and tab out, but how about the reverse?

Currently, I just search & replace for whitespace at the beginning of the line. Anything faster?

10 Answers

In Visual Studio and most other half decent IDEs you can simply do SHIFT+TAB. It does the opposite of just TAB.

I would think and hope that the IDEs you mention support this as well.

Shift-tab does that in Flex Builder (Based on Eclipse) - SO it hopefully should work in regular eclipse :)

Don't know if anyone is still looking here, but you can do this by going to Window menu > Preferences, then open the General list, choose keys. Scroll down the list of keys until you see "Shift Left". Click that. Below that you'll see some boxes, one of which lets you bind a key. It won't accept Shift-Tab, so I bound it to Shift-`. Apply-and-close and you're all set.

You can also change the shortcut. Use the Command+K Command+S shortcuts to open the Keyboard Shortcut menu and search for the "tab" then find the "outdent" on the list.

Related