Overview of shortcuts for Android Studio and for android
After switching from eclipse to android studio, the shortcut keys used for coding are different, which is difficult to adapt to at the moment. Of course, you can set the shortcut key template to be the same as that of eclipse, however, I personally disagree, because there are still some shortcut keys in Android Studio that are not available in eclipse, so I am still familiar with the shortcut keys in Android Studio through projects.
For more information, see http://wuyudong.com/2016/10/06/2822.html.
Here are some common shortcut keys for Android Studio:
Shortcut Key |
Function |
Alt + Enter |
Import packages, classes, domains, type conversion, etc. |
Ctrl + Alt + L |
Format code |
Ctrl + Alt + O |
Optimized imported packages and Classes |
Alt + Insert |
Insert Code (such as the get/set Method) |
Ctrl + E or Alt + Shift + C |
View recently changed code |
Ctrl + F |
Search Text |
Ctrl + Shift + Space |
Automatic completion code |
Ctrl + Shift + U |
Switch between uppercase and lowercase characters |
Ctrl + Space |
Code prompt |
Ctrl + P |
Method parameter prompt |
Ctrl + X |
Cut a single row |
Ctrl + D |
Copy selected |
Ctrl +/or Ctrl + Shift +/ |
Add Comment |
Ctrl + J |
Automatic Code |
Ctrl + E |
Recently opened document |
Ctrl + Q |
Show annotation document |
Ctrl + Shift + Up/Down |
Mobile Code |
Ctrl + W |
Rotate code |
Ctrl + [/] |
Jump to the beginning and end of brackets |
Ctrl + Alt + T |
Add the code to a try/catch statement, for example. |
Ctrl + O |
Select a method that can be rewritten |
If you have any shortcut keys not listed in the text, please leave a message to add ^_^.