当前位置:网站首页>Skills of switching from Si to vscode

Skills of switching from Si to vscode

2020-11-10 12:53:24 osc_zitca8hu

SI Switch to VSCode Use skills

Use Source Insight many years , Recently, due to copyright related reasons, we have to use Visual studio Code. I feel like I can't understand the code

In order to find and use SI A similar feeling , I summed up a few SI The most commonly used functions on VSCode A similar usage in :

The highlighted

First , install highlight-words plug-in unit .

It can be used after installation “Highlight Toggle Current” Command to highlight :

 Insert picture description here

The effect is as follows :

 Insert picture description here

There are two problems :

1、uint8_t and uint32_t Medium int It's also highlighted , It's not the effect I usually want

2、 Border highlight , I'm not used to it

Both problems can be solved by configuration . stay setting.json Modify configuration :

 Insert picture description here

The display effect after configuration is as follows :

 Insert picture description here

Every time you type “Highlight Toggle Current” The order is more troublesome , So set the shortcut key . Here's the picture , After setting, the user's feeling is basically the same as SI The same as .

 Insert picture description here

Show document outline

VSCode There are two ways to display the outline of the document .

The first one is :

choice EXPLORER -> OUTLINE, The effect is as follows :

 Insert picture description here

The second kind :

Use the default shortcut key ctrl+shift+o, The effect is as follows :

 Insert picture description here

In this way, you can not only display the outline of the document , You can also find symbols , And you can jump to the corresponding location of the code , as follows :

 Insert picture description here

Find references

Use Reference Search View plug-in unit . This plug-in seems to be installed by default .

Select the keyword you want to find , Then use the default shortcut key Alt+Shift+F12.

Or select the keyword you want to search for , Then right click , choice Find All Reference

as follows :

 Insert picture description here
 Insert picture description here

then , Use the default shortcut key F4 and Shift+F4, You can jump to the next / The previous result .

Other common shortcut keys

Forward / Back to the previous location of the source code where the cursor is :Alt+LeftArrow / Alt+RightArrow

Jump to the specified symbol in this document :Ctrl+Shift+O ( front “ Show document outline ” This shortcut has been introduced in the second method of )

In Ben workspace Jump to the specified symbol :Ctrl+T

Bookmarks

I am here SI I haven't used a similar function , I'm learning VSCode By chance , I think it's very good , So it's also recorded .

Here's the bookmark function kindle The bookmarks on e-books are almost , When you look at the code, you can bookmark important places , It's convenient to jump back to the bookmarked place later .

Need to install Bookmarks plug-in unit .

After installation , Right click . Use the following command to achieve bookmarking and jump operations :

 Insert picture description here

版权声明
本文为[osc_zitca8hu]所创,转载请带上原文链接,感谢