ISmartIndentationService.GetDesiredIndentation 方法
取得所要的縮排的ITextSnapshotLine中所顯示ITextView。
命名空間: Microsoft.VisualStudio.Text.Editor
組件: Microsoft.VisualStudio.Text.UI (在 Microsoft.VisualStudio.Text.UI.dll 中)
語法
'宣告
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>
參數
textView
類型:Microsoft.VisualStudio.Text.Editor.ITextView顯示下一行的文字檢視。
line
類型:Microsoft.VisualStudio.Text.ITextSnapshotLine要用來計算縮排的文字行。
傳回值
類型:Nullable<Int32>
您想要的縮排
備註
這項服務會使用ISmartIndentProvider物件來決定如何執行縮排。
.NET Framework 安全性
- 完全信任立即呼叫者。這個成員無法供部分信任的程式碼使用。如需詳細資訊,請參閱從部分受信任程式碼使用程式庫。