IntelliJ disable automatic line splitting

For a specific file use the Soft wraps option under the View/Active Editor menu item.

Enable/Disable Soft Wraps on a file


You can edit the Code Style Settings at:

File > Settings > Editor > Code Style > Java > Wrapping and Braces

There are different options, for your problem set Right margin column to 300 or something like this or just uncheck Ensure right margin it not exceeded. You can also experiment with them.

Press Ctrl + Alt + L to format afterwards. Unfortunately once IntelliJ has wrapped the lines I am not sure if it unwraps them on its own, maybe you have to fix this.

Please consider when changing line length etc. that sometimes line length is needed due to Code Conventions, Checkstyle and those... :)

Update Screenshot: Margin


Go to Intellij Settings and follow the instructions on these two pictures:

Click Here