Complete Paired Characters
IntelliJ IDEA can automatically add closing braces and other paired elements.
To enable adding closing braces:
- Open the Settings / Preferences dialog (Ctrl+Alt+S), click Editor, then General, and then Smart Keys.
- Select the Insert pair } check box in the Enter group. This enables adding closing braces when you press Enter.
- Configure automatic insertion of paired elements by selecting the following check boxes:
- Insert pair bracket
- Insert pair quote
- Auto-close tag on typing '</'
- Insert pair %> in JSP
- Auto-insert closing }} and %} in Django templates
- Click OK to apply changes.
The indentation level is defined in the Code Style settings.
Last modified: 24 July 2018