Sublime Text is called TextMate under Windows. According to its official website, the characteristics of Sublime Text are as follows: an efficient and interference-free interface, multiple selection, macros, code snippets and other editing functions, as well as the distinctive Minimap .
Sublime Text is a code editor. It is also an advanced text editor for HTML and prose. Beautiful user interface and extraordinary features such as mini-maps, multiple selections, Python plugins, code snippets, and more. Fully customizable key bindings, menus and toolbars.
Sublime Text main functions:
Spell check, bookmarks, full Python API, Goto function, instant project switching, multiple selections, multiple windows, etc. SublimeText2 supports but is not limited to C, C++, C#, CSS, D, Erlang, HTML, Groovy, Haskell, HTML, Syntax highlighting for mainstream programming languages such as Java, JavaScript, LaTeX, Lisp, Lua, Markdown, Matlab, OCaml, Perl, PHP, Python, R, Ruby, SQL, TCL, Textile and XML. ST2 has an excellent code auto-completion function (automatic completion of brackets, braces and other matching symbols; automatic completion of words that have already appeared; automatic completion of function names), which is very smart; in addition, ST2 also has the function of code snippets (Snippet). You can save frequently used code snippets and call them whenever you need them. Of course, syntax highlighting, code folding, line number display, custom skins, color schemes, etc. are already standard features that a modern editor should have!
It supports syntax highlighting, code completion, code snippets, code folding, line number display, custom skins, color schemes and other functions that other code editors have, while ensuring its fast speed. ! It also has its own unique features, such as code maps, multiple interface layouts, and full-screen do not disturb mode.
Package Control
The Expansion Pack Manager You Can’t Miss
In addition to its countless useful functions and features, Sublime Text 2 can also install and use various extensions/skins/color schemes to enhance itself. The Package Control introduced now can be regarded as an ST2 extension manager. Using it, you can download, install, and delete various plug-ins, skins, etc. of Sublime Text 2 in a very magical, very simple and convenient way. Trust me , if you want to use ST2 better, you must not live without it! However, ST2 itself does not come with this tool. We need to install it ourselves. The method is very simple:
1. Find the Data > Installed Packages folder in the SublimeText2 directory (please create a new one manually if it does not exist)
2. Download the Package Control.sublime-package file here
3. Put the downloaded files into Installed Packages
4. Restart Sublime Text
If Package Control has been installed successfully, then Ctrl+Shift+P calls the command panel, and we will find some commands starting with "Package Control:". The ones we commonly use are several Install Packages (installation extensions), List Packages (list packages) Remove all extensions), Remove Package (remove extensions), Upgrade Package (upgrade extensions). But if you really can’t figure it out according to the above method, you can try pressing Ctrl+~ (the keys to the left of the number 1) on the keyboard to bring up the console, then copy the following code into it and press Enter. It will automatically create a new folder for you and download it. file, the final effect is the same as the above method:
import urllib2,os; pf='Package Control.sublime-package';
ipp=sublime.installed_packages_path();
os.makedirs(ipp) if not os.path.exists(ipp) else None;
urllib2.install_opener(urllib2.build_opener(urllib2.ProxyHandler()));
open(os.path.join(ipp,pf),'wb').write(urllib2.urlopen('http://sublime.wbond.net/'+pf.replace(' ','%20')) .read());
print 'Please restart Sublime Text to finish installation'
After successfully installing Package Control, a series of commands starting with its name will appear in the command panel.
Enter "Package Control: Install Package" in the command panel and all the extensions that can be installed will be listed (need to be connected to the network, as shown below). As you can see from the list, 4GL and AAAPackageDev are the names of the plug-ins. Select them to download them. Installed. As you can see from this list, the various extensions of ST2 are already very rich! In addition, you can also see the Web version of the extension list and detailed instructions here (the data of these two lists should be synchronized. As of the deadline of 2012-7-8, 482 expansion packages have been collected here)
shortcut key:
Ctrl+L selects the entire row (hold - to continue selecting lower rows)
Ctrl+KK deletes from the cursor to the end of the line
Ctrl+Shift+K delete entire line
Ctrl+Shift+D Copy the entire line where the cursor is and insert it before the line
Ctrl+J Merge lines (when multiple lines to be merged have been selected)
Ctrl+KU changes to uppercase
Ctrl+KL Change to lowercase
Ctrl+D word selection (hold down - to continue selecting the next same string)
Ctrl+M moves the cursor to the beginning or end of the brackets
Ctrl+Shift+M Select the content within the brackets (hold - to continue selecting the parent brackets)
Ctrl+/ comments the entire line (if the content is selected, the effect is the same as "Ctrl+Shift+/")
Ctrl+Shift+/ annotate selected content
Ctrl+Space automatically completes (win conflicts with system shortcut keys and needs to be modified)
Ctrl+Z Undo
Ctrl+Y Undo
Ctrl+Shift+V paste and automatically indent (written by other brothers, the actual automatic indentation of win system is invalid)
Ctrl+M The cursor jumps to the corresponding bracket
Alt+. Close the current tab
Ctrl+Shift+A selects the parent tag pair at the cursor position
Ctrl+Shift+[ fold code
Ctrl+Shift+] expand code
Ctrl+KT collapse properties
Ctrl+K0 expand all
Ctrl+U soft undo
Ctrl+T word swap
Tab indent
Shift+Tab remove indent
Ctrl+Shift+UP swaps with up
Ctrl+Shift+DOWN swaps with down
Ctrl+K Backspace Delete from the cursor to the beginning of the line
Ctrl+Enter After inserting a line
Ctrl+Shift Enter insert before line
F9 row sort (by a-z)
Optimization instructions:
1. Modified based on the official version of Sublime Text 2
2. Set the font size to 11, Ctrl+middle mouse button for scrolling adjustment
3. Fixed the bug of an extra "<" in Html auto-completion
4. Added Theme-Nil theme with very comfortable color matching
5. Added automatic line wrapping setting option in user settings
6. Modify menu options and configuration files to make them more user-friendly
7. Various commonly used plug-ins have been integrated by default: (details are as follows)
(1).Alignment: Code alignment plug-in, shortcut key: Ctrl+Alt+A
(2).ConvertToUTF8: Supports GBK viewing and editing plug-ins
(3).Emmet: HTML/CSS code quick writing plug-in
(4).JsFormat: JS formatting plug-in, shortcut key: Ctrl+Alt+F
(5).KeymapManager: shortcut key management plug-in, shortcut key: Ctrl+Alt+K
(6).Package Control: Plug-in installation
(7).SideBarEnhancements: Sidebar plug-in
(8).Theme - Nil: SideBarEnhancements skin