在 Visual Studio 2015 中向下复制行 [英] Copy line down in Visual Studio 2015
问题描述
我想将复制行向下/向上键盘快捷键设置为 ctrl-alt-down/up.问题是我在键盘快捷键中找不到正确的命令.
I want to set the copy line down/up keyboard shortcuts to ctrl-alt-down/up. The problem is that i cannot find the proper commands in the keyboard shortcuts.
有以下几种:Edit.MoveSelectedLinesDownEdit.MoveSelectedLinesUp
There are the following: Edit.MoveSelectedLinesDown Edit.MoveSelectedLinesUp
但是没有什么可以向上/向下复制选定的行.它们是否已从 2015 版本中删除?
But there is nothing for copying selected lines up/down. Were they removed from 2015 version?
附言我知道我可以在一行上执行 ctrl-c、ctrl-v 但这对我来说很不舒服.
P.S. I know i can do ctrl-c, ctrl-v on a line but this is very uncomfortable for me.
问候
推荐答案
您可以使用我的 编写一个简单的 C# 命令Visual Commander 扩展并为其指定快捷方式:
You can write a simple C# command with my Visual Commander extension and assign a shortcut to it:
public void Run(EnvDTE80.DTE2 DTE, Microsoft.VisualStudio.Shell.Package package)
{
DTE.ExecuteCommand("Edit.Copy");
DTE.ExecuteCommand("Edit.Paste");
}
这篇关于在 Visual Studio 2015 中向下复制行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!