JetBrains Rider 2025.2 Help

VB.NET 的 EditorConfig 属性:空行

保留现有格式

保留声明中的最大空行

属性名称:

[resharper_]vb_keep_blank_lines_in_declarations[resharper_]keep_blank_lines_in_declarations

可能的值:

整数

示例:

格式化之前

格式化后,值:0

Class SomeClass Public Sub Foo1() End Sub Public Sub Foo2() End Sub End Class
Class SomeClass Public Sub Foo1() End Sub Public Sub Foo2() End Sub End Class

格式化之前

格式化后,值:1

Class SomeClass Public Sub Foo1() End Sub Public Sub Foo2() End Sub End Class
Class SomeClass Public Sub Foo1() End Sub Public Sub Foo2() End Sub End Class

格式化之前

格式化后,值:2

Class SomeClass Public Sub Foo1() End Sub Public Sub Foo2() End Sub End Class
Class SomeClass Public Sub Foo1() End Sub Public Sub Foo2() End Sub End Class

保留代码中的最大空行

属性名称:

[resharper_]vb_keep_blank_lines_in_code[resharper_]keep_blank_lines_in_code

可能的值:

整数

示例:

格式化之前

格式化后,值:0

Public Sub Foo() Dim x As Integer Call SomeMethod(x) End Sub
Public Sub Foo() Dim x As Integer Call SomeMethod(x) End Sub

格式化之前

格式化后,值:1

Public Sub Foo() Dim x As Integer Call SomeMethod(x) End Sub
Public Sub Foo() Dim x As Integer Call SomeMethod(x) End Sub

格式化之前

格式化后,值:2

Public Sub Foo() Dim x As Integer Call SomeMethod(x) End Sub
Public Sub Foo() Dim x As Integer Call SomeMethod(x) End Sub

空白行

文件选项部分后

属性名称:

[resharper_]vb_blank_lines_after_options[resharper_]blank_lines_after_options

可能的值:

整数

示例:

值:0

Option Strict On Option Explicit Off Imports System

值:1

Option Strict On Option Explicit Off Imports System

值:2

Option Strict On Option Explicit Off Imports System

import 部分后

属性名称:

[resharper_]vb_blank_lines_after_imports[resharper_]blank_lines_after_imports

可能的值:

整数

示例:

值:0

Imports System Namespace N End Namespace

值:1

Imports System Namespace N End Namespace

值:2

Imports System Namespace N End Namespace

全局特性后

属性名称:

[resharper_]vb_blank_lines_around_global_attribute[resharper_]blank_lines_around_global_attribute

可能的值:

整数

示例:

值:0

<Assembly: AssemblyTitle("")> <Assembly: AssemblyDescription("")>

值:1

<Assembly: AssemblyTitle("")> <Assembly: AssemblyDescription("")>

值:2

<Assembly: AssemblyTitle("")> <Assembly: AssemblyDescription("")>

命名空间周围

属性名称:

[resharper_]vb_blank_lines_around_namespace[resharper_]blank_lines_around_namespace

可能的值:

整数

示例:

值:0

Namespace N1 End Namespace Namespace N2 End Namespace

值:1

Namespace N1 End Namespace Namespace N2 End Namespace

值:2

Namespace N1 End Namespace Namespace N2 End Namespace

类型周围

属性名称:

[resharper_]vb_blank_lines_around_type[resharper_]blank_lines_around_type

可能的值:

整数

示例:

值:0

Class C1 End Class Class C2 End Class

值:1

Class C1 End Class Class C2 End Class

值:2

Class C1 End Class Class C2 End Class

多行字段周围

属性名称:

[resharper_]vb_blank_lines_around_field[resharper_]blank_lines_around_field

可能的值:

整数

示例:

值:0

Class C Public Dim x As Integer, y As Integer Public Dim i As String, j As String End Class

值:1

Class C Public Dim x As Integer, y As Integer Public Dim i As String, j As String End Class

值:2

Class C Public Dim x As Integer, y As Integer Public Dim i As String, j As String End Class

单行字段周围

属性名称:

[resharper_]vb_blank_lines_around_single_line_field[resharper_]blank_lines_around_single_line_field

可能的值:

整数

示例:

值:0

Class C Public Dim x As Integer Public Dim i As String End Class

值:1

Class C Public Dim x As Integer Public Dim i As String End Class

值:2

Class C Public Dim x As Integer Public Dim i As String End Class

多行方法周围

属性名称:

[resharper_]vb_blank_lines_around_invocable[resharper_]blank_lines_around_invocable

可能的值:

整数

示例:

值:0

Class C Sub Foo1 End Sub Sub Foo2 End Sub End Class

值:1

Class C Sub Foo1 End Sub Sub Foo2 End Sub End Class

值:2

Class C Sub Foo1 End Sub Sub Foo2 End Sub End Class

单行方法周围

属性名称:

[resharper_]vb_blank_lines_around_single_line_invocable[resharper_]blank_lines_around_single_line_invocable

可能的值:

整数

示例:

值:0

Interface I Sub Foo1 Sub Foo2 End Interface

值:1

Interface I Sub Foo1 Sub Foo2 End Interface

值:2

Interface I Sub Foo1 Sub Foo2 End Interface

区域周围

属性名称:

[resharper_]vb_blank_lines_around_region[resharper_]blank_lines_around_region

可能的值:

整数

示例:

值:0

Class C Dim x as Integer #Region "Description" Dim y as Integer #End Region Dim z as Integer End Class

值:1

Class C Dim x as Integer #Region "Description" Dim y as Integer #End Region Dim z as Integer End Class

值:2

Class C Dim x as Integer #Region "Description" Dim y as Integer #End Region Dim z as Integer End Class

区域内

属性名称:

[resharper_]vb_blank_lines_inside_region[resharper_]blank_lines_inside_region

可能的值:

整数

示例:

值:0

Class C Dim x as Integer #Region "Description" Dim y as Integer #End Region Dim z as Integer End Class

值:1

Class C Dim x as Integer #Region "Description" Dim y as Integer #End Region Dim z as Integer End Class

值:2

Class C Dim x as Integer #Region "Description" Dim y as Integer #End Region Dim z as Integer End Class
最后修改日期: 2025年 9月 26日