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](https://miro.medium.com/freeze/max/9999/0*22NIGgiQn-glFmJp.gif)
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](https://miro.medium.com/freeze/max/9999/0*gY9PMYYvqbB-si-K.gif)
查找和替换 (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](https://miro.medium.com/freeze/max/9999/0*xZH7_yGQF_rx3fzX.gif)
多选 (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](https://miro.medium.com/freeze/max/9999/0*-QC8vrU__uPPcMhS.gif)
工作台功能 (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](https://miro.medium.com/freeze/max/9999/0*DCDsPq00JHDsvMXz.gif)
从文件导航到符号 (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](https://miro.medium.com/freeze/max/9999/0*T5WXS_2kPTU_Fj7D.gif)
通过用空格分隔多个查询来过滤结果 (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](https://miro.medium.com/freeze/max/9999/0*g95Ypg7jZ_rqiVwJ.gif)
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](https://miro.medium.com/freeze/max/9999/0*VaTQTfbE2ZhduEwF.gif)
可拖动的窗扇角 (Draggable sash corners)
We can now resize two orthogonal sashes simultaneously by grabbing and dragging the intersection between them.
现在,我们可以通过抓住和拖动两个正交的窗框的交点来同时调整它们的大小。
![Image for post](https://miro.medium.com/freeze/max/9999/0*qKaNsBx6VxPdV699.gif)
分组视图 (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](https://miro.medium.com/freeze/max/9999/0*6W9Q7Sxa5eXpRUzL.gif)
重置视图位置 (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](https://miro.medium.com/freeze/max/9999/0*8QHXEGeLsP_PcrZI.gif)
选择时呈现空白 (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
设置可以被改变none
以selection
空白字符将现在默认为突出显示的文本渲染
![Image for post](https://miro.medium.com/max/9999/0*QGT_59UTaUlqERRw.png)
固定标签 (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](https://miro.medium.com/freeze/max/9999/0*RznWLKxjuoj9dSPW.gif)
搜索编辑器 (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](https://miro.medium.com/max/9999/0*YMpDsaHw9K9RQ9E5.png)
Search Editor: Apply ChangesApply changes in a Search Editor to files in a workspace. This can be done through a extension.
搜索编辑器:应用更改 将搜索编辑器中的更改应用于工作空间中的文件。 这可以通过扩展来完成。
![Image for post](https://miro.medium.com/freeze/max/9999/0*85jTgyymd0oKoCum.gif)
时间线视图 (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](https://miro.medium.com/freeze/max/9999/0*1cQx5cNwiB1fC9g1.gif)
Git:溢出菜单清理 (Git: Overflow menu cleanup)
The GIT commands are now grouped based on the action been done.
现在,根据已完成的操作将GIT命令分组。
![Image for post](https://miro.medium.com/max/9999/0*lMkNxaDo1QWSnGnP.png)
最后的想法 (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