Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android Studio - jump back and forth between matching braces using a single key sequence

I had to move from Eclipse to Android Studio for Android development. Many features are better, several are worse. In particular I miss the jump between matching braces (opening -> closing brace and v.v.) by means of a single key sequence.

I managed to find that CTRL ] takes you from the opening brace to the closing one, CTRL [ takes you from closing to opening brace. If the wrong [ or ] symbol is used when you ara already at an opening or closing brace, then the editor jumps to the next brace of that type.

Is there any key sequence which jumps between matching braces, like Eclipse does?

like image 560
NickT Avatar asked Jul 11 '16 14:07

NickT


3 Answers

I think you want

  • Ctrl+}

  • Ctrl+{

these move to the open and close brackets.

You want a single combination to do both?

Use Ctrl + shift + M

Reference

like image 89
AndroidMechanic - Viral Patel Avatar answered Nov 09 '22 00:11

AndroidMechanic - Viral Patel


If this helps anyone using Android Studio on a Mac OS X machine, to jump back and forth between matching braces or parentheses, use

control + m

or possibly

control + shift + m

like image 36
Gravitoid Avatar answered Nov 09 '22 01:11

Gravitoid


I am using Android Studio 4.2.1 and now it seems like need to use cmd + shift + m to move to matching bracket. Also, this one conflicts with one of the MacOS short cut and can be modified to ctrl + shift + m

like image 36
rysv Avatar answered Nov 09 '22 00:11

rysv