update editorconfig to include settings for spaces
This commit is contained in:
Родитель
c1a428a8bd
Коммит
9a8c9afb7b
|
@ -82,6 +82,30 @@ csharp_new_line_before_finally = true
|
||||||
csharp_new_line_before_members_in_object_initializers = true
|
csharp_new_line_before_members_in_object_initializers = true
|
||||||
csharp_new_line_before_members_in_anonymous_types = true
|
csharp_new_line_before_members_in_anonymous_types = true
|
||||||
|
|
||||||
|
# Space preferences
|
||||||
|
csharp_space_after_cast = false
|
||||||
|
csharp_space_after_colon_in_inheritance_clause = true
|
||||||
|
csharp_space_after_comma = true
|
||||||
|
csharp_space_after_dot = false
|
||||||
|
csharp_space_after_keywords_in_control_flow_statements = true
|
||||||
|
csharp_space_after_semicolon_in_for_statement = true
|
||||||
|
csharp_space_around_binary_operators = before_and_after
|
||||||
|
csharp_space_around_declaration_statements = do_not_ignore
|
||||||
|
csharp_space_before_colon_in_inheritance_clause = true
|
||||||
|
csharp_space_before_comma = false
|
||||||
|
csharp_space_before_dot = false
|
||||||
|
csharp_space_before_open_square_brackets = false
|
||||||
|
csharp_space_before_semicolon_in_for_statement = false
|
||||||
|
csharp_space_between_empty_square_brackets = false
|
||||||
|
csharp_space_between_method_call_empty_parameter_list_parentheses = false
|
||||||
|
csharp_space_between_method_call_name_and_opening_parenthesis = false
|
||||||
|
csharp_space_between_method_call_parameter_list_parentheses = false
|
||||||
|
csharp_space_between_method_declaration_empty_parameter_list_parentheses = false
|
||||||
|
csharp_space_between_method_declaration_name_and_open_parenthesis = false
|
||||||
|
csharp_space_between_method_declaration_parameter_list_parentheses = false
|
||||||
|
csharp_space_between_parentheses = false
|
||||||
|
csharp_space_between_square_brackets = false
|
||||||
|
|
||||||
[*.cs]
|
[*.cs]
|
||||||
# Disable enforcement of items covered by StyleCop Analyzers
|
# Disable enforcement of items covered by StyleCop Analyzers
|
||||||
dotnet_style_qualification_for_field = false:none
|
dotnet_style_qualification_for_field = false:none
|
||||||
|
|
|
@ -504,7 +504,7 @@ namespace Roslyn.SyntaxVisualizer.Control
|
||||||
var currentTag = (SyntaxTag)current.Tag;
|
var currentTag = (SyntaxTag)current.Tag;
|
||||||
if (currentTag.FullSpan.Contains(span))
|
if (currentTag.FullSpan.Contains(span))
|
||||||
{
|
{
|
||||||
if (( currentTag.Span == span || currentTag.FullSpan == span ) && ( kind == null || currentTag.Kind == kind ))
|
if ((currentTag.Span == span || currentTag.FullSpan == span) && (kind == null || currentTag.Kind == kind))
|
||||||
{
|
{
|
||||||
CollapseEverythingBut(current);
|
CollapseEverythingBut(current);
|
||||||
match = current;
|
match = current;
|
||||||
|
@ -515,7 +515,7 @@ namespace Roslyn.SyntaxVisualizer.Control
|
||||||
|
|
||||||
foreach (TreeViewItem item in current.Items)
|
foreach (TreeViewItem item in current.Items)
|
||||||
{
|
{
|
||||||
if (category != SyntaxCategory.Operation && ( (SyntaxTag)item.Tag ).Category == SyntaxCategory.Operation)
|
if (category != SyntaxCategory.Operation && ((SyntaxTag)item.Tag).Category == SyntaxCategory.Operation)
|
||||||
{
|
{
|
||||||
// Do not prefer navigating to IOperation nodes when clicking in source code
|
// Do not prefer navigating to IOperation nodes when clicking in source code
|
||||||
continue;
|
continue;
|
||||||
|
@ -528,8 +528,8 @@ namespace Roslyn.SyntaxVisualizer.Control
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (match == null && ( kind == null || currentTag.Kind == kind ) &&
|
if (match == null && (kind == null || currentTag.Kind == kind) &&
|
||||||
( category == SyntaxCategory.None || category == currentTag.Category ))
|
(category == SyntaxCategory.None || category == currentTag.Category))
|
||||||
{
|
{
|
||||||
match = current;
|
match = current;
|
||||||
}
|
}
|
||||||
|
@ -889,7 +889,7 @@ namespace Roslyn.SyntaxVisualizer.Control
|
||||||
ParentItem = parentItem
|
ParentItem = parentItem
|
||||||
};
|
};
|
||||||
|
|
||||||
var item = CreateTreeViewItem(tag, ( isLeadingTrivia ? "Lead: " : "Trail: " ) + tag.Kind + " " + trivia.Span.ToString(), trivia.ContainsDiagnostics);
|
var item = CreateTreeViewItem(tag, (isLeadingTrivia ? "Lead: " : "Trail: ") + tag.Kind + " " + trivia.Span.ToString(), trivia.ContainsDiagnostics);
|
||||||
item.SetResourceReference(ForegroundProperty, SyntaxTriviaTextBrushKey);
|
item.SetResourceReference(ForegroundProperty, SyntaxTriviaTextBrushKey);
|
||||||
|
|
||||||
if (SyntaxTree != null && trivia.ContainsDiagnostics)
|
if (SyntaxTree != null && trivia.ContainsDiagnostics)
|
||||||
|
@ -1024,7 +1024,7 @@ namespace Roslyn.SyntaxVisualizer.Control
|
||||||
|
|
||||||
private static TreeViewItem? FindTreeViewItem(DependencyObject source)
|
private static TreeViewItem? FindTreeViewItem(DependencyObject source)
|
||||||
{
|
{
|
||||||
while (source != null && !( source is TreeViewItem ))
|
while (source != null && !(source is TreeViewItem))
|
||||||
{
|
{
|
||||||
if (source is ContentElement contentElement)
|
if (source is ContentElement contentElement)
|
||||||
{
|
{
|
||||||
|
@ -1079,15 +1079,15 @@ namespace Roslyn.SyntaxVisualizer.Control
|
||||||
}
|
}
|
||||||
|
|
||||||
var directedSyntaxGraphEnabled =
|
var directedSyntaxGraphEnabled =
|
||||||
( SyntaxNodeDirectedGraphRequested != null ) &&
|
(SyntaxNodeDirectedGraphRequested != null) &&
|
||||||
( SyntaxTokenDirectedGraphRequested != null ) &&
|
(SyntaxTokenDirectedGraphRequested != null) &&
|
||||||
( SyntaxTriviaDirectedGraphRequested != null );
|
(SyntaxTriviaDirectedGraphRequested != null);
|
||||||
|
|
||||||
var symbolDetailsEnabled =
|
var symbolDetailsEnabled =
|
||||||
( SemanticModel != null ) &&
|
(SemanticModel != null) &&
|
||||||
( ( (SyntaxTag)_currentSelection.Tag ).Category == SyntaxCategory.SyntaxNode );
|
(((SyntaxTag)_currentSelection.Tag).Category == SyntaxCategory.SyntaxNode);
|
||||||
|
|
||||||
if (( !directedSyntaxGraphEnabled ) && ( !symbolDetailsEnabled ))
|
if ((!directedSyntaxGraphEnabled) && (!symbolDetailsEnabled))
|
||||||
{
|
{
|
||||||
e.Handled = true;
|
e.Handled = true;
|
||||||
}
|
}
|
||||||
|
@ -1145,7 +1145,7 @@ namespace Roslyn.SyntaxVisualizer.Control
|
||||||
}
|
}
|
||||||
|
|
||||||
var currentTag = (SyntaxTag)_currentSelection.Tag;
|
var currentTag = (SyntaxTag)_currentSelection.Tag;
|
||||||
if (( SemanticModel != null ) && ( currentTag.Category == SyntaxCategory.SyntaxNode ) && currentTag.SyntaxNode is not null)
|
if ((SemanticModel != null) && (currentTag.Category == SyntaxCategory.SyntaxNode) && currentTag.SyntaxNode is not null)
|
||||||
{
|
{
|
||||||
var symbol = SemanticModel.GetSymbolInfo(currentTag.SyntaxNode).Symbol;
|
var symbol = SemanticModel.GetSymbolInfo(currentTag.SyntaxNode).Symbol;
|
||||||
if (symbol == null)
|
if (symbol == null)
|
||||||
|
@ -1177,7 +1177,7 @@ namespace Roslyn.SyntaxVisualizer.Control
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (( SemanticModel != null ) && ( currentTag.Category == SyntaxCategory.SyntaxNode ))
|
if ((SemanticModel != null) && (currentTag.Category == SyntaxCategory.SyntaxNode))
|
||||||
{
|
{
|
||||||
var symbol = SemanticModel.GetTypeInfo(currentTag.SyntaxNode).Type;
|
var symbol = SemanticModel.GetTypeInfo(currentTag.SyntaxNode).Type;
|
||||||
DisplaySymbolInPropertyGrid(symbol);
|
DisplaySymbolInPropertyGrid(symbol);
|
||||||
|
@ -1199,7 +1199,7 @@ namespace Roslyn.SyntaxVisualizer.Control
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (( SemanticModel != null ) && ( currentTag.Category == SyntaxCategory.SyntaxNode ))
|
if ((SemanticModel != null) && (currentTag.Category == SyntaxCategory.SyntaxNode))
|
||||||
{
|
{
|
||||||
var symbol = SemanticModel.GetTypeInfo(currentTag.SyntaxNode).ConvertedType;
|
var symbol = SemanticModel.GetTypeInfo(currentTag.SyntaxNode).ConvertedType;
|
||||||
DisplaySymbolInPropertyGrid(symbol);
|
DisplaySymbolInPropertyGrid(symbol);
|
||||||
|
@ -1221,7 +1221,7 @@ namespace Roslyn.SyntaxVisualizer.Control
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (( SemanticModel != null ) && ( currentTag.Category == SyntaxCategory.SyntaxNode ))
|
if ((SemanticModel != null) && (currentTag.Category == SyntaxCategory.SyntaxNode))
|
||||||
{
|
{
|
||||||
var symbol = SemanticModel.GetAliasInfo(currentTag.SyntaxNode);
|
var symbol = SemanticModel.GetAliasInfo(currentTag.SyntaxNode);
|
||||||
DisplaySymbolInPropertyGrid(symbol);
|
DisplaySymbolInPropertyGrid(symbol);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче