C# - Blank Lines
Last modified: 21 July 2022General
Around region
Property names:
[resharper_]csharp_blank_lines_around_region
, [resharper_]blank_lines_around_region
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Inside region
Property names:
[resharper_]csharp_blank_lines_inside_region
, [resharper_]blank_lines_inside_region
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Before single-line comment
Property names:
[resharper_]csharp_blank_lines_before_single_line_comment
, [resharper_]blank_lines_before_single_line_comment
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Blank lines in declarations
Keep max blank lines in declarations
Property names:
[resharper_]csharp_keep_blank_lines_in_declarations
, [resharper_]keep_blank_lines_in_declarations
Possible values:
an integer
Examples:
Before formatting | After formatting, value: 0 |
---|---|
|
|
Before formatting | After formatting, value: 1 |
---|---|
|
|
Before formatting | After formatting, value: 2 |
---|---|
|
|
Remove blank lines after "{" and before "}" in declarations
Property names:
[resharper_]csharp_remove_blank_lines_near_braces_in_declarations
, [resharper_]remove_blank_lines_near_braces_in_declarations
Possible values:
true | false
Examples:
Before formatting | After formatting, true |
---|---|
|
|
Before formatting | After formatting, false |
---|---|
|
|
After file header comment
Property names:
[resharper_]csharp_blank_lines_after_start_comment
, [resharper_]blank_lines_after_start_comment
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Between different "using" groups
Property names:
[resharper_]csharp_blank_lines_between_using_groups
, [resharper_]blank_lines_between_using_groups
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
After "using" list
Property names:
[resharper_]csharp_blank_lines_after_using_list
, [resharper_]blank_lines_after_using_list
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around namespace
Property names:
[resharper_]csharp_blank_lines_around_namespace
, [resharper_]blank_lines_around_namespace
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Inside namespace
Property names:
[resharper_]csharp_blank_lines_inside_namespace
, [resharper_]blank_lines_inside_namespace
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
After file-scoped namespace directive
Property names:
[resharper_]csharp_blank_lines_after_file_scoped_namespace_directive
, [resharper_]blank_lines_after_file_scoped_namespace_directive
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around type
Property names:
[resharper_]csharp_blank_lines_around_type
, [resharper_]blank_lines_around_type
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around single-line type
Property names:
[resharper_]csharp_blank_lines_around_single_line_type
, [resharper_]blank_lines_around_single_line_type
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Inside type
Property names:
[resharper_]csharp_blank_lines_inside_type
, [resharper_]blank_lines_inside_type
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around field
Property names:
[resharper_]csharp_blank_lines_around_field
, [resharper_]blank_lines_around_field
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around single line field
Property names:
[resharper_]csharp_blank_lines_around_single_line_field
, [resharper_]blank_lines_around_single_line_field
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around property/event
Property names:
[resharper_]csharp_blank_lines_around_property
, [resharper_]blank_lines_around_property
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around single line property/event
Property names:
[resharper_]csharp_blank_lines_around_single_line_property
, [resharper_]blank_lines_around_single_line_property
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around auto/abstract property/event
Property names:
[resharper_]csharp_blank_lines_around_auto_property
, [resharper_]blank_lines_around_auto_property
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around single line auto/abstract property/event
Property names:
[resharper_]csharp_blank_lines_around_single_line_auto_property
, [resharper_]blank_lines_around_single_line_auto_property
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around property/event accessor
Property names:
[resharper_]csharp_blank_lines_around_accessor
, [resharper_]blank_lines_around_accessor
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around single line property/event accessor
Property names:
[resharper_]csharp_blank_lines_around_single_line_accessor
, [resharper_]blank_lines_around_single_line_accessor
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around method
Property names:
[resharper_]csharp_blank_lines_around_invocable
, [resharper_]blank_lines_around_invocable
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around single line method
Property names:
[resharper_]csharp_blank_lines_around_single_line_invocable
, [resharper_]blank_lines_around_single_line_invocable
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Blank lines in code
Keep max blank lines in code
Property names:
[resharper_]csharp_keep_blank_lines_in_code
, [resharper_]keep_blank_lines_in_code
Possible values:
an integer
Examples:
Before formatting | After formatting, value: 0 |
---|---|
|
|
Before formatting | After formatting, value: 1 |
---|---|
|
|
Before formatting | After formatting, value: 2 |
---|---|
|
|
Remove blank lines after "{" and before "}" in code
Property names:
[resharper_]csharp_remove_blank_lines_near_braces_in_code
, [resharper_]remove_blank_lines_near_braces_in_code
Possible values:
true | false
Examples:
Before formatting | After formatting, true |
---|---|
|
|
Before formatting | After formatting, false |
---|---|
|
|
Around local function
Property names:
[resharper_]csharp_blank_lines_around_local_method
, [resharper_]blank_lines_around_local_method
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around single line local function
Property names:
[resharper_]csharp_blank_lines_around_single_line_local_method
, [resharper_]blank_lines_around_single_line_local_method
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Before statements with control transfer
Property names:
[resharper_]csharp_blank_lines_before_control_transfer_statements
, [resharper_]blank_lines_before_control_transfer_statements
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
After statements with control transfer
Property names:
[resharper_]csharp_blank_lines_after_control_transfer_statements
, [resharper_]blank_lines_after_control_transfer_statements
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Before statements with child blocks
Property names:
[resharper_]csharp_blank_lines_before_block_statements
, [resharper_]blank_lines_before_block_statements
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
After statements with child blocks
Property names:
[resharper_]csharp_blank_lines_after_block_statements
, [resharper_]blank_lines_after_block_statements
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Before multiline statements
Property names:
[resharper_]csharp_blank_lines_before_multiline_statements
, [resharper_]blank_lines_before_multiline_statements
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
After multiline statements
Property names:
[resharper_]csharp_blank_lines_after_multiline_statements
, [resharper_]blank_lines_after_multiline_statements
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around "case" section with a block in switch statement
Property names:
[resharper_]csharp_blank_lines_around_block_case_section
, [resharper_]blank_lines_around_block_case_section
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Around multiline "case" section in switch statement
Property names:
[resharper_]csharp_blank_lines_around_multiline_case_section
, [resharper_]blank_lines_around_multiline_case_section
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
Before "case" in switch statement
Property names:
[resharper_]csharp_blank_lines_before_case
, [resharper_]blank_lines_before_case
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|
After "case" in switch statement
Property names:
[resharper_]csharp_blank_lines_after_case
, [resharper_]blank_lines_after_case
Possible values:
an integer
Examples:
value: 0 |
---|
|
value: 1 |
---|
|
value: 2 |
---|
|