Eclipse shortcut Key Usage Summary _java

Source: Internet
Author: User

The most common practical
1, Alt +/
As a content-assisted hint, it is estimated that no one will use it, but it can also be used to do some quick input, such as the SYSTEM.OUT.PRINTLN () for beginners, as long as you enter the SYSO and then press the key combination to automatically complete and position the cursor in parentheses. In fact, some commonly used structures can be entered using this method, such as for, try ... catch and so on, as long as it is defined in the preference–java–editor–template can be used.

2, Ctrl + Shift + O
Quickly and automatically import the required packages.

3, Ctrl + D
Deletes the current line or selects the row.

4, Ctrl +/
Using a single-line comment annotation/uncomment the current line or select the row, the debugger inevitably has to temporarily close some code, so its usage is very high. Functions similar to the shortcut keys and CTRL + SIFT +/and CTRL + SIFT + \ This pair, the selected section with a multiline comment or cancel.

Practical and not frequently used edit shortcut keys
1, Ctrl + Shift + UP ARROW/down ARROW
Copy the current line or select the line to the previous line/next line of methods.

2, ALT + UP ARROW/down ARROW
Swap the current line with the previous line/next line and combine the previous set of shortcuts and you'll find it handy to copy and paste the code.

3, SHIFT + Enter/ctrl + SHIFT + Enter
Inserts a blank row on the next line/top line of the current line and moves the cursor to the newly inserted row.

4, Ctrl + M
Maximize/Cancel maximize the current window, when the code is relatively long to use it is very convenient, no need to switch the mouse double-click so troublesome.

5, Alt + Shift + R
Modifying the variable or method name of the current cursor and automatically modifying all references is useful.

Do not use to locate shortcut keys
1, Ctrl + K/ctrl + Shift + K
Quickly find the selection back/forward in the current document, although Ctrl + F is OK, but this is more convenient.

2, ALT + LEFT ARROW/ALT + RIGHT ARROW
Back/forward to the last code position, this group is usually when you look at the code, continuous jump several classes or methods, you want to go back to see, use it very convenient.

3, Ctrl + Shift + T
Open the type and open the JDK class to see the source code.

4, Ctrl + Shift + G
You can see where the class, method, or property of the cursor is referenced, which is currently very small, because the code structure is simple, but it will be useful in the future.

Less-frequently-skilled shortcuts
1, Alt + Shift + S: Open the refactoring right-click menu, generate Getter/setter method, construct method, ToString () method
2 , Alt + Shift + Z: Put the selected code in a while, for, try...catch, etc structure
3, Ctrl + F6/ctrl + Shift + F6/ctrl + e switch to the previous/next editor or list the editor display card
4, F3 quickly locate the cursor position class, method, Properties
5, F4 display the current class inheritance relationship, and open the Class inheritance view (or similar Ctrl + T quickly show the current class inheritance)
6, Ctrl + Q navigate to the last edited position

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.