11.1+ Minor annoyance: changing text cursor placement behavior

Unless I'm imagining things, a minor change seems to have made it's way into the new 11.1 release that is causing me quite a bit of heart-ache.

Let's say you have the following code in your editor:

void someMethod()
{
   System.out.println("FOO");
}

If you place your cursor before the open curly brace and hit the delete button, prior to the latest release (11.0), IDEA would smartly move the open curly brace to the previous line and keep your cursor before the brace, like so:

void someMethod()|{
     System.out.println("FOO");
}

Now as of (11.1+), IDEA places the text cursor after the open brace, like so:

void someMethod(){|
     System.out.println("FOO");
}

Granted, this isn't a show stopper, but I've grown accustomed (read: commited to muscle memory) to typing "backspace -> space" when changing the brace style to match my teams' (at least when I'm working on common classes that I haven't established the style for).

Now I've got to learn "backspace -> left arrow -> space", which is kind of annoying.

Is there some setting I'm missing, or is this a minor bug that can perhaps eventually be fixed?

Thanks!

3 comments
Comment actions Permalink

This is a bug which has already been fixed. The workaround is to disable the CoffeeScript plugin.

0
Comment actions Permalink

Let me mention two things that might be useful for the use case you have.

1) Have you tried using CTRL+SHIFT+J instead? CTRL+SHIFT+J joins two lines smartly. So in this case, it will handle the spacing and brace placement. In the case of more "complex" things, it handles other syntax changes. For example:

String s;
s = "foo";


becomes

String s = "foo"; 


in one key stroke.

2) You can quickly change code styles via CTRL+`  (i.e. CTRL=Backquote), then select 2 Switch Code Style Scheme You could configre a second code scheme to match what your coworkers use. After editing the document (or while editing it) use the alternate code scheme to format it. THen quickly switch back to your preferred scheme.

0
Comment actions Permalink

Thanks to you both; Dmitry for the quick response and Mark for the very helpful tips that were, until this point, unknown to me.

0

Please sign in to leave a comment.