102 references to IndentStyle
Microsoft.CodeAnalysis.CSharp.EditorFeatures (1)
Formatting\CSharpFormattingInteractionService.cs (1)
47var isSmartIndent = _editorOptionsService.GlobalOptions.GetOption(IndentationOptionsStorage.SmartIndent, LanguageNames.CSharp) == FormattingOptions2.IndentStyle.Smart;
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (39)
AutomaticCompletion\AutomaticBraceCompletionTests.cs (5)
1123{ FormattingOptions2.SmartIndent, FormattingOptions2.IndentStyle.Block }, 1153{ FormattingOptions2.SmartIndent, FormattingOptions2.IndentStyle.None }, 1189{ FormattingOptions2.SmartIndent, FormattingOptions2.IndentStyle.Block }, 1233{ FormattingOptions2.SmartIndent, FormattingOptions2.IndentStyle.Block }, 1681{ FormattingOptions2.SmartIndent, FormattingOptions2.IndentStyle.None },
Formatting\FormattingEngineTests.cs (2)
41{ IndentationOptionsStorage.SmartIndent, FormattingOptions2.IndentStyle.Smart }, 1073{ IndentationOptionsStorage.SmartIndent, FormattingOptions2.IndentStyle.None }
Formatting\Indentation\SmartIndenterEnterOnTokenTests.cs (4)
23using IndentStyle = Microsoft.CodeAnalysis.Formatting.FormattingOptions2.IndentStyle; 1435IndentStyle indentStyle = IndentStyle.Smart) 1446IndentStyle indentStyle)
Formatting\Indentation\SmartIndenterTests.cs (12)
22using IndentStyle = Microsoft.CodeAnalysis.Formatting.FormattingOptions2.IndentStyle; 130indentStyle: IndentStyle.None); 3255indentStyle: IndentStyle.Smart); 3461IndentStyle indentStyle = IndentStyle.Smart) 3472IndentStyle indentStyle) 3516IndentStyle indentStyle = IndentStyle.Smart) 3528IndentStyle indentStyle) 3546IndentStyle indentStyle = IndentStyle.Smart) 3557IndentStyle indentStyle)
SplitStringLiteral\SplitStringLiteralCommandHandlerTests.cs (9)
27using IndentStyle = Microsoft.CodeAnalysis.Formatting.FormattingOptions2.IndentStyle; 46IndentStyle indentStyle = IndentStyle.Smart, 132IndentStyle indentStyle = IndentStyle.Smart, 463IndentStyle.Block); 488IndentStyle.None); 539}", indentStyle: IndentStyle.Block); 560}", indentStyle: IndentStyle.None);
Workspaces\WorkspaceTests_EditorFeatures.cs (7)
1433Assert.Equal(FormattingOptions2.IndentStyle.Smart, primaryWorkspace.Options.GetOption(optionKey)); 1434Assert.Equal(FormattingOptions2.IndentStyle.Smart, secondaryWorkspace.Options.GetOption(optionKey)); 1440primaryWorkspace.Options = primaryWorkspace.Options.WithChangedOption(optionKey, FormattingOptions2.IndentStyle.Block); 1446Assert.Equal(FormattingOptions2.IndentStyle.Block, primaryWorkspace.Options.GetOption(optionKey)); 1447Assert.Equal(FormattingOptions2.IndentStyle.Block, secondaryWorkspace.Options.GetOption(optionKey)); 1459Assert.Equal(FormattingOptions2.IndentStyle.Block, primaryWorkspace.Options.GetOption(optionKey)); 1460Assert.Equal(FormattingOptions2.IndentStyle.Block, secondaryWorkspace.Options.GetOption(optionKey));
Microsoft.CodeAnalysis.CSharp.Features (10)
BraceCompletion\AbstractCurlyBraceOrBracketCompletionService.cs (1)
223if (options.IndentStyle == FormattingOptions2.IndentStyle.Smart)
BraceCompletion\CurlyBraceCompletionService.cs (9)
86var indentStyle = options.IndentStyle; 95new BraceCompletionFormattingRule(FormattingOptions2.IndentStyle.None), 96new BraceCompletionFormattingRule(FormattingOptions2.IndentStyle.Block), 97new BraceCompletionFormattingRule(FormattingOptions2.IndentStyle.Smart)); 99private readonly FormattingOptions2.IndentStyle _indentStyle; 102public BraceCompletionFormattingRule(FormattingOptions2.IndentStyle indentStyle) 107private BraceCompletionFormattingRule(FormattingOptions2.IndentStyle indentStyle, CSharpSyntaxFormattingOptions options) 113public static AbstractFormattingRule ForIndentStyle(FormattingOptions2.IndentStyle indentStyle) 253if (_indentStyle == FormattingOptions2.IndentStyle.Block)
Microsoft.CodeAnalysis.CSharp.Workspaces (3)
CSharpIndentationService.cs (2)
44protected override AbstractFormattingRule GetSpecializedIndentationFormattingRule(FormattingOptions2.IndentStyle indentStyle) 63if (options.IndentStyle != FormattingOptions2.IndentStyle.Smart)
CSharpSmartTokenFormatter.cs (1)
110_options.IndentStyle != FormattingOptions2.IndentStyle.Smart)
Microsoft.CodeAnalysis.EditorFeatures (7)
Options\TextBufferOptionProviders.cs (7)
92public static IndentingStyle ToEditorIndentStyle(this FormattingOptions2.IndentStyle value) 95FormattingOptions2.IndentStyle.Smart => IndentingStyle.Smart, 96FormattingOptions2.IndentStyle.Block => IndentingStyle.Block, 100public static FormattingOptions2.IndentStyle ToIndentStyle(this IndentingStyle value) 103IndentingStyle.Smart => FormattingOptions2.IndentStyle.Smart, 104IndentingStyle.Block => FormattingOptions2.IndentStyle.Block, 105_ => FormattingOptions2.IndentStyle.None,
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (1)
Formatting\CoreFormatterTestsBase.cs (1)
74FormattingOptions2.IndentStyle indentStyle,
Microsoft.CodeAnalysis.ExternalAccess.FSharp (4)
Editor\AutoFormattingOptionsWrapper.cs (2)
12private readonly FormattingOptions2.IndentStyle _indentStyle; 14public AutoFormattingOptionsWrapper(AutoFormattingOptions underlyingObject, FormattingOptions2.IndentStyle indentStyle)
Internal\Editor\FSharpEditorFormattingService.cs (1)
68var indentStyle = _globalOptions.GetOption(IndentationOptionsStorage.SmartIndent, LanguageNames.FSharp);
Internal\Editor\FSharpSmartIndentProvider.cs (1)
88var indentStyle = _provider._globalOptions.GetOption(IndentationOptionsStorage.SmartIndent, document.Project.Language);
Microsoft.CodeAnalysis.ExternalAccess.Razor (1)
RazorCSharpFormattingInteractionService.cs (1)
54IndentStyle = (FormattingOptions2.IndentStyle)indentStyle
Microsoft.CodeAnalysis.Features (3)
Wrapping\AbstractCodeActionComputer.cs (2)
86=> GetIndentationAfter(nodeOrToken, FormattingOptions2.IndentStyle.Smart); 88protected string GetIndentationAfter(SyntaxNodeOrToken nodeOrToken, FormattingOptions2.IndentStyle indentStyle)
Wrapping\SeparatedSyntaxList\SeparatedSyntaxListCodeActionComputer.cs (1)
135return GetIndentationAfter(previousToken, FormattingOptions2.IndentStyle.Block);
Microsoft.CodeAnalysis.LanguageServer.Protocol (1)
Features\Options\IndentationOptionsStorage.cs (1)
25public static PerLanguageOption2<FormattingOptions2.IndentStyle> SmartIndent => FormattingOptions2.SmartIndent;
Microsoft.CodeAnalysis.VisualBasic.EditorFeatures.UnitTests (13)
Formatting\Indentation\SmartIndenterTests.vb (7)
2549indentStyle:=FormattingOptions2.IndentStyle.Block) 2564indentStyle:=FormattingOptions2.IndentStyle.Block) 2579indentStyle:=FormattingOptions2.IndentStyle.None) 2978indentStyle:=FormattingOptions2.IndentStyle.Smart) 3014Optional indentStyle As FormattingOptions2.IndentStyle = FormattingOptions2.IndentStyle.Smart) 3024indentStyle As FormattingOptions2.IndentStyle)
Formatting\Indentation\SmartTokenFormatter_FormatTokenTests.vb (6)
157Await ExpectException_TestAsync(code, 4, FormattingOptions2.IndentStyle.Block) 170Await ExpectException_TestAsync(code, indentation:=0, indentStyle:=FormattingOptions2.IndentStyle.None) 173Private Shared Async Function ExpectException_TestAsync(codeWithMarkup As String, indentation As Integer, Optional indentStyle As FormattingOptions2.IndentStyle = FormattingOptions2.IndentStyle.Smart) As Task 177Private Shared Async Function TestAsync(codeWithMarkup As String, indentation As Integer, Optional indentStyle As FormattingOptions2.IndentStyle = FormattingOptions2.IndentStyle.Smart) As Threading.Tasks.Task
Microsoft.CodeAnalysis.VisualBasic.Workspaces (4)
SpecialFormattingOperation.vb (3)
15Private ReadOnly _indentStyle As FormattingOptions2.IndentStyle 17Public Sub New(indentStyle As FormattingOptions2.IndentStyle) 172If _indentStyle <> FormattingOptions2.IndentStyle.Smart Then
VisualBasicIndentationService.vb (1)
35Protected Overrides Function GetSpecializedIndentationFormattingRule(indentStyle As FormattingOptions2.IndentStyle) As AbstractFormattingRule
Microsoft.CodeAnalysis.Workspaces (15)
AbstractIndentation.cs (1)
19protected abstract AbstractFormattingRule GetSpecializedIndentationFormattingRule(FormattingOptions2.IndentStyle indentStyle);
AbstractIndentation.Indenter.cs (4)
70public IndentationResult? GetDesiredIndentation(FormattingOptions2.IndentStyle indentStyle) 73if (indentStyle == FormattingOptions2.IndentStyle.None) 78if (indentStyle == FormattingOptions2.IndentStyle.Block || 84Debug.Assert(indentStyle == FormattingOptions2.IndentStyle.Smart);
AbstractIndentationService.cs (3)
22var indentStyle = options.IndentStyle; 24if (indentStyle == FormattingOptions2.IndentStyle.None) 32if (indentStyle == FormattingOptions2.IndentStyle.Smart &&
Formatting\FormattingOptions.cs (1)
27/// <inheritdoc cref="FormattingOptions2.IndentStyle"/>
FormattingOptions2.cs (3)
62public static PerLanguageOption2<IndentStyle> SmartIndent = new PerLanguageOption2<IndentStyle>( 66.WithPublicOption(PublicFeatureName, "SmartIndent", static value => (PublicIndentStyle)value, static value => (IndentStyle)value);
IndentationOptions.cs (3)
19[DataMember(Order = 2)] public FormattingOptions2.IndentStyle IndentStyle { get; init; } = DefaultIndentStyle; 21public const FormattingOptions2.IndentStyle DefaultIndentStyle = FormattingOptions2.IndentStyle.Smart;