IVsHiddenTextManager::CreateHiddenTextSession Method (UInt32, Object^, IVsHiddenTextClient^, IVsHiddenTextSession^)
Creates a new hidden text session for a text buffer.
Assembly: Microsoft.VisualStudio.TextManager.Interop (in Microsoft.VisualStudio.TextManager.Interop.dll)
int CreateHiddenTextSession( unsigned int dwFlags, Object^ pOwningObject, IVsHiddenTextClient^ pClient, [OutAttribute] IVsHiddenTextSession^% ppState )
Parameters
- dwFlags
-
Type:
System::UInt32
[in] This value is reserved for future use.
- pOwningObject
-
Type:
System::Object^
[in] Text buffer containing the outlining or hidden text session.
- pClient
-
Type:
Microsoft.VisualStudio.TextManager.Interop::IVsHiddenTextClient^
[in] Pointer to a hidden text client for the buffer. The hidden text client provides notification of when a hidden text or outlining region is expanded or collapsed by the user. For more information, see IVsHiddenTextClient.
- ppState
-
Type:
Microsoft.VisualStudio.TextManager.Interop::IVsHiddenTextSession^
[out] Pointer to the newly created hidden text session for the text buffer. For more information, see IVsHiddenTextSession.
Return Value
Type: System::Int32If the method succeeds, it returns S_OK. If it fails, it returns an error code.
From textmgr.idl:
HRESULT IVsHiddenTextManager::CreateHiddenTextSession ([in] DWORD dwFlags, [in] IUnknown *pOwningObject, [in] IVsHiddenTextClient *pClient, [out] IVsHiddenTextSession **ppState );
If a hidden text session already exists in a buffer (that is, a call to GetHiddenTextSession is non-null, then you cannot specify a hidden text client (IVsHiddenTextManager) to inform you of user actions on the hidden text region.