Macro is a rule or pattern, or grammar replacement. So how to set macros in sublime? Below, the sublime usage tutorial column will explain how to set macros in sublimetext3. I hope it will be helpful to friends in need!
sublime text 3How to set macros?
Definition of macro
Generally speaking, a macro is a rule or pattern, or syntax replacement, used to describe a specific input ( How to convert (usually a string) into the corresponding output (usually a string) according to predefined rules. This replacement is performed during precompilation and is called macro expansion
The role of macro
So much nonsense above, in fact, it is to use "one key" instead of "multiple keys", which is the same as encapsulation
How to implement macros in Sublime_text_3
Example: After pressing =, realize the equal sign with spaces on both sides
1. Start recording
Click Tools->Record Macro to start recording the macro. (You can also use the shortcut key ctrl Q )
2. Record
Find a file and write "space=space" //In fact, it is the rule or pattern to be implemented
3.End recording
Tools->Stop Recoding Macro (actually the button to start recording, so you can also use ctrl Q)
4. Save Macro
Operation: Tools->Save Macro
Personal habits are saved in your sublime/Data/User/Macoro (create if not)/your_filename.sublime-macro
Here we assume that we save your sublime/Data/User/Macoro/equal .sublime-macro
5. Add shortcut keys to the recorded macro
Preferences->Key bindings
Type the following content
{ "keys":["="],"command":"run_macro_file","args":{"file":"Packages/user/Macoro/equal.sublime-macro"} }
The above is the detailed content of How to set macros in sublime text 3?. For more information, please follow other related articles on the PHP Chinese website!

SublimeText is suitable for developers who pursue speed and simplicity, while VSCode is suitable for users who need strong scalability and integration capabilities. 1.SublimeText is known for its lightweight and fast response, with GotoAnything and multi-select powerful. 2. VSCode is known for its scalability and IDE functions, with built-in Git and debugging tools, and IntelliSense improves development efficiency.

SublimeText's plug-ins and packages can be installed and managed through PackageControl to improve programming efficiency. 1. Install plug-ins such as BracketHighlighter to simplify code reading by highlighting bracket matching. 2. Use SublimeLinter to configure pylint to implement real-time code checking. 3. Use SideBarEnhancements to customize the sidebar function to optimize file management.

SublimeTextisfreeduringanunlimitedtrial,buta$99licenseisrecommendedforregularuse.1)Thetrialallowsfullfeatureaccesswithouttimelimits.2)Alicenseoffersperpetualuse,futureupdates,andremovespurchasereminders,enhancingproductivityandsupportingdevelopers.

SublimeText can greatly improve work efficiency. 1) Multiple selection and multicursor functions allow editing of multiple positions at the same time, 2) Command panel provides fast function access, 3) Macros and fragments can automate common operations, 4) Optimized configuration and shortcut key use can improve performance and efficiency.

SublimeText offers a free trial, but ultimately requires a paid purchase for a permanent authorization. 1) During the free trial period, users can experience its functions, but they will receive a purchase prompt. 2) After purchase, users can use it permanently, no subscription fee, and access more plug-ins and themes.

ThemaindifferencesbetweenthepaidandunpaidversionsofSublimeTextaretheremovalofstatusbarremindersandoccasionalpop-uppromptsinthepaidversion.1)Unregisteredversion:fullyfunctionalwithallcorefeatureslikesyntaxhighlighting,codecompletion,andcommandpalette,

SublimeText is worth buying. 1) Its simple interface and powerful functions, such as multi-line editing and GotoAnything, improve development efficiency. 2) Rich plug-in ecosystem, such as Anaconda, enhances the development experience. 3) Although the price is $70, its performance and fluency are great value for professional developers.

SublimeText is loved by developers for its powerful code completion and syntax highlighting capabilities. 1) Code completion can automatically prompt function names, variable names, etc. to improve programming efficiency. 2) Syntax highlighting distinguishes code elements through different colors to improve readability and error detection speed.


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

SecLists
SecLists is the ultimate security tester's companion. It is a collection of various types of lists that are frequently used during security assessments, all in one place. SecLists helps make security testing more efficient and productive by conveniently providing all the lists a security tester might need. List types include usernames, passwords, URLs, fuzzing payloads, sensitive data patterns, web shells, and more. The tester can simply pull this repository onto a new test machine and he will have access to every type of list he needs.

MantisBT
Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

ZendStudio 13.5.1 Mac
Powerful PHP integrated development environment

SublimeText3 Chinese version
Chinese version, very easy to use
