VA助手(Visual Assist X) 笔记
官方网站:http://www.wholetomato.com/
一、 快捷键
Shift+Alt+F Find References 查找引用
Shift+Alt+S FindSynbolDialog 打开查找符号对话框 <—很常用
Alt+G GotoImplementation 转到定义
Alt+M ListMethodsInCurrentFile 光标定位在顶部搜索文件中的方法
Alt+Left Arrow NavigateBack 后台
Alt+O OpenCurrespondingFile .h/.cpp切换
Shift+Alt+O OpenFileInSolutionDialog 打开解决方案文件对话框
Ctrl+Shift+V Parse 弹出最近10个copy的内容菜单
Shift+Alt+Q RefactorContextMenu 弹出重构菜单
Shift+Alt+C RefactorCreateFromUsage
Shift+Alt+R RefactorRename 改名
Alt+Down Arraw ScopeNext 当前行和下一行互换位置
Alt+Up Arraw ScopePrevious 当前行和上一行互换位置
二、插入代码片段
效果如下图所示:
1、在VS的工具栏上可以看到VA的工具栏图标,点击 VA Options
2、在弹出的窗口左侧中,选择 Suggestions(工具箱),点击 Edit VA Snippets
3、在弹出的窗口的左侧选择语言,我选择的是C#,选中 “C#”点击右键,如下图操作
4、输入需要添加的 快速代码片段 信息,可参考下图
5、如何使用?在VA的工具栏,点击 Insert VS Snippet
选择 VA Snippets with shortcuts/添加的名称
在弹出的窗口中,输入brief(摘要)
在代码中就生成了,之前设定的代码片段
附上我使用的文件头注释:
/***************************************************************************** * @brief : $brief$ * @author : qingqing_zhao * @email : 569032731@qq.com * @date : $YEAR$/$MONTH$/$DAY$ $HOUR$:$MINUTE$ * @version : ver 1.0 *****************************************************************************/
.csharpcode, .csharpcode pre { font-size: small; color: rgba(0, 0, 0, 1); font-family: consolas, “Courier New”, courier, monospace; background-color: rgba(255, 255, 255, 1) }
.csharpcode pre { margin: 0 }
.csharpcode .rem { color: rgba(0, 128, 0, 1) }
.csharpcode .kwrd { color: rgba(0, 0, 255, 1) }
.csharpcode .str { color: rgba(0, 96, 128, 1) }
.csharpcode .op { color: rgba(0, 0, 192, 1) }
.csharpcode .preproc { color: rgba(204, 102, 51, 1) }
.csharpcode .asp { background-color: rgba(255, 255, 0, 1) }
.csharpcode .html { color: rgba(128, 0, 0, 1) }
.csharpcode .attr { color: rgba(255, 0, 0, 1) }
.csharpcode .alt { background-color: rgba(244, 244, 244, 1); width: 100%; margin: 0 }
.csharpcode .lnum { color: rgba(96, 96, 96, 1) }
官方文档:http://docs.wholetomato.com/default.asp?W171
三、破解方法
1、解压出下载的补丁包中的 VA_X.dll
2、VS 2013 的路径:C:\Users\用户名\AppData\Local\Microsoft\VisualStudio\12.0\Extensions\ 文件夹内有VA开头的
VS 2012 的路径 : C:\Users\用户名\AppData\Local\Microsoft\VisualStudio\11.0\Extensions\ 文件夹内有VA开头的
3、替换步骤2文件夹中的VA_X.dll
4、重启VS即可