1. Control-shift-T: Open type ). If you are not interested in doing this, forget to open the source tree.
2. Control-shift-R: Open resources (not just to find java files ). Tip: Use the yellow two-way arrow button in the navigator view to associate your editing window with the navigator. This will display the opened files in the hierarchy of the navigator to facilitate the organization of information. If this affects the speed, turn it off.
3. F3: open declaration ).Alternatively, use the Declaration tab (in Java view mode, choose windows --> show View --> Declaration ). When you select a method in the Code and press this button, it will display the entire method in the statement box.
4. Alt-left arrow: Backward in navigation history. Just like the back button of the web browser, it is particularly useful after the F3 jump. (Used to return the original compilation location)
5. Alt-right arrow: Forward in navigation history.
6. Control-Q: Return to the Last edited place. This shortcut key is also used when you jump to the code. Especially when you drill too deep and forget what you did first.
7. Control-shift-G: Search for reference in workspace ). This is the premise of refactoring. For methods, this hot key works in the opposite way as F3. It allows you to locate all callers of a method in the method stack. One function related to this is to enable the "mark" function (occurrence marking ). Choose Windows> preferences> JAVA> editor> MARK occurrences and select the option. When you click an element, all the elements in the Code are highlighted. I personally only use Mark local variables ). Note: too many highlights will slow down eclipse.
8. Control-shift-F: Re-format the code according to the code style. Our team has a unified code format and we put it on our Wiki. To do this, open eclipse, select Window & #61664; preferences & #61664; Java & #61664; Code style, and set code formatter, code style, and organize imports. Use the export function to generate a configuration file. We put these configuration files on the Wiki, and then everyone in the team imported them to their own eclipse.
9. Control-o: Quick outline ). With this shortcut key, you can quickly jump to a method or attribute, just enter the first few letters of the name.
10. Control -/: Annotate or cancel a line. The same applies to multiple rows.
11. Control-alt-Down Arrow: Copy one or more highlighted rows.
12. Alt-Down Arrow: Move one or more rows down. Alt-up arrow moves up.
Other hotkeys are available in the menu. You can press control-shift-l (from version 3.1) to view the list of all shortcut keys. Press Control-shift-l twice to display the key dialog box (Keys preferences diences). You can set the key here. You are welcome to post your eclipse prompt in the Talkback section.