Eclipse shortcut keys I remember a colleague who just worked and told me that, no matter how the code is typed, the shortcut keys must be used 6 common shortcut keys in Eclipse

Eclipse shortcut keys I remember a colleague who just worked and told me that, no matter how the code is typed, the shortcut keys must be used 6 common shortcut keys in Eclipse

I remember a colleague at work told me this, no matter how the code is typed, the shortcut key must be 6

Copy from the Internet, under the commonly used tags.

Transfer from https://www.cnblogs.com/mq0036/p/4995390.html

Eclipse commonly used shortcut keys

1 The most important shortcut keys

Code Assistant: Ctrl+Space (Alt+/for Simplified Chinese operating system) Quick fix: Ctrl+1 Word completion: Alt+/Open external Java document: Shift+F2 Display search dialog: Ctrl+H Quick Outline: Ctrl+O to open Resource: Ctrl+Shift+R Open type: Ctrl+Shift+T Display reconstruction menu: Alt+Shift+T

Previous/Next cursor position: Alt+Left/Right Previous/Next member (member object or member function): Ctrl+Shift+Up/Down Select closed element: Alt+Shift+Up/Down/Left/Right Delete line: Ctrl+D Insert a line on the current line: Ctrl+Shift+Enter Insert a line under the current line: Shift+Enter Move the selected line up and down: Alt+Up/Down

Organization import: Ctrl+Shift+O

2 Positioning 2.1 Positioning within a line End of line/beginning of a line: End/Home Previous/next word: Ctrl+Right/Left 2.2 Positioning within a file to jump to a line: Ctrl+L Scroll up and down: Ctrl+Up/Down Previous/Next Member (member object or member function): Ctrl+Shift+Up/Down Quick Outline: Ctrl+O  2.3 Cross-file positioning open statement: F3 Open resource: Ctrl+Shift+R Open type: Ctrl+Shift+T Search in workspace Declaration of the selected element: Ctrl+G Search for the selected text in the workspace: Ctrl+Alt+G Search for the reference of the selected element in the workspace: Ctrl+Shift+G Open the call hierarchy: Ctrl+Alt+H Very important Quick hierarchy : Ctrl+T Reverse: Ctrl+Z 2.4 Other Previous/next cursor position: Alt+Left/Right Previous edit position: Ctrl+Q 

3 Select the 3.1 line to select. Select to the end of the line/first: Shift+End/Home Select the previous/next word: Ctrl+Shift+Left/Right 3.2 Select the closed element in the file : Alt+Shift+Up Revert to the previous selection : Alt+Shift+Down Select the next/previous element: Alt+Shift+Right/Left 

4 Position/select/operation and delete the line at the same time : Ctrl+D delete the next/previous word: Ctrl+Delete/Backspace delete to the end of the line: Ctrl+Shift+Delete insert a line on the current line: Ctrl+Shift+Enter in the current line Insert a line below: Shift+Enter Move the selected line up and down: Alt+Up/Down Copy the selected line: Ctrl+Alt+Up/Down 

5 Save other code editing shortcut keys : Ctrl+S Save all: Ctrl+Shift+S The next item hit (after searching): Ctrl+. Note: Ctrl+/Add import: Ctrl+Shift+M Show shortcut help: Ctrl+Shift+L becomes upper/lower case: Ctrl+Shift+X/Y

6 Refactoring Display the refactoring menu: Alt+Shift+T Refactoring-change method signature: Alt+Shift+C Refactoring-move: Alt+Shift+V Refactoring-rename: Alt+Shift+R 

7 Switch between editor, view and perspective view Next editor: Ctrl+F6 Next view: Ctrl+F7 Next perspective: Ctrl+F8 Maximize the current view or editor: Ctrl+M Activate the editor: F12 

8 Debug F5: Step Into (debug) F6: Step over (debug) F7: Step return (debug) F8: Resume (debug) F11: debug the previous application (debug) 

9 Up/Down/Right/Left shortcut keys Ctrl the previous/next word: Ctrl+Right/Left scroll up and down: Ctrl+Up/Down Alt the position of the previous/next cursor: Alt+Left/Right move up and down to select Line: Alt+Up/Down Shift Select the previous/next character: Shift+Left/Right Select the previous/next line (starting from the current cursor position): Shift+Up/Down Ctrl+Shift Previous/Next member (Member object or member function): Ctrl+Shift+Up/Down Select the previous/next word: Ctrl+Shift+Left/Right Alt+Shift Select the closed element: Alt+Shift+Up Revert to the previous selection: Alt+ Shift+Down Select the next/previous element: Alt+Shift+Right/Left Copy the selected row: Ctrl+Alt+Up/Down Ctrl+Alt Copy the selected row: Ctrl+Alt+Up/Down 

10 F type shortcut key F2: Display prompt/rename F3: Open the declaration of the selected element F4: Open the type inheritance structure of the selected element F5: Refresh F5: Step Into (debug) F6: Step over (debug) F7: Step return ( debug) F8: Resume (debug) F11: debug the previous application (debug) F12: activate the editor

Source: http://www.cnblogs.com/ifaithu/archive/2013/02/19/2917263.html

================================================== ===============================

Eclipse shortcut keys

Especially when it is called in multiple places) Alt+Shift+F turns the local variable in the Class into a field variable (a more practical function) Alt+Shift+I merges the variable (it may be a bit wrong to say that Inline) Alt+Shift+V Move functions and variables (not very commonly used) Alt+Shift+Z Refactored regret medicine (Undo) Edit scope function shortcut keys Global search and replace Ctrl+F text editor search previous Ctrl+Shift+K text editor search A Ctrl+K Global Undo Ctrl+Z Global Copy Ctrl+C Global Restore Last Selection Alt+Shift+↓ Global Cut Ctrl+X Global Quick Fix Ctrl1+1 Global Content Assist Alt+/Global All Select Ctrl+A Global Delete Delete Global Contextual information Alt+? Alt+Shift+? Ctrl+Shift+Space Java editor displays tooltip description F2 Java editor selects package element Alt+Shift+↑ Java editor selects the previous element Alt+Shift+← Java editor selects the next element Alt+Shift+→ text Editor incremental search Ctrl+J Text editor incremental reverse search Ctrl+Shift+J Global paste Ctrl+V Global redo Ctrl+Y View scope function shortcut Global zoom in Ctrl+= Global zoom out Ctrl+- Window scope function shortcut Key to activate the editor globally F12 Global switch editor Ctrl+Shift+W Global previous editor Ctrl+Shift+F6 Global previous view Ctrl+Shift+F7 Global previous perspective Ctrl+Shift+F8 Global next editor Ctrl +F6 Global next view Ctrl+F7 Global next perspective Ctrl+F8 It is recommended to set it yourself. You can also use Ctrl+1 to automatically correct it. Run scope function shortcuts Global single-step return to F7 Global single-step skip F6 Global single-step jump into F5 Global single-step jump select Ctrl+F5 Global debugging Last start F11 Global continue F8 Global use filter to single-step Shift+ F5 Globally add/remove breakpoints Ctrl+Shift+B Global display Ctrl+D Global run Last start Ctrl+F11 Global run to line Ctrl+R Global execution Ctrl+U Refactor scope function shortcut keys Global undo Refactor Alt+ Shift+Z Global extraction method Alt+Shift+M Global extraction of local variables Alt+Shift+L Global inline Alt+Shift+I Global movement Alt+Shift+V Global rename Alt+Shift+R Global redo Alt+Shift+ Y

Source: http://www.blogjava.net/action/articles/17339.html

================================================== ===============================

eclipse shortcut keys and the use of skills Daquan

1. Open MyEclipse 6.0.1, then "window" → "Preferences" 2. Select "java", expand, "Editor", select "Content Assist". 3. Select "Content Assist", and then see the option "AutoActivation triggers for java" under "Auto-Activation" on the right and right. In fact, it refers to the symbol "." that triggers the code prompt. 4. For the option of "Auto Activation triggers for java", add abc after "." to facilitate the search and modification later. Then "apply" and click "OK". 5. Then, "File" → "Export", select "Perferences" in the pop-up window, and click "Next". 6. Select the export file path, export it to the desktop, enter "test" as the file name, and click "Save". 7. Find the file "test.epf" you just saved on the desktop, right-click and select "Open with Notepad". 8. You can see a lot of information about configuring MyEclipse 6.0.1. 9. Press the "ctrl + F" shortcut key, enter ".abc", and click "Find Next". 10. Find the configuration information of ".abc" as follows: 11. Change ".abc" to ".abcdefghijklmnopqrstuvwxyz(,", save and close "test.epf". 12. Go back to MyEclipse 6.0.1 interface, "File "→"Import", select "Perferences" in the pop-up window, click "Next", select the "test.epf" file that has just been modified, click "Open", and click "Finish". This step and the above The export steps are similar. 13. Finally, of course, code testing. Create a new project and create a new class. Enter switch, foreach, etc. in the code to test. You will immediately find that there is a prompt, and no matter which letter is typed, it will be There are a lot of related tips, very smooth and convenient. Summary: The option "Auto Activation triggers for java" refers to the option that triggers the code prompt. Change the "." to ".abcdefghijklmnopqrstuvwxyz(," to mean 26 letters and ., (these symbols trigger the code prompt Function. By the way, modify the class name, interface name, etc. to be highlighted in different colors, you can configure it in "java"→"enditor"→"syntac", expand "java"→"classes" on the right, and check " "Enable" option, just choose the color you like. Of course, there are other related color configurations. I won’t talk about the specifics. In fact, there are many things that can be configured in the "Preferences" item, which makes MyEclipse optimized. It is necessary for each person to configure according to their personal preferences.

Eclipse commonly used shortcut keys

The editing function of Eclipse is very powerful. Mastering the Eclipse shortcut key function can greatly improve development efficiency. There are some shortcut keys related to editing in Eclipse. 1. [ALT+/] This shortcut key is a good helper for users to edit, and can provide users with content assistance. Don't worry about memorizing the names of methods and properties. When you fail to memorize the names of classes, methods and properties, please experience it more [ ALT+/] shortcut keys bring the benefits. 2. [Ctrl+O] Display the outline of the methods and properties in the class, which can quickly locate the methods and properties of the class, which is very useful when looking for bugs. 3. [Ctrl+/] Quickly add comments, you can quickly add or uncomment the line where the cursor is located or the selected line, you may always need to comment or uncomment something when debugging, now it’s fine, no need for each line Make repeated notes. 4. [Ctrl+D] Delete the current line, which is also one of the author's favorites. There is no need to press the delete key so many times to delete a line. 5. [Ctrl+M] The window is maximized and restored. When users operate in the window, they will always feel that the current window is small (especially when writing code). Now it's fine, try the [Ctrl+M] shortcut. Viewing and locating shortcut keys In the program, it is very difficult to quickly locate the location of the code and quickly find the location of the bug. Eclipse provides a powerful search function. You can use the following shortcut keys to help you complete the search and location work. 1. [Ctrl+K], [Ctrl++Shift+K] Quickly find the selected content down and up, no longer need to click the find dialog box with the mouse. 2. [Ctrl+Shift+T] Find the Java class files that can be found in the Workspace build path. Don't worry about not finding the class, and you can use wildcards such as "*" and "?". 3. [Ctrl+Shift+R] corresponds to [Ctrl+Shift+T], find all files (including Java files) in the workspace (Workspace), you can also use wildcards. 4. [Ctrl+Shift+G] Find references to classes, methods and attributes. This is a very useful shortcut key. For example, if you want to modify the code that references a certain method, you can quickly locate all references to this method by pressing the shortcut key [Ctrl+Shift+G]. 5. [Ctrl+Shift+O] Quickly generate import. After copying a program from the Internet, I don’t know how to import the called class. Try the [Ctrl+Shift+O] shortcut, and you will be pleasantly surprised. 6. [Ctrl+Shift+F] Formatting code, writing standardized code is a compulsory course for every programmer. When you see a certain piece of code that is extremely unpleasant, press [Ctrl+Shift+F] to make a shortcut after selecting it. The key can format this code, if the code is not selected, the current file (Java file) will be formatted by default. 7. [ALT+Shift+W] Find the path in the project where the current file is located, you can quickly locate the location of the browser view, if you want to find the package where a file is located, this shortcut key is very useful (especially in larger projects) in). 8. [Ctrl+L] Navigate to a certain line of the current editor, which is also valid for non-Java files. 9. [Alt+←], [Alt+→] Backward history and forward history are very useful when tracking code. Users may find several related places, but they may not remember clearly. You can use these two shortcuts Key locates the order of search. 10. [F3] Quickly locate a certain class, method and attribute at the cursor position. 11. [F4] Display the inheritance relationship of the class, and open the class inheritance view. 【F3】Quickly locate a certain class, method and attribute at the cursor position. 11. [F4] Display the inheritance relationship of the class, and open the class inheritance view. 【F3】Quickly locate a certain class, method and attribute at the cursor position. 11. [F4] Display the inheritance relationship of the class, and open the class inheritance view.

Debug shortcuts

There are some shortcut keys related to running and debugging in Eclipse. 1. [Ctrl+Shift+B]: Set a breakpoint or cancel the set breakpoint in the current line. 2. [F11]: Debug the last executed program. 3. [Ctrl+F11]: Run the last executed program. 4. [F5]: Trace to the method, when the program executes to a method, you can press the [F5] key to trace to the method. 5. 【F6】: Single-step execution of the program. 6. [F7]: After executing the method, return to the next statement that called the method. 7. [F8]: Continue to execute until the next breakpoint or the end of the program.

Common editor shortcuts

Usually text editors provide some editing-related shortcut keys, and you can also use these shortcut keys for text editing in Eclipse. 1. [Ctrl+C]: Copy. 2. [Ctrl+X]: Cut. 3. [Ctrl+V]: Paste. 4. [Ctrl+S]: Save the file. 5. [Ctrl+Z]: Cancel. 6. [Ctrl+Y]: Repeat. 7. [Ctrl+F]: Search.

Other shortcut keys

There are many shortcut keys in Eclipse, which cannot be listed one by one. Users can find out how to use them through the help document. In addition, there are several commonly used shortcut keys as follows. 1. [Ctrl+F6]: Switch to the next editor. 2. [Ctrl+Shift+F6]: Switch to the previous editor. 3. [Ctrl+F7]: Switch to the next view. 4. [Ctrl+Shift+F7]: Switch to the previous view. 5. [Ctrl+F8]: Switch to the next perspective view. 6. [Ctrl+Shift+F8]: Switch to the previous perspective.

There are many shortcut keys in Eclipse. You can find the use of all shortcut keys through the help document, but it is impossible and unnecessary to master the use of all shortcut keys. If you spend some time familiarizing yourself with the shortcut keys listed in this section, you will definitely Do more with less 1. edit->content Assist-> add Alt+/code association 2. Window -> Next Editor -> add Ctrl+Tab to switch windows 3. Run/Debug Toggle Line Breakpoint -> add Ctrl+` Add and delete breakpoints during debugging 4. Source-> Surround with try/catch Block -> Ctrl+Shift+v add try catch box 5. Source -> Generate Getters and Setters -> Ctrl+Shift+. add get set method--------- --Useful shortcut keys----------- Alt+/Code Assistant completes the insertion of some codes (but generally conflicts with the input method, you can modify the hot key of the input method, or you can use Alt+/temporarily Replace) Ctrl+1: When the cursor is placed on a variable, press Ctrl+1 to provide a quick reconstruction solution. Select several lines and press Ctrl+1 to put this code into for, while, if, do or try blocks. Double-click the left bracket (parenthesis, bracket, brace), and everything inside the bracket will be selected. Alt+Enter displays the properties of the currently selected resource (project, or file or file)-----------Ctrl series----------- Ctrl+K: put the cursor on the variable Up, press Ctrl+K to find the next same variable Ctrl+Shift+K: The search direction is opposite to Ctrl+K Ctrl+E to quickly display the drop-down list of the current Editor (if the current page is not displayed, it will be shown in bold) Ctrl+Shift+E displays the manager that manages all the currently opened Views (you can choose to close, (Activate and other operations) Ctrl+Q to locate the last edited place Ctrl+L to locate in a line (for those with more than 100 programs, there is a good news) Ctrl+M to maximize the current Edit or View (press again to reverse) Ctrl+/Comment the current line, then press to uncomment Ctrl+T to quickly display the inheritance structure of the current class Ctrl+Shift-T: Open type. If you are not deliberately working hard, forget to open it through the source tree. Ctrl+O: Open a small window similar to the outline view in the code Ctrl+Mouse stay: You can display the source code of the class and method Ctrl+H: Open the search window Ctrl+/(keyboard) Collapse all codes in the current class Ctrl+× (keyboard ) Expand all codes in the current class-----------Ctrl+Shift series----------- Ctrl+Shift+F format the current code Ctrl+Shift+X The selected text all taste lowercase Ctrl+Shift+Y Change the currently selected text all lowercase Ctrl+Shift+O: Quickly import import Ctrl+Shift+R: Open the resource open Resource ---------- -F shortcut key series----------- F3: Open the file that declares the reference F4: Open the type hierarchy F5: Single step into F6: Single step skip F7: Single step out F8: Continue , If there is no breakpoint behind, the program will run to completion-----------line editing use----------- Ctrl+D: delete the current line Ctrl+Alt+↓ copy the current line Go to the next line (copy and increase) Ctrl+Alt+↑ Copy the current line to the previous line (copy and increase) Alt+↓ The interactive position of the current line and the next line (particularly useful, you can save the first cut and then paste) Alt+↑ the current line and The interactive position of the upper line (same as above) Shift+Enter inserts a blank line in the next line of the current line (the mouse can be at any position of the current line at this time,

Source: http://jingyan.baidu.com/article/2a1383285ed0d5074a134ff0.html

================================================== ===============================

Summary of the most commonly used Eclipse shortcut keys

Read the table of contents

This article is a summary of some of the most practical, complete, and time-saving Eclipse shortcut keys. These shortcut keys can help you complete any operation in your work. Welcome reference.

1. ctrl+shift+r: open resource

This may be the most time-saving of all shortcut key combinations. This set of shortcut keys allows you to open any file in your workspace, and you only need to press the first few letters of the file name or mask name, such as applic*.xml. The fly in the ointment is that this set of shortcut keys is not available in all views.

back to the top

2. ctrl+o: fast outline

If you want to view the methods of the current class or a specific method, but don't want to pull up and down the code, and don't want to use the search function, just use ctrl+o. It can list all methods and attributes in the current class. You only need to enter the name of the method you want to query, and click enter to jump directly to where you want to go.

back to the top

3. ctrl+e: quick conversion editor

This set of shortcut keys will help you navigate between open editors. Use ctrl+page down or ctrl+page up to browse the front and back tabs, but when many files are open, ctrl+e will be more efficient.

back to the top

4. ctrl+2, L: Assign values ​​to local variables

In the development process, I often write a method first, such as Calendar.getInstance(), and then assign the calculation result of the method to a local variable through the ctrl+2 shortcut key. This saves me the time to enter class names, variable names, and import declarations. The effect of Ctrl+F is similar, but the effect is to assign the calculation result of the method to the domain in the class.

back to the top

5. alt+shift+r: rename

Renaming properties and methods was a cumbersome task a few years ago, requiring a lot of search and replacement, so that the code became fragmented. Today's Java IDE provides source code processing functions, as does Eclipse. Now, the renaming of variables and methods is very easy, and you will be used to renaming them every time a better alternative name appears. To use this function, move the mouse to the attribute name or method name, press alt+shift+r, enter the new name and click Enter. That's it. If you are renaming an attribute in the class, you can click alt+shift+r twice, which will call out the source code processing dialog box, which can realize the automatic renaming of the get and set methods.

back to the top

6. alt+shift+l and alt+shift+m: extract local variables and methods

Source code processing also includes the function of extracting variables and methods from large blocks of code. For example, to create a constant from a string, just select the text and press alt+shift+l. If the same string appears elsewhere in the same category, it will be automatically replaced. Method extraction is also a very convenient function. Breaking large methods into smaller, well-defined methods will greatly reduce complexity and improve the testability of the code.

back to the top

7. shift+enter and ctrl+shift+enter

Shift+enter creates a blank line below the current line, regardless of whether the cursor is at the end of the line. Ctrl+shift+enter inserts a blank line before the current line.

back to the top

8. Alt+arrow keys

This is also a magic weapon to save time. This combination moves the content of the current line up or down. In the try/catch section, this shortcut is especially useful.

back to the top

9. ctrl+m

Everyone knows that large display screens can improve work efficiency. Ctrl+m is the shortcut key for maximizing the editor window.

back to the top

10. ctrl+. and ctrl+1: the next error and quick modification

ctrl+. Move the cursor to the next error or warning in the current file. I usually use this set of shortcut keys together with ctrl+1 to modify the suggested shortcut keys. The modification suggestions of the new version of Eclipse are very good and can help you solve many problems, such as missing parameters in methods, throw/catch exceptions, unexecuted methods, and so on.

More shortcut key combinations can be viewed in Eclipse by pressing ctrl+shift+L.

Let's take a look at some of my favorite hotkey combinations according to the frequency of use. (Note: The following content has passed the test in Eclipse3.02 and the first version)

1.  Control-Shift-T: Open type. If you are not deliberately working hard, forget to open it through the source tree. It is easy to open the implementation class of the interface with eclipse. Press ctrl+t to list the implementation class list of the interface

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 allow the files you open to be displayed in the hierarchical structure of the navigator, which makes it easier to organize information. If this affects speed, turn it off.

3.  F3: Open declaration. Or, use the Declaration Tab (in Java view mode, select Windows -> Show View -> Declaration). When you select a method in the code and press this button, it will display the entire method in the declaration box.

4.  Alt-left arrow: Go back in the Navigation History.Just like the back button of a web browser, it is especially useful after using F3 to jump. (Used to return to the original compiled place)

5.  Alt-right arrow: Move forward in the navigation history.

6.  Control-Q: Go back to the last edited place. This shortcut is also used when you jump in the code. Especially when you drill too deep and forget what you were doing in the first place.

7.  Control-Shift-G: Search for references in the workspace. This is the prerequisite for refactoring. For methods, the function of this hotkey is exactly the opposite of F3. It allows you to find all the callers of a method up in the method stack. A related function is to turn on the "marking" function (occurrence marking). Select Windows->Preferences->Java-> Editor-> Mark Occurrences and check the option. At this time, when you click on an element, all the places where the element exists in the code will be highlighted. Personally, I only use "Mark Local Variables" (Mark Local Variables). Note: Too many highlighting will slow down Eclipse.

8.  Control-Shift-F: CodeàJavaàPreferencesà to reformat the code according to the code style setting. Our team has a unified code format, and we put it on our wiki. To do this, we open Eclipse, select Window Style, and then set Code Formatter, Code Style and Organize Imports. Use the Export function to generate configuration files. We put these configuration files on the wiki, and then everyone in the team imported into their own Eclipse.

9.  Control-O: Quick outline. With this shortcut key, you can quickly jump to a method or attribute, and you only need to enter the first few letters of the name.

10.  Control-/: Comment or uncomment a line. The same applies to multiple rows.

11.  Control-Alt-down arrow: Copy the highlighted line or lines.

12.  Alt-down arrow: Move one or more rows down. Alt-up arrow will move up.

Other hot keys are available in the menu. You can see a list of all shortcut keys by pressing Control-Shift-L (from version 3.1). Press Control-Shift-L twice to display the Keys Preferences dialog, where you can set the hotkey yourself. I welcome you to post your Eclipse tips in the Talkback section.

back to the top

Other Eclipse tricks

I summarized a few related tips:

Lock the command line window : In the command line view (Window ->Show View ->Other ->Basic ->Console), try using the scroll lock button to lock the console output without scrolling.

Use the Ant view : In my Java or Debug mode, I like to show the Ant view so that I can run Ant tasks quickly. This view can be found through Window Ant. Put the Ant view in the corner of the screen and add the build.xml file through the "Add à Other à Show View à Buildfiles" button. In version 3.1, even the Ant debugging scripting language is supported.

Automatically traverse a collection : for + Control-Space: If you don’t know yet, then you should remember that Control-Space is an auto-completion function. In Eclipse, you can also auto-complete the structure. Within an array or collection, try typing "for" and then pressing the Control-Space key. Eclipse will ask you which collection you want to traverse and then automatically complete the loop code.

Use hierarchical layout : The default layout (flat style) in the Package Explorer view confuses me. It displays the full name of the package in the navigation tree. I prefer the package and file system view of my source code, which is called Hierarchical Layout in Eclipse. To switch to this mode, click the down button in the package browse view, select Layout, and then select Hierarchial.

Show multiple files at once : You can browse multiple files at once. Drag the edit window that is not in the active state to the scroll bar at the bottom or side of the active window to open the edit window. This is the best way I can describe the trick.

Open two Eclipses at the same time : To merge changes from one CVS branch to another, I like to do so by opening two working directories (Workspace) with different Eclipses at the same time. This way I can see all the changes by comparing the latest version on CVS (right-click on the project, and select Compare Lastest from HEAD) and merge each change into another CVS branch. The easiest way to start multiple Eclipses is to use Eclipseàwith Launcher.

Implementors plug-in : Install a plug-in that can jump to the implementation of an interface. If you are a dependency injection fan, or are working based on well-written interfaces, then you need a plugin like this to speed up code navigation. You can find this plugin at SourceForge.

back to the top

Ctrl+Alt+H

If you want to know which methods of a class are called by other classes, please select the method name and press "Ctrl+Alt+H",

Eclipse will show which methods this method is called, and finally generate a call relationship tree.

1. Ctrl+Left Button

This is often used by most people to view the definitions of variables, methods, and classes

2. Ctrl+O

View the outline of a class, listing its methods and member variables. Tip: Press Ctrl+O again to list the inherited methods and variables of this class.

Mnemonic: "O"—>"Outline"—>"Outline"

3. Ctrl+T

View the inheritance tree of a class, it is top-down, press Ctrl+T again, it will change to the bottom-up display structure.

Tip: Select a method name and press Ctrl+T to view the parent class, subclass, and interface of the method with the same name.

Mnemonic: "T"——->"Tree" —–>"Hierarchical Tree"

4.Alt+left and right arrow keys

We often encounter the situation of Ctrl+Left button, tracking layer by layer when looking at the code, and then getting lost in the code. At this time, you only need to press "Alt+Left arrow key" to return to the last reading position. Similarly, press " "Alt+Right Arrow" will advance to the reading position you just went back to, just like the browser’s forward and back buttons.

Import package: Ctrl+Shift+O

edit

Scope function shortcut keys

Find and replace globally Ctrl+F

The text editor finds the previous Ctrl+Shift+K

The text editor finds the next Ctrl+K

Global undo Ctrl+Z

Global Copy Ctrl+C

Globally restore the previous selection Alt+Shift+↓

Global cut Ctrl+X

Global quick fix Ctrl1+1

Global content assist Alt+/

Select all globally Ctrl+A

Delete globally

Global context information Alt+?

Alt+Shift+?

Ctrl+Shift+Space

Java editor displays tooltip description F2

Java editor select package element Alt+Shift+↑

Java editor selects the previous element Alt+Shift+←

Java editor selects the next element Alt+Shift+→

Text editor incremental search Ctrl+J

Incremental reverse search in text editor Ctrl+Shift+J

Global paste Ctrl+V

Global redo Ctrl+Y

View

Scope function shortcut keys

Global zoom Ctrl+=

Global shrink Ctrl+-

window

Scope function shortcut keys

Global activation editor F12

Global switch editor Ctrl+Shift+W

Global last editor Ctrl+Shift+F6

Global previous view Ctrl+Shift+F7

Global previous perspective Ctrl+Shift+F8

Global next editor Ctrl+F6

Global next view Ctrl+F7

Global next perspective Ctrl+F8

The text editor displays the ruler context menu Ctrl+W

Global display view menu Ctrl+F10

Global display system menu Alt+-

navigation

Scope function shortcut keys

Java editor open structure Ctrl+F3

Global open type Ctrl+Shift+T

Open type hierarchy F4 globally

Global open statement F3

Open external javadoc globally Shift+F2

Open resources globally Ctrl+Shift+R

Global Back History Alt+←

Global forward history Alt+→

Global last Ctrl+,

Global next Ctrl+.

Java editor shows outline Ctrl+O

Open globally in the hierarchy, type Ctrl+Shift+H

Go to matching brackets globally Ctrl+Shift+P

Go to the previous editing position globally Ctrl+Q

Java editor to go to the previous member Ctrl+Shift+↑

Java editor go to the next member Ctrl+Shift+↓

Text editor go to line Ctrl+L

search for

Scope function shortcut keys

Globally appear in the file Ctrl+Shift+U

Open the search dialog box Ctrl+H globally

Statement in the global workspace Ctrl+G

References in the global workspace Ctrl+Shift+G

Text Editor

Scope function shortcut keys

Text editor rewrite switch Insert

Scroll up the text editor Ctrl+↑

Scroll down the text editor Ctrl+↓

file

Scope function shortcut keys

Global save Ctrl+X Ctrl+S

Global print Ctrl+P

Global close Ctrl+F4

Save all globally Ctrl+Shift+S

Close all globally Ctrl+Shift+F4

Global attributes Alt+Enter

Global New Ctrl+N

project

Scope function shortcut keys

Build all globally Ctrl+B

Source code

Scope function shortcut keys

Java editor format Ctrl+Shift+F

Java editor uncomment Ctrl+/

Java editor comment Ctrl+/

Java editor adds a single import Ctrl+Shift+M

Java editor organizes multiple imports Ctrl+Shift+O

The Java editor uses try/catch blocks to surround the unset, which is too common, so it is listed here, and it is recommended to set it yourself. You can also use Ctrl+1 to automatically correct it.

Commissioning

Scope function shortcut keys

Global single step return to F7

Global single step skip F6

Step into F5 globally

Global step into the selection Ctrl+F5

Global debugging last started F11

Continue to F8 globally

Globally use the filter to execute Shift+F5 in a single step

Globally add/remove breakpoints Ctrl+Shift+B

Global display Ctrl+D

Global run last start Ctrl+F11

Global run to line Ctrl+R

Execute Ctrl+U globally

Refactor

Scope function shortcut keys

Global undo reconstruction Alt+Shift+Z

Global extraction method Alt+Shift+M

Extract local variables globally Alt+Shift+L

Global inline Alt+Shift+I

Global move Alt+Shift+V

Global rename Alt+Shift+R

Global redo Alt+Shift+Y

(1) Ctrl+M to switch the size of the window

(2) Ctrl+Q jumps to the last edit

(3) F2 When the mouse is placed on a mark and Tooltip appears, press F2 to move the mouse away and the Tooltip will also display Show Tooltip Description.

F3 jumps to the place of declaration or definition.

F5 single step debugging into the function.

F6 single-step debugging does not enter the function. If Kingsoft PowerWord 2006 is installed, the shortcut key of "Fetch Word Switch" should be changed to something else.

F7 is returned from the function to the calling point.

F8 has been executed until the next breakpoint.

(4) Ctrl+Pg~ is to switch code and icon window for XML file

(5) Ctrl+Alt+I to see the relevant information of the variables in the Java file

(6) Ctrl+PgUp opens the "Show List" drop-down box for the code window, in which the recently opened files are displayed

(7) Ctrl+/is this//~ comment in the code window. Ctrl+Shift+/is this kind of/*~*/comment in the code window, and <!–~–> in the JSP file window.

(8) Alt+Shift+O (or click the Toggle Mark Occurrences button in the toolbar) When you click a mark, the mark in other places on this page will be highlighted in yellow, and a white square will appear on the right border of the window. Clicking on this box will jump to this mark.

(9) Right-click the left border of the window, which is the place where the breakpoint is added, and select Show Line Numbers to add line numbers.

(10) Ctrl+I Format Active Elements. Ctrl+Shift+F Format Document.

(11) Ctrl+S saves the current file. Ctrl+Shift+S saves all unsaved files.

(12) Ctrl+Shift+M (first put the cursor on the class name of the package to be imported) The function is to add the Import statement. The effect of Ctrl+Shift+O is that the missing Import statement is added, and the redundant Import statement is deleted.

(13) Ctrl+Space prompts that the content to be typed is Content Assist. At this time, the shortcut keys of Chinese (Simplified) IME-Ime/Nonlme Toggle (used to switch between English and other text) in the input method should be changed to other. Ctrl+Shift+Space prompt information is Context Information.

(14) Double-click the left border of the window to add a breakpoint.

(15) Ctrl+D deletes the current line.

Eclipse shortcut keys

Ctrl+1 quick fix (the most classic shortcut key, needless to say)

Ctrl+D: delete the current line

Ctrl+Alt+↓ Copy the current line to the next line (copy increase)

Ctrl+Alt+↑ Copy the current line to the previous line (copy increase)

Alt+↓ The interactive position of the current line and the next line (especially practical, you can save the cutting and then pasting)

Alt+↑ The interactive position of the current line and the upper line (same as above)

Alt+← the previous edited page

Alt+→ the next edited page (of course for the above one)

Alt+Enter displays the properties of the currently selected resource (project, or file or file)

Shift+Enter insert a blank line in the next line of the current line (the mouse can be at any position of the current line at this time, not necessarily the last)

Shift+Ctrl+Enter insert a blank line in the current line (the principle is the same as the previous one)

Ctrl+Q Position to the last edited place

Ctrl+L is positioned in a certain line (for those with more than 100 programs, there is a gospel)

Ctrl+M Maximize the current Edit or View (press again to vice versa)

Ctrl+/comment the current line, press again to cancel the comment

Ctrl+O quickly display OutLine

Ctrl+T quickly display the inheritance structure of the current class

Ctrl+W close the current Editor

Ctrl+K Quickly locate to the next one with reference to the selected Word

Ctrl+E quickly display the drop-down list of the current Editor (if the current page is not displayed, it is indicated in bold)

Ctrl+/(small keyboard) collapse all codes in the current class

Ctrl+× (keyboard) Expand all codes in the current class

Ctrl+Space code assistant completes the insertion of some codes (but generally conflicts with the input method, you can modify the hotkey of the input method, or you can temporarily use Alt+/instead)

Ctrl+Shift+E displays the manager that manages all the currently opened Views (you can choose to close, activate, etc.)

Ctrl+J Forward incremental search (after pressing Ctrl+J, the editor for each letter you enter provides quick matching to locate a certain word, if not, it will display in the stutes line that it is not found, check one It is particularly useful when it comes to words. This feature Idea had two years ago)

Ctrl+Shift+J reverse incremental search (same as the previous one, but search from back to front)

Ctrl+Shift+F4 Close all open Editors

Ctrl+Shift+X change the flavor of the currently selected text to lowercase

Ctrl+Shift+Y changes the currently selected text to all lowercase

Ctrl+Shift+F format the current code

Ctrl+Shift+P Position to the matching character (such as ()) (When positioning from the front to the back, the cursor should be in the matching character, from the back to the front, and vice versa)

The following shortcut keys are commonly used in refactoring, and I like to organize them frequently (Note: Generally, the shortcut keys for reconstruction start with Alt+Shift)

Alt+Shift+R Rename (it is my favorite one, especially the Rename of variables and classes, which can save a lot of labor than manual methods)

Alt+Shift+M extraction method (this is one of the most commonly used methods in refactoring, especially useful for a lot of mud code)

Alt+Shift+C modify the function structure (more practical, there are N functions called this method, modify it once)

Alt+Shift+L extract local variables (you can directly extract some magic numbers and strings into one variable, especially when called in multiple places)

Alt+Shift+F turns the local variable in Class into a field variable (a more practical function)

Alt+Shift+I merge variables (it may be a bit wrong to say that Inline)

Alt+Shift+V Move functions and variables (not very commonly used)

Alt+Shift+Z refactoring regret medicine (Undo) 

Source: http://www.open-open.com/lib/view/open1426774886742.html

Reference: https://cloud.tencent.com/developer/article/1335896 Eclipse shortcut keys. I remember a colleague who just worked and told me that, no matter how the code is typed, the shortcut keys must be used 6 common shortcuts in Eclipse Key-Cloud + Community-Tencent Cloud