ITfSourceSingle interface (msctf.h)
The ITfSourceSingle interface is implemented by the TSF manager. It is used by applications and text services to install and remove various advise sinks. This interface differs from ITfSource in that advise sinks installed with ITfSourceSingle only support one advise sink at a time whereas advise sinks installed with ITfSource support multiple simultaneous advise sinks.
Inheritance
The ITfSourceSingle interface inherits from the IUnknown interface. ITfSourceSingle also has these types of members:
Methods
The ITfSourceSingle interface has these methods.
ITfSourceSingle::AdviseSingleSink ITfSourceSingle::AdviseSingleSink method |
ITfSourceSingle::UnadviseSingleSink ITfSourceSingle::UnadviseSingleSink method |
Remarks
The TSF manager has different implementations of ITfSourceSingle, depending upon how the ITfSourceSingle interface is obtained. The difference in the implementations is the types of advise sinks that can be installed with the interface. The different implementations can be obtained from the following objects.
For more information about advise sinks that can be installed by each implementation, see ITfSourceSingle::AdviseSingleSink.Examples
ITfThreadMgr
HRESULT hr;
ITfSourceSingle *pSourceSingle;
hr = pThreadManager->QueryInterface(IID_ITfSourceSingle, (LPVOID*)&pSourceSingle);
if(SUCCEEDED(hr))
{
//Use the ITfSourceSingle interface.
pSourceSingle->Release();
}
ITfContext
HRESULT hr;
ITfSourceSingle *pSourceSingle;
hr = pContext->QueryInterface(IID_ITfSourceSingle, (LPVOID*)&pSourceSingle);
if(SUCCEEDED(hr))
{
//Use the ITfSourceSingle interface.
pSourceSingle->Release();
}
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 2000 Professional [desktop apps | UWP apps] |
Minimum supported server | Windows 2000 Server [desktop apps | UWP apps] |
Target Platform | Windows |
Header | msctf.h |
Redistributable | TSF 1.0 on Windows 2000 Professional |