ホーム › UI.TextServices › ITfDocumentMgr
ITfDocumentMgr
COMメソッド 6
vtbl = vtable インデックス(0始まり)。HSP等からCOMメソッドをインデックス指定で呼ぶ際に使用します。0〜2 は IUnknown。
vtbl 3 HRESULT CreateContext(DWORD tidOwner, DWORD dwFlags, IUnknown* punk, ITfContext** ppic, DWORD* pecTextStore)
| tidOwner | DWORD | in | コンテキストを作成するテキストサービスのクライアント識別子 (TfClientId) を指定する。 |
| dwFlags | DWORD | in | 予約済みのフラグであり、0 を指定する。 |
| punk | IUnknown* | in | コンテキストに関連付けるテキストストア (ITextStoreACP または ITextStoreAnchor) を実装するオブジェクトへのポインタである。 |
| ppic | ITfContext** | out | 新しく作成された ITfContext インターフェイスを受け取るポインタである。 |
| pecTextStore | DWORD* | out | テキストストアへの読み取り専用アクセスに使用する編集クッキーを受け取るポインタである。 |
vtbl 4 HRESULT Push(ITfContext* pic)
| pic | ITfContext* | in | コンテキストスタックの最上位にプッシュする ITfContext へのポインタである。 |
| dwFlags | DWORD | in | ポップ操作の動作を制御するフラグを指定する。TF_POPF_ALL でスタック上のすべてのコンテキストをポップする。 |
vtbl 6 HRESULT GetTop(ITfContext** ppic)
| ppic | ITfContext** | out | スタック最上位のコンテキストを表す ITfContext インターフェイスを受け取るポインタである。スタックが空の場合は NULL が返る。 |
vtbl 7 HRESULT GetBase(ITfContext** ppic)
| ppic | ITfContext** | out | スタック最下位 (ベース) のコンテキストを表す ITfContext インターフェイスを受け取るポインタである。 |
vtbl 8 HRESULT EnumContexts(IEnumTfContexts** ppEnum)
| ppEnum | IEnumTfContexts** | out | このドキュメント内のコンテキストを列挙する IEnumTfContexts インターフェイスを受け取るポインタである。 |
HSP用 COM定義
#usecom / #comfunc によるHSPのCOM呼び出し定義。数字は vtbl インデックス(0始まり)。クラスIDが無い場合 #usecom の末尾は "{}"、ある場合は "{CLSID}"。
出力引数:
#define global IID_ITfDocumentMgr "{AA80E7F4-2021-11D2-93E0-0060B067B86E}" #usecom global ITfDocumentMgr IID_ITfDocumentMgr "{}" #comfunc global ITfDocumentMgr_CreateContext 3 int,int,sptr,sptr,var #comfunc global ITfDocumentMgr_Push 4 sptr #comfunc global ITfDocumentMgr_Pop 5 int #comfunc global ITfDocumentMgr_GetTop 6 sptr #comfunc global ITfDocumentMgr_GetBase 7 sptr #comfunc global ITfDocumentMgr_EnumContexts 8 sptr ; ※数字は vtbl インデックス(0始まり)。0/1/2 は IUnknown(QueryInterface/AddRef/Release)。 ; ※このインターフェースは直接 CoCreateInstance するクラスIDが無いため "{}"(他メソッド/アクティベーションで取得)。 ; ※出力/バッファ引数は var(変数直渡し)。varptr 方式にも切替可。 ; ※ハンドル/void*等の不透明ポインタは IronHSP では intptr 指定が可能。#define global IID_ITfDocumentMgr "{AA80E7F4-2021-11D2-93E0-0060B067B86E}" #usecom global ITfDocumentMgr IID_ITfDocumentMgr "{}" #comfunc global ITfDocumentMgr_CreateContext 3 int,int,sptr,sptr,sptr #comfunc global ITfDocumentMgr_Push 4 sptr #comfunc global ITfDocumentMgr_Pop 5 int #comfunc global ITfDocumentMgr_GetTop 6 sptr #comfunc global ITfDocumentMgr_GetBase 7 sptr #comfunc global ITfDocumentMgr_EnumContexts 8 sptr ; ※数字は vtbl インデックス(0始まり)。0/1/2 は IUnknown(QueryInterface/AddRef/Release)。 ; ※このインターフェースは直接 CoCreateInstance するクラスIDが無いため "{}"(他メソッド/アクティベーションで取得)。 ; ※出力/バッファ引数はポインタ方式(token=sptr / 呼び出しは varptr(変数))。 ; ※ハンドル/void*等の不透明ポインタは IronHSP では intptr 指定が可能。