当前位置:网站首页>notepad++

notepad++

2022-07-05 08:58:00 Wanderer001

Reference resources  notepad++ - cloud + Community - Tencent cloud

Notepad++ What is it? ? Why recommend Notepad++? These questions are not the questions to be answered in this blog . But proficient notepad++ Use skills , It will undoubtedly greatly improve professional skills .

Catalog

One 、 install notepad + +

Two 、 Shortcut key

3、 ... and 、 Change the theme

Four 、 Set up tab key

5、 ... and 、 Word wrap

6、 ... and 、 Automatic completion

7、 ... and 、 establish 、 Save the file

8、 ... and 、 Edit two files at the same time

Nine 、 keep Notepad++ Code highlighting style to web pages or word in

Ten 、 Plug in installation

11、 ... and 、 Use notepad++ Solve practical problems .


One 、 install notepad + +

notepad++ The download 、 The installation is very easy. Next next next , All options can be installed by default . But there are a few things to note .
By the end of writing this blog ,notepad++ The latest version of is 7.5.4. It is divided into 32bit and 64bit Two kinds of .
stay 7.5 In the previous version ,32bit Version has plug-in management function ,64bit There is no plug-in management function in version .
stay 7.5 Later versions , No matter what 32bit still 64bit edition , There is no plug-in management function .
below , With the latest version of notepad++7.5.4 For example , Describes how to install notepad++.

1、 Double click Install Package , Bad English , Be sure to choose “ Simplified Chinese ”. If the choice is “English”, After installation, the interface style is English . You can set -> Preferences … -> Commonly used -> Interface language Set to simplified Chinese .
Step one
2. next step .
Step two
3. I accept .
Step three
4. After selecting the installation location , next step .
Step four
5. next step .
Step five
6. install .
Step six

Parameter interpretation :

    Don’t use %APPDATA%
    It is unchecked by default . The function is to allow the configuration file to be placed in Notepad++ Under the installation path of . thus , It can support the whole Notepad++ Put the root directory in U Plate , Ran around with . When the user is interested in Notepad++ There are many custom configurations , And changed a computer , You have to reconfigure Notepad++ when , It is recommended to check this option .

    Allow plugins to be loaded from %APPDATA%\notepad++\plugins
    It is unchecked by default . The function is to allow from %APPDATA%\notepad++\plugins The location of , Loading plug-ins , There are some security risks . Because there are some unsafe plug-ins , If you put it in plugins In the catalog , It will also automatically load , So it may lead to some security problems .

    Create Shortcut on Desktop
    It is unchecked by default . Create a... On the desktop Notepad++ Shortcut to . Check the box is not recommended , Because use Notepad++ It is usually selected from the right-click of the file “Edit with Notepad++”, Therefore, it is generally unnecessary to create shortcuts on the desktop .

7. Installation completed , start-up notepad++, adopt “ plug-in unit -> Plug-in management ” see .32bit There is really no plug-in management function .64bit Also verified. , Again, there is no .
Plug-in management

8. Download plug-ins .
because 32bit and 64bit Our plug-ins are not universal . So you need to download and notepad++ Version of the plug-in .
Download mode 1 :
github On 32&64bit Of PluginManager Download address
Download mode 2 :
csdn On 32bit Of PluginManager_v1.4.9_UNI .7z Download address
csdn On 64bit Of PluginManager_v1.4.9_x64.7z Download address

Download the corresponding version of PluginManager_v1.4.9.7z after , decompression , Copy plugins Under folder “PluginManager.dll” To notepad++ Install under directory plugins Under the folder . restart notepad++ that will do .

Here we are ,notepad++ Installation of is complete .

Two 、 Shortcut key

Click Settings -> Manage shortcuts …, In the pop-up window, you can view and modify the shortcut keys you want to change .

The following is the recommended shortcut key to remember :
Serial number         function                                  Shortcut key

1              Bookmark                           CTRL+F2 or Right click the left column directly ( Similar to setting breakpoints )

2              Quickly locate Bookmarks                    F2

3              Quickly copy a line                    CTRL+D

4              Delete a line quickly                    CTRL+L

5              Exchange uplink and downlink                    CTRL+T

6              Quickly navigate to a line             CTRL+G

7              A quick query                            CTRL+F

8              Make a single line comment                     CTRL+K Or is it CTRL+Q

9              Uncomment a single line                     CTRL+SHIFT+K Or is it CTRL+Q

10            Make multiple line comments                     CTRL+SHIFT+Q

11            Enlarge the font 、 narrow                  Click to enlarge 、 Zoom out button or CTRL+ mouse + The way of the roller

12            Choose multiple lines                             Right click to display : “ Start / end ” The last line selects “ Start / end ”

13            Collapse all rows                         ALT+0

14            Release all rows                         ALT+SHIFT+0

15            Collapse the current line                         CTRL+ALT+F

16            Release the current row                         CTRL+ALT+SHIFT+F

17            Full screen mode                             F11 ( Like the browser )

18            Merger line                                 Ctrl+J

3、 ... and 、 Change the theme

notepad++ There is a default interface style , If you're tired of the default interface style , Let's change the theme .
Click Settings -> Language formatting …, Then choose a satisfactory theme , Click save and close . The recommended topic here is :obsidian, Because the theme of cool black is also the mainstream IDE Popular topics in .

Four 、 Set up tab key

We know , Good indentation helps to improve code reading ,tab Key provides indent function . In most text editors , One tab The key is equivalent to 4 The width of an English space . We can also according to our own preferences , Set up tab key .
Click Settings -> Preferences … -> Tab settings .

5、 ... and 、 Word wrap

notepad++ and windows The system comes with the same Notepad , If a line of text is too long , The text will run out of the window . Need to set auto wrap .

6、 ... and 、 Automatic completion

Notepad++ With automatic replenishment function , The automatic completion only refers to the automatic matching of some symbols and labels . For example, when you enter parentheses , Entered the first parenthesis , You can automatically fill in the back parentheses . Write html when , Label before writing , The tail tag is automatically completed . When programming, the automatic completion of some keywords requires the help of additional plug-ins .

Setup method : Click settings in turn -> Preferences -> Done automatically .

7、 ... and 、 establish 、 Save the file

There are two common ways to create files . At the time of preservation , Specify both the file name 、 Also specify the file type . More troublesome .
create a file
Suggest : After file creation , Can be in “ Language ” Column specifies the file type , When saving, you only need to specify the file name .
Language settings

8、 ... and 、 Edit two files at the same time

Open the two files you want to edit at the same time . Right click on the tab of any one of the files , Check move to another view , The whole screen will be divided into two parts .

You can split and view vertically , You can also split horizontally to view , Please right-click the divider bar in the middle of the split view , Then select “ Spin to the right ” perhaps “ Rotate to the left ”, You can switch the horizontal or vertical mode .

Nine 、 keep Notepad++ Code highlighting style to web pages or word in

stay Notepad++ Many computer programming languages are supported in , Not only grammar high brightness display , It also has grammar folding function .
If you need to put the highlighted code , Paste the Word or html In file . You need to use the following skills .
Select the code to paste . then

In the toolbar : plug-in unit -> NppExport -> Export to RTF / Export to HTML / Copy RTF to Clipboard / Copy Html to Clipboard / Copy all formats to Clipboard

Highlight paste
Serial number      command                                               Function explanation
1.         Export to RTF                                Export the highlighted code to a rtf In file
2.         Export to HTML                             Export the highlighted code to a html In file .
3.         Copy RTF to Clipboard                  Highlight the code Copy to pasteboard
4.         Copy Html to Clipboard                 Highlight the code Copy to pasteboard
5.         Copy all formats to Clipboard        Highlight the code Copy to pasteboard


Ten 、 Plug in installation

Mode one : Download the plug-in online , Then import to notepad++ in .
First, we can visit notepad++ The official website of the plug-in , Download the plug-in we want to download .
perhaps , Click on “?” Under the menu ” Get plug-ins “ The button will pop up the plug-in download page or search on the Internet .dll Format Notepad++ plug-in unit .

Unzip the file after downloading , Click on Set up -> Import -> Import plug-ins . Or put the plug-in in the installation directory plugin Under the table of contents , restart Notepad++.
Mode two : Use “ Plug-in management ” function .
Click on :Plugins -> Plugin Manager -> Show Plugin Manager-> Avaliable A column displays a list of currently available plug-ins , Select the plug-in you want , Then click below Install You can automatically download and install the corresponding plug-ins , Restart after installation notepad++.
Plug in installation

Here we recommend the second method to install plug-ins , Because this will not cause incompatibility and other problems , Let plug-ins work healthily and efficiently .

11、 ... and 、 Use notepad++ Solve practical problems .

Case a : When the programmer debugs the interface , The result returned by the interface is json data ,json The data format is chaotic , Difficult to read . We can paste the returned results into notepad++ in , utilize Json Viewer The plug-in formats the data .
After completing the operation ,json The data structure is very clear .

Case 2 : When the programmer debugs the interface , Interfaces sometimes need json Data as arguments , Show... In one line of code . We can take the arguments json Paste the notepad++ in ( As shown in the figure above ), Do the following .

原网站

版权声明
本文为[Wanderer001]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/186/202207050851134001.html