Introduction to common functions of sublime text
The following is sublime introductionUsing the tutorial column to introduce the common functions of sublime text. I hope it will be helpful to friends in need!
Common functions of sublime text
● Autocomplete
Autocomplete shortcut The key is Tab. If you enter cl and press tab in an html file, it will be automatically completed as class=""; after adding zencoding, it will be even more powerful. I will talk about it later
● Multi-column editing
Hold down ctrl and click the mouse, multiple flashing cursors will appear. At this time, you can modify multiple places at the same time, or hold down the middle mouse button and drag.
● Code comment function
ctrl /, ctrl shift / are line comments and block comments respectively. Click again to remove the comment. ST2 can automatically identify it as html , css or js files, give different types of comments.
● Line operation
ctrl alt ↑, ctrl alt ↓Swap two lines up or down, ctrl enter, insert a blank line after the cursor, ctrl d selects similar, You can refer to the shortcut key list below.
● Shortcut keys
Ctrl L Select the entire line (press and hold - continue to select the next line)
Ctrl KK Delete from the cursor to the end of the line
Ctrl K Backspace Delete from the cursor to the beginning of the line
Ctrl J Merge lines (when multiple lines to be merged have been selected)
Ctrl KU Change to uppercase
Ctrl KL Change to lower case
Ctrl D Select a string (press and hold - continue to select the next same string)
Ctrl M Move the cursor to the beginning or end of the bracket
Ctrl / Comment the entire line (if the content is selected, the same effect as "Ctrl Shift /")
Ctrl Shift c converts to utf8
Ctrl R Searches for function labels in the specified file
Ctrl G Jump to the specified line
Ctrl KT Collapse attributes
Ctrl K0 Expand all
Ctrl U Soft undo
Ctrl T word swap
Tab indent auto-complete
Shift Tab remove indent
Ctrl F2 set bookmark.
F2 next bookmark
Shift F2 Previous bookmark
shift Right-click column selection
Alt F3 Select text and press the shortcut key to select all the same text at once for editing simultaneously
Alt . Close the current tag
F6 Detect syntax errors
F9 Sort rows (press a-z)
F11 Full screen mode
Ctrl Enter insert after cursor Line
Ctrl Shift Enter Insert line before cursor
Ctrl Shift [Collapse code
Ctrl Shift] Expand code
Ctrl Shift ↑ Swap with the previous line
Ctrl Shift ↓ Swap with the next line
Ctrl Shift A Select the parent label pair at the cursor position
Ctrl Shift D Copy the entire line where the cursor is and insert it before the line
ctrl shift F Search within a folder. The difference from ordinary editors is that sublime allows you to add multiple folders for search
Ctrl Shift K Delete the entire line
Ctrl Shift L Select multiple lines with the mouse (press the shortcut key), and you can edit these lines at the same time
Ctrl Shift M Select the content within the brackets (press and hold - continue to select the parent bracket)
Ctrl Shift P Open the command panel
Ctrl Shift/Comment the selected content
Ctrl PageDown, Ctrl PageUp files are switched in the order they are opened
Ctrl The left mouse button can select what you want to edit at the same time Multiple text
Shift Right-click (or use the middle mouse button) to select vertical multiple lines with the mouse
Shift Tab Remove indent
Alt Shift 1~9 (Non-keyboard) A small window showing equal numbers on the screen
The above is the detailed content of Introduction to common functions of sublime text. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics











To open HTML files you need to use a browser such as Google Chrome or Mozilla Firefox. To open an HTML file using a browser, follow these steps: 1. Open your browser. 2. Drag and drop the HTML file into the browser window, or click the File menu and select Open.

IDLE and Jupyter Notebook are recommended for beginners, and PyCharm, Visual Studio Code and Sublime Text are recommended for intermediate/advanced students. Cloud IDEs Google Colab and Binder provide interactive Python environments. Other recommendations include Anaconda Navigator, Spyder, and Wing IDE. Selection criteria include skill level, project size and personal preference.

HTML can be used to open local files as follows: Create a .html file and import the jQuery library. Create an input field that allows the user to select a file. Listen to the file selection event and use a FileReader() object to read the file contents. Display the read file contents on the web page.

Here are the steps to use copied code in Python: Copy and paste the code into a text editor. Create a Python file. Run the code from the command line. Understand what the code is for and how it works. Modify the code as needed and rerun it.

HTML files can be opened using a browser (such as Chrome, Firefox, Edge, Safari, Opera): find the HTML file (.html or .htm extension); right-click/long-press on the file; select "Open"; select the file you want to use browser.

Steps to create a .py file in Python: Open a text editor (such as Notepad, TextMate, or Sublime Text). Create a new file and enter the Python code, paying attention to indentation and syntax. When saving the file, use a .py extension (for example, my_script.py).

To sum up, the following HTML editors are highly praised: Visual Studio Code: Cross-platform, feature-rich, free and open source. Sublime Text: High performance, highly customizable, paid software. Atom: cross-platform, scalable, open source and free. Brackets: dedicated for front-end development, intuitive interface, open source and free. Notepad++: lightweight, fast, powerful, open source and free. When choosing an HTML editor, consider factors such as platform compatibility, functionality, extensibility, price, and user-friendliness.

Create an HTML document: Use a text editor to enter the HTML structure and save it as an .html file. Open an HTML document: Double-click the file or use the File > Open option in your browser. Practical case: Create a new HTML file, add a title, style sheet and content, and save it as an .html file.
