Home > Article > Development Tools > How to automatically typeset in notepad++
astyle is an open source tool. It can easily format the program code into the style you want without manual modification.
Originally, as higher organisms, we should prioritize doing some smart things instead of spending time on things that machines can do perfectly.
In notepad: Run or F5. (Recommended learning: notepad )
Select the directory where astyle.exe is located in the input box.
Add some parameters to the path of the input box command you just ran:
E:\AStyle_2.06_windows\AStyle\bin\AStyle.exe --style=ansi -S -N -n "$(FULL_CURRENT_PATH)" "$(FULL_CURRENT_PATH)"<br>
Note: --style=ansi -S -N -n sets the formatting parameters for astyle. You can modify it according to your own situation, and then click Save.
Give it a name, for example, astyle. You can also customize the shortcut keys according to your own needs! If you want to modify it later, you can modify it yourself in the shortcut key management
Finally, "Settings"->"Preferences"->"Others ", just tick the automatic update, and you're done.
Okay, let's test it. We deliberately messed up the code layout
Run the shortcut you just set
After automatic typesetting
The above is the detailed content of How to automatically typeset in notepad++. For more information, please follow other related articles on the PHP Chinese website!