visual-studio 在 Visual Studio 中拆分编辑窗口

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/294449/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-10-22 09:56:12  来源:igfitidea点击:

Split edit window in Visual Studio

visual-studio

提问by stimms

It there any way to show two editing windows in visual studio? I would like to look at two source files at the same time but I must be missing the option to do that.

有没有办法在visual studio中显示两个编辑窗口?我想同时查看两个源文件,但我一定缺少这样做的选项。

采纳答案by Rob Prouse

Another easy option is to open two documents, then just click and drag the tab for one of the documents and drop it on the document itself. This will display a menu that lets you move the document to a new vertical or horizontal tab group.

另一个简单的选择是打开两个文档,然后只需单击并拖动其中一个文档的选项卡并将其放在文档本身上。这将显示一个菜单,可让您将文档移动到新的垂直或水平选项卡组。

I find this to be the easiest and quickest way to do this.

我发现这是最简单、最快捷的方法。

You didn't ask in the question, but if you want to edit onedocument in two windows, you can grab the small area above the scrollbar and drag it down. You will now have your document open in two scrollable areas. Great for working on two sections at once.

你没有问问题,但是如果你想在两个窗口中编辑一个文档,你可以抓住滚动条上方的小区域并将其向下拖动。您现在将在两个可滚动区域中打开您的文档。非常适合同时处理两个部分。

回答by Amadeus Sánchez

I think what you want to do is to add a new vertical tab group. The keyboard shortcut to do that is

我认为您想要做的是添加一个新的垂直选项卡组。执行此操作的键盘快捷键是

Alt+ W, V.

Alt+ W, V

According to this source, it works for Visual Studio 2005, 2008, and 2010. In my experience, it also works for Visual Studio 2013.

根据这个来源,它适用于 Visual Studio 2005、2008 和 2010。根据我的经验,它也适用于 Visual Studio 2013。

回答by THX-1138

To create a keyboard shortcut for "Window->New Vertical Tab Group" you need to assign a shortcut to "Window.NewVerticalTabGroup" command.
Tools->Options->Environment->Keyboard, in "Show commands containing" type "Window.NewVerticalTabGroup", and assign the keyboard shortuct in "Press shortcut keys" field.
Remember to click "Assign" before "OK".

要为“Window->New Vertical Tab Group”创建键盘快捷键,您需要为“Window.NewVerticalTabGroup”命令分配一个快捷键。
工具->选项->环境->键盘,在“显示包含的命令”中输入“Window.NewVerticalTabGroup”,并在“按快捷键”字段中指定键盘快捷键。
请记住在“确定”之前单击“分配”。

回答by Icaroo

For Visual Studio 2012:

对于 Visual Studio 2012:

Move your mouse over the Class tab > Right Click on the Title of the Class > New Horizontal Tab Group or New Vertical Tab Group.

将鼠标移到类选项卡上 > 右键单击​​类的标题 > 新建水平选项卡组或新建垂直选项卡组。

If you want to split the same class: Tools -> Options -> Keyboard -> search by Window.Split and add a new shortcut.

如果要拆分同一个类:工具 -> 选项 -> 键盘 -> 按 Window.Split 搜索并添加新的快捷方式。

回答by Engineer

In visual Studio 2015 right click tab part where file name is written and select vertical split or horizontal split.

在 Visual Studio 2015 中右键单击写入文件名的选项卡部分,然后选择垂直拆分或水平拆分。