1 override of GetLinePosition
Microsoft.CodeAnalysis.EditorFeatures.Text (1)
Extensions.SnapshotSourceText.cs (1)
167public override LinePosition GetLinePosition(int position)
31 references to GetLinePosition
Microsoft.CodeAnalysis (5)
Syntax\LineDirectiveMap.cs (2)
51var unmappedStartPos = sourceText.Lines.GetLinePosition(span.Start); 52var unmappedEndPos = sourceText.Lines.GetLinePosition(span.End);
Syntax\SyntaxTreeExtensions.cs (1)
71var position = text.Lines.GetLinePosition(index);
Text\TextLineCollection.cs (2)
57return new LinePositionSpan(GetLinePosition(span.Start), GetLinePosition(span.End));
Microsoft.CodeAnalysis.CodeStyle (1)
src\Compilers\Core\Portable\Syntax\SyntaxTreeExtensions.cs (1)
71var position = text.Lines.GetLinePosition(index);
Microsoft.CodeAnalysis.CSharp (4)
Syntax\CSharpLineDirectiveMap.cs (3)
182var unmappedPos = sourceText.Lines.GetLinePosition(position); 231var unmappedStartPos = lines.GetLinePosition(span.Start); 232var unmappedEndPos = lines.GetLinePosition(span.End);
Syntax\CSharpSyntaxTree.cs (1)
753=> GetText(cancellationToken).Lines.GetLinePosition(position);
Microsoft.CodeAnalysis.CSharp.Features (2)
Structure\Providers\ArgumentListStructureProvider.cs (2)
37var start = text.Lines.GetLinePosition(openToken.SpanStart).Line; 38var end = text.Lines.GetLinePosition(closeToken.SpanStart).Line;
Microsoft.CodeAnalysis.Features (2)
Structure\BlockSpan.cs (2)
134var startLine = lines.GetLinePosition(this.TextSpan.Start).Line; 139var endLine = lines.GetLinePosition(this.TextSpan.End).Line;
Microsoft.CodeAnalysis.LanguageServer.Protocol (2)
Extensions\ProtocolConversions.cs (1)
282Position = LinePositionToPosition(text.Lines.GetLinePosition(position))
Handler\OnAutoInsert\OnAutoInsertHandler.cs (1)
182desiredCaretLinePosition = indentedText.Lines.GetLinePosition(caretLineInIndentedText.End);
Microsoft.CodeAnalysis.UnitTests (8)
Text\LargeTextTests.cs (4)
175Assert.Equal(lineNumber, text.Lines.GetLinePosition(p).Line); 176Assert.Equal(p - start, text.Lines.GetLinePosition(p).Character); 183Assert.Equal(lineNumber - 1, text.Lines.GetLinePosition(start - 1).Line); 191Assert.Equal(lineNumber + 1, text.Lines.GetLinePosition(nextPosition).Line);
Text\StringTextTest.cs (4)
128Assert.Equal(lineNumber, text.Lines.GetLinePosition(p).Line); 129Assert.Equal(p - start, text.Lines.GetLinePosition(p).Character); 136Assert.Equal(lineNumber - 1, text.Lines.GetLinePosition(start - 1).Line); 144Assert.Equal(lineNumber + 1, text.Lines.GetLinePosition(nextPosition).Line);
Microsoft.CodeAnalysis.VisualBasic (4)
Syntax\VisualBasicLineDirectiveMap.vb (3)
148Dim unmappedPos As LinePosition = sourceText.Lines.GetLinePosition(position) 210Dim unmappedStartPos = sourceText.Lines.GetLinePosition(span.Start) 211Dim unmappedEndPos = sourceText.Lines.GetLinePosition(span.End)
Syntax\VisualBasicSyntaxTree.vb (1)
485Return Me.GetText().Lines.GetLinePosition(position)
Microsoft.CodeAnalysis.Workspaces (3)
Shared\Extensions\FileLinePositionSpanExtensions.cs (2)
89Contract.ThrowIfTrue(start < text.Lines.GetLinePosition(0)); 90Contract.ThrowIfTrue(end > text.Lines.GetLinePosition(text.Length));
src\Compilers\Core\Portable\Syntax\SyntaxTreeExtensions.cs (1)
71var position = text.Lines.GetLinePosition(index);