Visual Studio提示和技巧

hashtag #vstip for a while, and this is a collection of the best ones so far. #vstip主题标签在Twitter上分享提示,这是迄今为止最好的提示的集合。

调试器 ( Debugger )

Hitting F10 to build, run, and attach debugger instead of F5 will automatically break on the first time your own code is being executed. No breakpoints needed.

在您第一次执行自己的代码时,按F10键来构建,运行和附加调试器而不是F5会自动中断。 无需断点。

image
Supported from Visual Studio 2005 受Visual Studio 2005支持

Reattach to process (Shift+Alt+P) is extremely helpful when you have to attach to the same process again and again.

当您必须一次又一次地附加到同一进程时,重新附加到进程(Shift + Alt + P)会非常有用。

image
Supported from Visual Studio 2017 v15.8 从Visual Studio 2017 v15.8支持

A blue dot in the margin indicates a switch of threads while stepping through debugging.

页边的蓝点表示在调试过程中线程切换。

image
Supported from Visual Studio 2013 受Visual Studio 2013支持

( Solution )

Improve performance of solution load and reduce visual noise by disabling restore of node expansions in Solution Explorer as well as Reopen documents on solution load.

通过在解决方案资源管理器中禁用节点扩展的还原以及在解决方案负载时重新打开文档来提高解决方案负载的性能并减少视觉噪声。

image
Supported from Visual Studio 2019 从Visual Studio 2019支持

For fast keyboard navigation, use Ctrl+T to find anything in your solution – files, classes etc.

为了快速进行键盘导航,请使用Ctrl + T在解决方案中查找任何内容–文件,类等。

image
Supported from Visual Studio 2017 受Visual Studio 2017支持

Assign a keyboard shortcut to perform a “git pull” so you don’t have to use CLI or Team Explorer to ensure your repo is up to date.

分配键盘快捷方式来执行“ git pull”,这样您就不必使用CLI或Team Explorer来确保您的存储库是最新的。

image
Supported in Visual Studio 2019 在Visual Studio 2019中受支持

Make Solution Explorer automatically select the current active document, so you never lose track of its location in the project.

使解决方案资源管理器自动选择当前的活动文档,因此您永远不会丢失它在项目中的位置。

image
Supported from Visual Studio 2010 受Visual Studio 2010支持

编辑 ( Editor )

Easily surround HTML elements with a using Shift+Alt+W. The inserted is selected so you can easily edit it to be any tag you’d like, and the end-tag matches up automatically.

使用Shift + Alt + W轻松围绕HTML元素。 已选择插入项,因此您可以轻松地将其编辑为所需的任何标签,并且结束标签会自动匹配。

image
Supported from Visual Studio 2017 受Visual Studio 2017支持

Copy any JSON fragment to the clipboard and paste it as strongly typed .NET classes into any C# or VB code file.

将任何JSON片段复制到剪贴板,并将其作为强类型.NET类粘贴到任何C#或VB代码文件中。

image
Supported from Visual Studio 2013 受Visual Studio 2013支持

You don’t need to write quotation marks around JSON property names, simply type a colon and Visual Studio will insert the quotes automatically.

您无需在JSON属性名称周围写引号,只需键入冒号,Visual Studio就会自动插入引号。

image
Supported in Visual Studio 2015 在Visual Studio 2015中受支持

Make IntelliSense and tooltips semi-transparent for the duration you press and hold the Control key.

在按住Control键的时间内,使IntelliSense和工具提示变为半透明。

image
Supported from Visual Studio 2010 受Visual Studio 2010支持

Instead of retyping ‘(‘ to show parameter info in method signatures, use Ctrl+Shift+Space to display the currently used overload.

不必重新键入'('以在方法签名中显示参数信息,而是使用Ctrl + Shift + Space来显示当前使用的重载。

image
Supported from Visual Studio 2010 受Visual Studio 2010支持

( Miscellaneous )

Play a sound when certain events occur within Visual Studio.

在Visual Studio中发生某些事件时播放声音。

image

Supported from Visual Studio 2010

受Visual Studio 2010支持

Create custom window layouts for specific development scenarios or monitor setups and switch between them easily.

为特定的开发方案创建自定义窗口布局,或监视设置并在它们之间轻松切换。

image
Supported from Visual Studio 2017 受Visual Studio 2017支持

Specify which Visual Studio components are required for any solution, and Visual Studio will prompt the user to install them if missing. Read more in the blog post Configure Visual Studio across your organization with .vsconfig.

指定任何解决方案都需要哪些Visual Studio组件,如果缺少,Visual Studio会提示用户安装它们。 在博客文章中使用.vsconfig配置整个组织中的Visual Studio ,以了解更多信息

image
Supported from Visual Studio 2019 从Visual Studio 2019支持

扩展名 ( Extensions )

Visual Studio Spell Checker. An editor extension that checks the spelling of comments, strings, and plain text as you type or interactively with a tool window. It can also spell check an entire solution, project, or selected items. Options are available to define multiple languages to spell check against. Visual Studio拼写检查器 。 一个编辑器扩展,可在您键入或与工具窗口交互时检查注释,字符串和纯文本的拼写。 它还可以拼写检查整个解决方案,项目或选定的项目。 选项可用于定义多种语言以进行拼写检查。
image
Supported from Visual Studio 2013 受Visual Studio 2013支持 Add New File. A Visual Studio extension for easily adding new files to any project. Simply hit Shift+F2 to create an empty file in the selected folder or in the same folder as the selected file. 添加新文件 。 一个Visual Studio扩展,可轻松将新文件添加到任何项目。 只需按Shift + F2即可在所选文件夹或与所选文件相同的文件夹中创建一个空文件。
image
Supported from Visual Studio 2015 受Visual Studio 2015支持 Git Diff Margin. Git Diff Margin displays live Git changes of the currently edited file on Visual Studio margin and scroll bar. Git Diff保证金 。 Git Diff Margin在Visual Studio页边距和滚动条上显示当前编辑文件的实时Git更改。
image
Supported from Visual Studio 2012 受Visual Studio 2012支持

This was just a few of the thousands of available extensions. To see more extensions, go to the Visual Studio Marketplace.

这只是数千个可用扩展中的几个。 要查看更多扩展,请转到Visual Studio市场

在结束时 (In closing)

These were just a few hand-picked tips from the hashtag #vstip on Twitter. There are plenty more to check out. If you have some great tips, please share them using the #vstip hashtag so we can all easily find them.

这些只是Twitter上#vstip标签上的一些精选技巧。 还有更多需要检查的地方。 如果您有一些很棒的提示,请使用#vstip主题标签将其分享,以便我们所有人都可以轻松找到它们。

翻译自: https://habr.com/en/company/microsoft/blog/457994/

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

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值