ISmartIndentationService.GetDesiredIndentation Method
Gets the desired indentation of an ITextSnapshotLine as displayed in ITextView.
Namespace: Microsoft.VisualStudio.Text.Editor
Assembly: Microsoft.VisualStudio.Text.UI (in Microsoft.VisualStudio.Text.UI.dll)
Syntax
'Declaration
Function GetDesiredIndentation ( _
textView As ITextView, _
line As ITextSnapshotLine _
) As Nullable(Of Integer)
Nullable<int> GetDesiredIndentation(
ITextView textView,
ITextSnapshotLine line
)
Nullable<int> GetDesiredIndentation(
ITextView^ textView,
ITextSnapshotLine^ line
)
abstract GetDesiredIndentation :
textView:ITextView *
line:ITextSnapshotLine -> Nullable<int>
function GetDesiredIndentation(
textView : ITextView,
line : ITextSnapshotLine
) : Nullable<int>
Parameters
textView
Type: Microsoft.VisualStudio.Text.Editor.ITextViewThe text view in which the line is displayed.
line
Type: Microsoft.VisualStudio.Text.ITextSnapshotLineThe line for which to compute the indentation.
Return Value
Type: System.Nullable<Int32>
The desired indentation
Remarks
This service consumes ISmartIndentProvider objects to determine how to perform the indentation.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.