Visual Studio 代码格式化插件(等号自动对齐、注释自动对齐等)

1、下载地址

插件:Code alignment  下载地址

2、介绍

Based on principles borrowed from mathematics and other disciplines, code alignment gives extra meaning to your code by lining up similar data in columns. This is something we do naturally when working with tables and spreadsheets, but unfortunately it doesn't get applied to code often enough.

The usual excuses are, "It's too hard. It takes too long. They don't pay me enough." With this extension, these excuses are no longer valid.

支持等号自动对齐,注释自动对齐,自定义对齐模式等功能;

3、安装方法

下载文件如下图所示:

双击即可安装;注意:最低版本为:visual studio 2010

安装后,重启Visual Studio.可以看见工具条如下图所示:

4、效果

自动对齐注释:

对齐前:

操作:选中欲对齐的内容,点击Align by按钮,自定义对齐模式为  "//":

对齐后:

 

等号对齐:

对齐前:

操作:选中欲对齐的内容,点击工具条上的=号:

对齐后效果:

4、高级功能

正则表达式

 

 

 

 

你可能感兴趣的:(格式化)