In eclipse when I press the tab key, it takes the current line to the correct indentation instantly...even if that is 5 tab's in. So
public class TabTest {
public void func1() {
int a = 1;
|int b = 2;
The '|' pipe being where the cursor is, when I hit tab once it looks correct
public class TabTest {
public void func1() {
int a = 1;
|int b = 2;
In intellij I have to hit tab twice. Or here is another annoyance.
public class TabTest {
public void func1() {
int a = 1;|int b = 2;
In eclipse 'Enter' will result in
public class TabTest {
public void func1开发者_如何学C() {
int a = 1;
|int b = 2;
In Intellij that takes an enter, tab, tab.
Anyone know how to get what i had in eclipse into intellij?
From CrazyCoder comment, the solution seems to be :
- map the tab key on the "Auto-indent Lines" action
- unmap the tab key from the "Tab" and "Indent Selection" actions
Something is wrong with either your IDEA installation or the settings. Indentation works automatically on Enter, you don't have to hit Tab at all.
Try running with all the default settings after renaming IDEA config directory and see if you still can reproduce it. Specify your IDEA version and provide sample project with the steps to replicate the problem if the issue persists.
精彩评论