Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disable Intellij IDEA code reformatting when closing brace is typed in

Intellij IDEA seems to like to reformat the code block inside braces once the closing brace is entered. For example, if I have a block of code that I now want to wrap in a try/catch block, once I type in the closing brace of the try block, the entire try block automatically gets reformatted. I have searched in settings but was not able to find anything that would turn this off. Any ideas?

like image 881
Mensur Avatar asked Dec 08 '25 00:12

Mensur


1 Answers

Yes.

File --> Settings --> Editor --> General --> Smart Keys

Then uncheck the option "Reformat block on typing '}'"

Apply --> OK

like image 181
Avihoo Mamka Avatar answered Dec 10 '25 13:12

Avihoo Mamka



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!