尝试使用Vs代码的新功能

VsCode工作区,十六进制编辑器,搜索,时间轴 (VsCode Workspace, Hex Editor, Search, Timeline)

在正则表达式替换中更改大小写 (Changing case in regex replace)

VS Code now supports changing the case of regex matching groups while doing a find/replace in the editor. This is done with the modifiers \u\U\l\L, where \u and \l will upper/lowercase a single character, and \U and \L will upper/lowercase the rest of the matching group.

VS Code现在支持在编辑器中查找/替换时更改正则表达式匹配组的大小写。 这可以通过修饰符\u\U\l\L ,其中\u\l将大写/小写单个字符,而\U\L将大写/小写匹配组的其余字符。

Image for post
VsCode VsCode

The modifiers can also be stacked — for example, \u\u\u$1 will uppercase the first three characters of the group, or \l\U$1 will lowercase the first character, and uppercase the rest.

修饰符也可以堆叠-例如, \u\u\u$1将大写该组的前三个字符,或者\l\U$1将小写第一个字符,其余的则大写。

Currently, these are only supported in the editor’s Find control, and not in global Find in Files.

当前,这些仅在编辑器的“查找”控件中受支持,而在“文件中的全局查找”中不受支持。

十六进制编辑器 (Hex Editor)

The HexEditor extension sees improvements every release of vs code. The latest version now support for copy and paste, file watching, and find and replace.

HexEditor扩展在vs代码的每个发行版中都有改进。 现在,最新版本支持复制和粘贴,文件监视以及查找和替换。

复制和粘贴 (Copy and Paste)

Ability to copy values to the clipboard and paste them either inside the editor, or in different place.

可以将值复制到剪贴板并将其粘贴到编辑器中或其他位置。

Image for post
VsCode VsCode

查找和替换 (Find and Replace)

We can no search in the hex editor now and comes with a similar find and replace widget. It supports searching hexadecimal fields using wildcards (for example, FF ?? DD) and regex searching on the decoded text section.

我们现在无法在十六进制编辑器中进行搜索,并且带有类似的查找和替换小部件。 它支持使用通配符(例如FF ?? DD )搜索十六进制字段,并支持在解码的文本部分上搜索正则表达式。

Image for post
VsCode VsCode

多选 (Multi Select)

We can now use drag and drop selection, Shift and (Ctrl+click) selection, and holding Shift and navigating with the keyboard to create a selection.

现在,我们可以使用拖放选择,Shift和(Ctrl+click)选择,并按住Shift并使用键盘导航以创建选择。

Image for post
VsCode VsCode

工作台功能 (Workbench Features)

使用鼠标滚轮切换标签页 (Switch tabs using mouse wheel)

We can now use the mouse wheel to scroll over the editor tabs.Press and hold the Shift key while scrolling to get the opposite behavior.

现在我们可以使用鼠标滚轮在编辑器选项卡上滚动。滚动时按住Shift键可获得相反的行为。

Image for post
VsCode VsCode

从文件导航到符号 (Navigate from files to symbols)

We can now continue to navigate to the symbols of a file result simply by typing @. For the file that is currently selected, all symbols will appear and the editor will open in the background to reveal the active symbol.

现在,我们只需输入@即可继续导航到文件结果的符号。 对于当前选定的文件,将出现所有符号,编辑器将在后台打开以显示活动符号。

Image for post
VsCode VsCode

通过用空格分隔多个查询来过滤结果 (Filter results by separating multiple queries with spaces)

We can add more search patterns after typing a space, If we are getting too many results for a file search.For example, we can narrow down results by folder if you type <file name> <folder name> one after the other.

键入空格后,我们可以添加更多搜索模式;如果对于文件搜索而言,搜索结果过多,例如,如果您依次输入<file name> <folder name> ,则可以按文件夹缩小结果范围。

Image for post
VsCode VsCode

This also works for the editor (Ctrl+Shift+O) and workspace (Ctrl+T) symbol picker. Any text after a space character will be used to filter by the container of that symbol.

这也适用于编辑器(Ctrl + Shift + O)和工作区(Ctrl + T)符号选择器。 空格字符后的任何文本都将用于过滤该符号的容器。

按最近使用的排序编辑器历史记录 (Sort editor history by most recently used)

“search.quickOpen.history.filterSortOrder”: “recency”

单个面板中的多个视图 (Multiple views in a single panel)

We can now have multiple views within a single panel to make better use of horizontal space.

现在,我们可以在一个面板中拥有多个视图,以更好地利用水平空间。

在侧边栏和面板之间移动视图 (Moving views between Sidebar and Panel)

We can now move the window Side Bar to Panel or vice versa. To do this we have to drag the view from its header and move it to the desired location. This can also be done using below keyboard command,1. View: Move View (workbench.action.moveView)2. View: Move Focused View (workbench.action.moveFocusedView)

现在,我们可以将侧边栏窗口移动到面板上,反之亦然。 为此,我们必须将视图从其标题拖动到所需位置。 也可以使用下面的键盘命令1完成此操作。 视图:移动视图( workbench.action.moveView )2。 视图:移动焦点视图( workbench.action.moveFocusedView )

Image for post
VsCode VsCode

可拖动的窗扇角 (Draggable sash corners)

We can now resize two orthogonal sashes simultaneously by grabbing and dragging the intersection between them.

现在,我们可以通过抓住和拖动两个正交的窗框的交点来同时调整它们的大小。

Image for post
VsCode VsCode

分组视图 (Grouping views)

We can also group some views together that come from different extensions or you feel the default groups of built-in views aren’t quite right for you. You can both move views into existing groups or create new groups for a select set of views. This works across the Side Bar and Panel.

我们还可以将来自不同扩展名的一些视图组合在一起,或者您认为默认的内置视图组不太适合您。 您既可以将视图移动到现有组中,也可以为一组选定的视图创建新组。 这适用于侧栏和面板。

Image for post
VsCode VsCode

重置视图位置 (Resetting view Locations)

The Views and groups of views can be reset to their default locations via their context menus.The below commands can also be used to reset the views,1. View: Reset Focused View Location (workbench.action.resetFocusedViewLocation)2. View: Reset View Locations (workbench.action.resetViewLocations)

可以通过上下文菜单将视图和视图组重置为其默认位置。以下命令也可以用于重置视图1。 视图:重置焦点视图位置( workbench.action.resetFocusedViewLocation )2。 视图:重置视图位置( workbench.action.resetViewLocations )

列选择模式 (Column Selection mode)

The Column Selection mode is entered by clicking menu item “Selection > Column Selection Mode”.When in this mode is entered, as indicated in the Status bar, the mouse gestures and the arrow keys will create a column selection

通过单击菜单项“选择>列选择模式”进入列选择模式。进入此模式时,如状态栏所示,鼠标手势和箭头键将创建列选择

Image for post
VsCode VsCode

选择时呈现空白 (Render whitespace on selection)

The editor.renderWhitespace setting can be changed from none to selection Whitespace characters will now be rendered on highlighted text by default

editor.renderWhitespace设置可以被改变noneselection空白字符将现在默认为突出显示的文本渲染

Image for post
VsCode VsCode

固定标签 (Pin tabs)

We can now pin tabs either from the context menu or using the new command workbench.action.pinEditor (Ctrl+K Shift+Enter).

现在,我们可以从上下文菜单或使用新命令workbench.action.pinEditor (Ctrl + K Shift + Enter)固定选项卡。

Image for post
VsCode VsCode

搜索编辑器 (Search Editor)

  • search.searchEditor.defaultNumberOfContextLines - Configure how many context lines a Search Editor shows by default.

    search.searchEditor.defaultNumberOfContextLines配置默认情况下搜索编辑器显示的上下文行数。

  • search.searchEditor.reusePriorSearchConfiguration - Reuse the last active Search Editor's configuration when creating a new Search Editor.

    search.searchEditor.reusePriorSearchConfiguration在创建新的Search Editor时重用上一个活动Search Editor的配置。

  • search.searchEditor.doubleClickBehaviour -Double-clicking can optionally open the source location,

    search.searchEditor.doubleClickBehaviour双击可以选择打开源位置,

The search results can also be viewed in a full-sized editor, complete with syntax highlighting and optional lines of surrounding context.

搜索结果还可以在完整的编辑器中查看,并带有语法高亮显示和周围环境的可选行。

Image for post
VsCode VsCode

Search Editor: Apply ChangesApply changes in a Search Editor to files in a workspace. This can be done through a extension.

搜索编辑器:应用更改 将搜索编辑器中的更改应用于工作空间中的文件。 这可以通过扩展来完成。

Image for post
Visual Studio Marketplace Visual Studio市场

时间线视图 (Timeline view)

The Timeline view is a unified view for visualizing time-series events (for example, Git commits, file saves, test runs, etc.) for a file. The Timeline view automatically updates showing the timeline for the currently active editor, by default.

时间线视图是一个统一的视图,用于可视化文件的时间序列事件(例如,Git提交,文件保存,测试运行等)。 默认情况下,“时间线”视图会自动更新以显示当前活动的编辑器的时间线。

Image for post
VsCode VsCode

Git:溢出菜单清理 (Git: Overflow menu cleanup)

The GIT commands are now grouped based on the action been done.

现在,根据已完成的操作将GIT命令分组。

Image for post
VsCode VsCode

最后的想法 (Final Thoughts)

Visual Studio Code is always getting updated with new features. Try out the above features and get you IDE to work easier.

Visual Studio Code始终会使用新功能进行更新。 试用上述功能,使您的IDE更加轻松地工作。

翻译自: https://medium.com/swlh/new-features-to-try-out-on-vs-code-154cfc71085a

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值