ExpansionProvider.FormatSpan Method
Formats the specified text span.
Namespace: Microsoft.VisualStudio.Package
Assemblies: Microsoft.VisualStudio.Package.LanguageService.9.0 (in Microsoft.VisualStudio.Package.LanguageService.9.0.dll)
Microsoft.VisualStudio.Package.LanguageService (in Microsoft.VisualStudio.Package.LanguageService.dll)
Microsoft.VisualStudio.Package.LanguageService.10.0 (in Microsoft.VisualStudio.Package.LanguageService.10.0.dll)
Syntax
'Dichiarazione
Public Overridable Function FormatSpan ( _
buffer As IVsTextLines, _
ts As TextSpan() _
) As Integer
'Utilizzo
Dim instance As ExpansionProvider
Dim buffer As IVsTextLines
Dim ts As TextSpan()
Dim returnValue As Integer
returnValue = instance.FormatSpan(buffer, _
ts)
public virtual int FormatSpan(
IVsTextLines buffer,
TextSpan[] ts
)
public:
virtual int FormatSpan(
IVsTextLines^ buffer,
array<TextSpan>^ ts
)
abstract FormatSpan :
buffer:IVsTextLines *
ts:TextSpan[] -> int
override FormatSpan :
buffer:IVsTextLines *
ts:TextSpan[] -> int
public function FormatSpan(
buffer : IVsTextLines,
ts : TextSpan[]
) : int
Parameters
- buffer
Type: Microsoft.VisualStudio.TextManager.Interop.IVsTextLines
The IVsTextLines buffer.
- ts
Type: array<Microsoft.VisualStudio.TextManager.Interop.TextSpan[]
An array of TextSpan objects.
Return Value
Type: System.Int32
S_OK() if the method succeeded, otherwise E_NOTIMPL().
Implements
IVsExpansionClient.FormatSpan(IVsTextLines, array<TextSpan[])
Remarks
This method first checks that buffer is the same as the IVsTextLines in the Source, and throws an ArgumentException if they are not. If format selection is enabled, this method iterates through the array of TextSpan objects and formats them.
.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.