Eva*_*sch 9 java ide intellij-idea
所以我是Intellij Idea IDE的新手,到目前为止我非常喜欢它.在获取代码样式设置方面遇到一些麻烦,正是我喜欢它们的Java.我喜欢不使用大括号作为一行if语句,但我喜欢他们在两行:
if(true)
dosomething();
Run Code Online (Sandbox Code Playgroud)
现在,当我在Idea中运行代码格式时,它会向上移动到一行:
if(true) dosomething();
Run Code Online (Sandbox Code Playgroud)
我觉得很难读,但我似乎无法正确设置.任何人都可以帮助我,并告诉我我需要设置什么来保持两行,但仍然没有大括号?感觉很蠢,无法找到它.谢谢!
取消选择Simple blocks in one line设置 - > CodeStyle - > WrappingandBraces,然后它应该工作.它对我有用.
