I\'m finally making the voyage back to IntelliJ via Eclipse. Currently my Eclipse is set up so that if I currently have a statement such as this (where ^ denotes where my c
For Windows or Linux users, Ctrl+Shift+Enter.
For macOS/OS X users, ⌘ Command+⇧ Shift+Enter.
That finishes the statement you're currently writing. Try it in a few different situations, like in if statements, for loops etc, and you'll see that it'll complete the line and open some curly braces for you if necessary.
if you want always have it just do this
You can add a keymap of your own. I added Ctrl+; to my Keymaps for the "Complete Current Statement" action. This saved me an extra key stroke and made it a little bit more intuitive.
Ctrl+Semicolon
OK
, and OK
to save and exit.You can opt to remove or keep the existing mapping. Should look something like this when you're done: