IntelliJ IDEA empty constructor/method code style -


how tweak inllij idea 14 code style java, make keep closing brace of empty constructor/method right after opening one.

e. g. :

class {     private a() {}     public void b() {} } 

go settings/code style/java/wrapping , braces , select these options:

  • keep when reformatting
    • simple blocks in 1 line
    • simple methods in 1 line
    • simple classes in 1 line

that keep code untouched while reformatting code:

if(true) {} public void foo() {} public class bar {} 

i tested on intellij 13.1.5, work same way on 14 too.


Comments

Popular posts from this blog

c++ - QTextObjectInterface with Qml TextEdit (QQuickTextEdit) -

javascript - angular ng-required radio button not toggling required off in firefox 33, OK in chrome -

xcode - Swift Playground - Files are not readable -