Export (0) Print
Expand All
Expand Minimize

LanguageService.IVsLanguageContextProvider.UpdateLanguageContext Method

Updates the current user help context given a selected region of the given source.

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)
  Microsoft.VisualStudio.Package.LanguageService.12.0 (in Microsoft.VisualStudio.Package.LanguageService.12.0.dll)
  Microsoft.VisualStudio.Package.LanguageService.11.0 (in Microsoft.VisualStudio.Package.LanguageService.11.0.dll)

int IVsLanguageContextProvider.UpdateLanguageContext(
	uint dwHint,
	IVsTextLines buffer,
	TextSpan[] ptsSelection,
	Object ptr
)

Parameters

dwHint
Type: System.UInt32

[in] A set of flags from the LanguageContextHint enumeration.

buffer
Type: Microsoft.VisualStudio.TextManager.Interop.IVsTextLines

[in] The IVsTextLines object holding the source.

ptsSelection
Type: Microsoft.VisualStudio.TextManager.Interop.TextSpan[]

[in] A single TextSpan object describing the selected range of text (or the current caret position).

ptr
Type: System.Object

[in] An IVsUserContext object that is to be updated.

Return Value

Type: System.Int32
If successful, returns S_OK; otherwise, returns an error code.

Implements

IVsLanguageContextProvider.UpdateLanguageContext(UInt32, IVsTextLines, TextSpan[], Object)

The given object can be queried for the IVsUserContext interface by casting it to the IVsUserContext interface: IVsUserContext pContext = ptr as IVsUserContext.

The base method calls the other LanguageService.UpdateLanguageContext and always returns S_OK.

Show:
© 2014 Microsoft