posted this on November 09, 2011 14:34
Keybindings / shortcuts:
note: The keybindings that are listed in this article can be used in de Cloud9 Editor.
This document contains the following:
- A list of keybindings and a short description
- A complete list of keybindings for Mac users and Windows users
Keybindings and short description:
We use keybindings to become more productive as a developer. During the process of improving the IDE we added more and more keybindings to easily make use of all the cool features supported by editor. The list below contains keybindings you might not have heard of yet and their descriptions.
Selected word highlight and navigation. If you have a word selected (e.g. a variable name), you will notice that other occurrences of that word are automatically highlighted. To jump between them, you can use Ctrl-K (Cmd-G on Mac) and Ctrl-Shift-K (Cmd-Shift-G on Mac) to jump between them.
Moving/copying lines. You can use Alt-Up (Option-Up on Mac) and Alt-Down (Option-Down on Mac) to move lines up and down. Add the Shift key to copy the line, or select multiple lines to move/copy them together. While you may think this is not super useful, you will likely find that when you get used to it, you'll use this feature all the time.
Indenting and outdenting blocks. Select a block of code and use Tab and Shift-Tab to indent or outdent the block of code.
Search within a file. Use Ctrl-F (Cmd-F on Mac) to search within the file -- a small search box will appear along the top-right. Press enter to search, and keep pressing it to jump to the next result.
Delete a line. The less code, the better. Deleting code is one of the most satisfying things to do. Ctrl-D (Cmd-D on Mac) makes it faster, my removing lines one at a time.
Reveal file. Having trouble finding your currently open file in the file tree? Happens to the best of us. Simply press Ctrl-Shift-L (Cmd-Shift-L on Mac) to reveal the current file in the file tree.
Tab switching. Want to quickly switch between two or more open tabs? Give Ctrl-Tab (Alt-Tab on Mac) a try. To switch to the tab to the left use Ctrl-[ (Cmd-[ on Mac), to switch to the tab to the right use Ctrl-] (Cmd-] on Mac).
Close a tab. Use Alt-W (Option-W on Mac) to quickly close the current tab.
Quickly open a file. Press Alt-Shift-R (Option-Shift-R on Mac) to open the open file dialog and search for any file within your project.
Search file contents. Want to search your entire project, or a certain directory? Select the directory in your file tree and press Alt-Shift-F (Option-Shift-F on Mac) to quickly to a full-text search of your files for a certain phrase.
Close any dialog. Just by pressing Esc, easy no?
Mouse trickery. If you are a mouse aficionado, here's a couple of clickery tricks:
Double click: select current word
Triple click: select current line
Quadruple click: select entire file
Bonus tip: Want to really get in the zone? Press Ctrl-E (Command-E on Mac) to enter Zen mode.
As we are still creating new features and improving the IDE the keybindings may change in time. If a keybinding is not working it might have been changed and we should update the page. We will update the page, if not please let us know!