Visual Studio跳至功能开始 [英] Visual Studio Jump to Beginning of Function

查看:117
本文介绍了Visual Studio跳至功能开始的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道 Ctrl + } 会将您带到Visual Studio中的相应括号,但是说我处于一个巨大的函数中间,我不知道不知道顶部或底部在哪里,是否有直接进入函数声明的快捷方式?

I know that Ctrl+} will take you to the corresponding brace in Visual Studio, but say I'm in the middle of a gigantic function and I don't know where the top or the bottom is, is there a shortcut to get directly to the function declaration?

void function()
{
//so many lines of code
//can't see the top or the bottom curly brace
//can i get to the top of the function with a shortcut?
}

推荐答案

我重新安装了VS2017.从15.9.1开始,我的默认值为 Alt + Shift + [.

I have a fresh install of VS2017. As of 15.9.1, the default for me is Alt+Shift+[.

这是EditorContextMenus.Navigate.GoToContainingBlock的快捷方式.因此,如果您的数据块深度很深,则可能必须多次执行此快捷方式,但它会将您带到您要去的地方.

This is the shortcut for EditorContextMenus.Navigate.GoToContainingBlock. So you may have to execute this shortcut multiple times if you are a few block layers deep, but it'll get you where you want to go.

这篇关于Visual Studio跳至功能开始的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆