Eclipse 快捷键总结

来源:互联网 发布:淘宝网商城男装外套 编辑:程序博客网 时间:2024/06/05 06:37

原文地址:http://www.shortcutworld.com/en/win/Eclipse.html

常用的快捷键用红色字体高亮显示

Eclipse Shortcuts  

Uploaded by berndupdated on 6/14/2013 by csscouter
Platform: Windows/ English

pdf PDF   printer_friendly Print minimize Hide all  maximize Show all

Table of Contents:

  1. Manage Files and Projects
  2. Editor Window
  3. Navigate in Editor
  4. Select Text
  5. Edit Text
  6. Search and Replace
  7. Indentions and Comments
  8. Editing Source Code
  9. Code Information
  10. Refactoring
  11. Run and Debug
  12. The Rest
minus1. Manage Files and ProjectsCtrl+NCreate new project using the WizardCtrl+Alt+nCreate new project, file, class, etc.Alt+f, then .Open project, file, etc.Ctrl+Shift+rOpen Ressource (file, folder or project)Alt+EnterShow and access file propertiesCtrl+sSave current fileCtrl+Shift+sSave all filesCtrl+wClose current fileCtrl+Shift+wClose all filesF5Refresh content of selected element with local file system

▲ up

minus2. Editor WindowFocus/ cursor must be in Editor Window for these to work.F12Jump to Editor WindowCtrl+Page Down/Ctrl+Page UpSwitch to next editor / switch to previous editorCtrl+mMaximize or un-maximize current Editor Window (also works for other Windows)Ctrl+eShow list of open Editors. Use arrow keys and enter to switchCtrl+F6/Ctrl+Shift+F6Show list of open Editors. Similar to ctrl+e but switches immediately upon release of ctrlAlt+Arrow Left/Alt+Arrow RightGo to previous / go to next Editor WindowAlt+-Open Editor Window Option menuCtrl+F10Show view menu (features available on left vertical bar: breakpoints, bookmarks, line numbers, …)Ctrl+F10, then nShow or hide line numbersCtrl+Shift+qShow or hide the diff column on the left (indicates changes since last save)

▲ up

minus3. Navigate in EditorHome/EndJump to beginning / jump to end of indention. Press home twice to jump to beginning of lineCtrl+Home/EndJump to beginning / jump to end of sourceCtrl+Arrow Right/Arrow LeftJump one word to the left / one word to the rightCtrl+Shift+Arrow Down/Arrow UpJump to previous / jump to next methodCtrl+lJump to Line Number. To hide/show line numbers, press ctrl+F10 and select 'Show Line Numbers'Ctrl+qJump to last location editedCtrl+./Ctrl+,Jump to next / jump to previous compiler syntax warning or errorCtrl+Shift+pWith a bracket selected: jump to the matching closing or opening bracketCtrl+[+]/Ctrl+- on numeric keyboardCollapse / Expand current method or classCtrl+[/]/Ctrl+* on numeric keyboardCollapse / Expand all methods or classesCtrl+Arrow Down/Ctrl+Arrow UpScroll Editor without changing cursor position

▲ up

minus4. Select TextShift+Arrow Right/Arrow LeftExpand selection by one character to the left / to the rightCtrl+Shift+Arrow Right/Arrow LeftExpand selection to next / previous wordShift+Arrow Down/Arrow UpExpand selection by one line down / one line upShift+End/HomeExpand selection to end / to beginning of lineCtrl+aSelect allAlt+Shift+Arrow UpExpand selection to current element (e.g. current one-line expression or content within brackets)Alt+Shift+Arrow Left/Arrow RightExpand selection to next / previous elementAlt+Shift+Arrow DownReduce previously expanded selection by one step

▲ up

minus5. Edit TextCtrl+c/Ctrl+x/Ctrl+vCut, copy and pasteCtrl+zUndo last actionCtrl+yRedo last (undone) actionCtrl+dDelete LineAlt+Arrow Up/Arrow DownMove current line or selection up or downCtrl+Alt+Arrow Up / Ctrl+Alt+Arrow Down /Duplicate current line or selection up or downCtrl+DeleteDelete next wordCtrl+BackspaceDelete previous wordShift+EnterEnter line below current lineShift+Ctrl+EnterEnter line above current lineInsertSwitch between insert and overwrite modeShift+Ctrl+yChange selection to all lower caseShift+Ctrl+xChange selection to all upper case

▲ up

minus6. Search and ReplaceCtrl+fOpen find and replace dialogCtrl+k/Ctrl+Shift+kFind previous / find next occurrence of search term (close find window first)Ctrl+hSearch Workspace (Java Search, Task Search, and File Search)Ctrl+j/Ctrl+Shift+jIncremental search forward / backwards. Type search term after pressing ctrl+j, there is now search windowCtrl + Shift + oOpen a resource search dialog to find any class

▲ up

minus7. Indentions and CommentsTab/Shift+TabIncrease / decrease indent of selected textCtrl+iCorrect indention of selected text or of current lineCtrl+shift+fAutoformat all code in Editor using code formatterCtrl+/Comment / uncomment line or selection ( adds '//' )Ctrl+Shift+/Add Block Comment around selection ( adds '/... */' )Ctrl+Shift+Remove Block CommentAlt+Shift+jAdd Element Comment ( adds '/** ... */')

▲ up

minus8. Editing Source CodeCtrl+SpaceOpens Content Assist (e.g. show available methods or field names)Ctrl+1Open Quick Fix and Quick AssistAlt+/Propose word completion (after typing at least one letter). Repeatedly press alt+/ until reaching correct nameCtrl+Shift+InsertDeactivate or activate Smart Insert Mode (automatic indention, automatic brackets, etc.)

▲ up

minus9. Code InformationCtrl+oShow code outline / structureF2Open class, method, or variable information (tooltip text)F3Open Declaration: Jump to Declaration of selected class, method, or parameterF4Open Type Hierarchy window for selected itemCtrl+tShow / open Quick Type Hierarchy for selected itemCtrl+Shift+tOpen Type in HierarchyCtrl+Alt+hOpen Call HierarchyCtrl+uFind occurrences of expression in current fileCtrl+move over methodOpen Declaration or Implementation

▲ up

minus10. RefactoringAlt+Shift+rRename selected element and all referencesAlt+Shift+vMove selected element to other class or file (With complete method or class selected)Ctrl+Shift+cChange method signature (with method name selected)Alt+Shift+mExtract selection to methodAlt+Shift+lExtract local variable: Create and assigns a variable from a selected expressionAlt+Shift+iInline selected local variables, methods, or constants if possible (replaces variable with its declarations/ assignment and puts it directly into the statements)

▲ up

minus11. Run and DebugCtrl+F11Save and launch application (run)F11DebugF5Step Into functionF6Next step (line by line)F7Step outF8Skip to next Breakpoint

▲ up

minus12. The RestCtrl+F7/Ctrl+Shift+F7Switch forward / backward between views (panels). Useful for switching back and forth between Package Explorer and Editor.Ctrl+F8/Ctrl+Shift+F8Switch forward / backward between perspectivesCtrl+pPrintF1Open Eclipse Help
原创粉丝点击