import "textstor.idl";
import "ctfutb.idl";
#endif
-cpp_quote("#include <winuser.h>")
cpp_quote("#define TF_E_STACKFULL MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0501)")
cpp_quote("#define TF_E_DISCONNECTED MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0504)")
interface ITfContext;
interface IEnumTfDocumentMgrs;
interface IEnumTfContexts;
-interface ITfFunctionProvider;
-interface IEnumTfFunctionProviders;
interface ITfCompartmentMgr;
interface ITfEditSession;
interface ITfRange;
-interface ITfContextView;
-interface IEnumTfContextViews;
interface ITfProperty;
interface ITfReadOnlyProperty;
-interface IEnumTfProperties;
-interface ITfRangeBackup;
interface IEnumTfLanguageProfiles;
-interface ITfEditRecord;
interface ITfCompositionView;
interface ITfKeyEventSink;
typedef [uuid(5a886226-ae9a-489b-b991-2b1e25ee59a9)] enum { TF_ANCHOR_START = 0, TF_ANCHOR_END = 1 } TfAnchor;
+[
+ object,
+ uuid(101d6610-0990-11d3-8df0-00105a2799b5),
+ pointer_default(unique)
+]
+interface ITfFunctionProvider : IUnknown
+{
+ HRESULT GetType(
+ [out] GUID *guid);
+
+ HRESULT GetDescription(
+ [out] BSTR *desc);
+
+ HRESULT GetFunction(
+ [in] REFGUID guid,
+ [in] REFIID riid,
+ [out, iid_is(riid)] IUnknown **func);
+}
+
+[
+ object,
+ uuid(e4b24db0-0990-11d3-8df0-00105a2799b5),
+ pointer_default(unique)
+]
+interface IEnumTfFunctionProviders : IUnknown
+{
+ HRESULT Clone(
+ [out] IEnumTfFunctionProviders **ret);
+
+ HRESULT Next(
+ [in] ULONG count,
+ [out, size_is(count), length_is(*fetched)] ITfFunctionProvider **prov,
+ [out] ULONG *fetched);
+
+ HRESULT Reset();
+
+ HRESULT Skip(
+ [in] ULONG count);
+}
+
[
object,
uuid(aa80e801-2021-11d2-93e0-0060b067b86e),
HRESULT GetGlobalCompartment(
[out] ITfCompartmentMgr **ppCompMgr);
-};
+}
+
+[
+ object,
+ uuid(3e90ade3-7594-4cb0-bb58-69628f5f458c),
+ pointer_default(unique)
+]
+interface ITfThreadMgrEx : ITfThreadMgr
+{
+ HRESULT ActivateEx(
+ [out] TfClientId *id,
+ [in] DWORD flags);
+ HRESULT GetActiveFlags(
+ [out] DWORD *flags);
+}
[
object,
HRESULT EnumContexts(
[out] IEnumTfContexts **ppEnum);
-};
+}
+
+[
+ object,
+ uuid(2433bf8e-0f9b-435c-ba2c-180611978c30),
+ pointer_default(unique)
+]
+interface ITfContextView : IUnknown
+{
+ HRESULT GetRangeFromPoint(
+ [in] TfEditCookie cookie,
+ [in] const POINT *pt,
+ [in] DWORD flags,
+ [out] ITfRange **range);
+
+ HRESULT GetTextExt(
+ [in] TfEditCookie cookie,
+ [in] ITfRange *range,
+ [out] RECT *rect,
+ [out] BOOL *clipped);
+
+ HRESULT GetScreenExt(
+ [out] RECT *rect);
+
+ HRESULT GetWnd(
+ [out] HWND *hwnd);
+}
+
+[
+ object,
+ uuid(f0c0f8dd-cf38-44e1-bb0f-68cf0d551c78),
+ pointer_default(unique)
+]
+interface IEnumTfContextViews : IUnknown
+{
+ HRESULT Clone(
+ [out] IEnumTfContextViews **ret);
+
+ HRESULT Next(
+ [in] ULONG count,
+ [out, size_is(count), length_is(*fetched)] ITfContextView **views,
+ [out] ULONG *fetched);
+
+ HRESULT Reset();
+
+ HRESULT Skip(
+ [in] ULONG count);
+}
+
+[
+ object,
+ uuid(19188cb0-aca9-11d2-afc5-00105a2799b5),
+ pointer_default(unique)
+]
+interface IEnumTfProperties : IUnknown
+{
+ HRESULT Clone(
+ [out] IEnumTfProperties **ret);
+
+ HRESULT Next(
+ [in] ULONG count,
+ [out, size_is(count), length_is(*fetched)] ITfProperty **props,
+ [out] ULONG *fetched);
+
+ HRESULT Reset();
+
+ HRESULT Skip(
+ [in] ULONG count);
+}
+
+[
+ object,
+ uuid(463a506d-6992-49d2-9b88-93d55e70bb16),
+ pointer_default(unique)
+]
+interface ITfRangeBackup : IUnknown
+{
+ HRESULT Restore(
+ [in] TfEditCookie cookie,
+ [in] ITfRange *range);
+}
[
object,
[in] TfEditCookie ec,
[in] ITfRange *pRange,
[out] ITfRangeBackup **ppBackup);
-
-};
+}
const DWORD TF_INVALID_COOKIE = 0xffffffff;
HRESULT UnadviseSink(
[in] DWORD dwCookie);
-};
+}
[
object,
[in] LANGID langid,
[in] REFGUID guidProfile,
[in] HKL hKL);
-};
+}
typedef [uuid(44d2825a-10e5-43b2-877f-6cb2f43b7e7e)]
struct TF_INPUTPROCESSORPROFILE {
HRESULT IsEqualTfGuidAtom([in] TfGuidAtom guidatom,
[in] REFGUID rguid,
[out] BOOL *pfEqual);
-};
+}
+
+[
+ object,
+ uuid(f99d3f40-8e32-11d2-bf46-00105a2799b5),
+ pointer_default(unique)
+]
+interface IEnumTfRanges : IUnknown
+{
+ HRESULT Clone([out] IEnumTfRanges **ppEnum);
+
+ HRESULT Next(
+ [in] ULONG ulCount,
+ [out, size_is(ulCount), length_is(*pcFetched)] ITfRange **ppRange,
+ [out] ULONG *pcFetched);
+
+ HRESULT Reset();
+
+ HRESULT Skip(ULONG ulCount);
+}
+
+[
+ object,
+ uuid(42d4d099-7c1a-4a89-b836-6c6f22160df0),
+ pointer_default(unique)
+]
+interface ITfEditRecord : IUnknown
+{
+ const DWORD TF_GTP_INCL_TEXT = 0x1;
+
+ HRESULT GetSelectionStatus(
+ [out] BOOL *changed);
+
+ HRESULT GetTextAndPropertyUpdates(
+ [in] DWORD flags,
+ [in, size_is(count)] const GUID **props,
+ [in] ULONG count,
+ [out] IEnumTfRanges **ret);
+}
[
object,
[in] ITfContext *pic,
[in] TfEditCookie ecReadOnly,
[in] ITfEditRecord *pEditRecord);
-};
+}
[
object,
HRESULT OnEndComposition(
[in] ITfCompositionView *pComposition);
-};
+}
[
object,
HRESULT Skip(
[in] ULONG ulCount);
-};
+}
[
object,
[in] TfClientId tid);
HRESULT Deactivate();
-};
+}
[
object,
HRESULT OnPopContext(
[in] ITfContext *pic);
-};
+}
[
object,
[in] ITfContext *pic,
[in] REFGUID rguid,
[out] BOOL *pfEaten);
-};
+}
[
object,
[in] ITfContext *pic,
[in] REFGUID rguid,
[out] BOOL *pfEaten);
-};
+}
[
object,
[in] UINT wMsgFilterMin,
[in] UINT wMsgFilterMax,
[out] BOOL *pfResult);
-};
+}
[
object,
HRESULT GetClientId(
[in] REFCLSID rclsid,
[out] TfClientId *ptid);
-};
+}
[
object,
HRESULT GetContext(
[out] ITfContext **ppContext);
-};
+}
[
object,
[in] DWORD dwFlags,
[in] IDataObject *pDataObject,
[out] ITfRange **ppRange);
-};
+}
[
object,
[out] ULONG *pcb);
}
-[
- object,
- uuid(f99d3f40-8e32-11d2-bf46-00105a2799b5),
- pointer_default(unique)
-]
-interface IEnumTfRanges : IUnknown
-{
- HRESULT Clone([out] IEnumTfRanges **ppEnum);
-
- HRESULT Next(
- [in] ULONG ulCount,
- [out, size_is(ulCount), length_is(*pcFetched)] ITfRange **ppRange,
- [out] ULONG *pcFetched);
-
- HRESULT Reset();
-
- HRESULT Skip(ULONG ulCount);
-}
-
[
object,
uuid(5efd22Ba-7838-46cb-88e2-cadb14124f8f),
HRESULT GetValue(
[out] VARIANT *pvarValue);
-};
+}
[
object,
HRESULT EnumCompartments(
[out] IEnumGUID **ppEnum);
-};
+}
[
object,
HRESULT Skip(
[in] ULONG ulCount);
-};
+}
[
object,
HRESULT Skip(
[in] ULONG ulCount);
-};
+}
+
+[
+ object,
+ local,
+ uuid(ea1ea137-19df-11d7-a6d2-00065b84435c),
+ pointer_default(unique)
+]
+interface ITfUIElement : IUnknown
+{
+ HRESULT GetDescription(
+ [out] BSTR *description);
+
+ HRESULT GetGUID(
+ [out] GUID *guid);
+
+ HRESULT Show(
+ [in] BOOL show);
+
+ HRESULT IsShown(
+ [out] BOOL *show);
+}
+
+[
+ object,
+ local,
+ uuid(887aa91e-acba-4931-84da-3c5208cf543f),
+ pointer_default(unique)
+]
+interface IEnumTfUIElements : IUnknown
+{
+ HRESULT Clone(
+ [out] IEnumTfUIElements **enum_elements);
+
+ HRESULT Next(
+ [in] ULONG count,
+ [out, size_is(count), length_is(fetched)] ITfUIElement **element,
+ [out] ULONG fetched);
+
+ HRESULT Reset();
+
+ HRESULT Skip(
+ [in] ULONG count);
+}
+
+[
+ object,
+ local,
+ uuid(ea1ea135-19df-11d7-a6d2-00065b84435c),
+ pointer_default(unique)
+]
+interface ITfUIElementMgr : IUnknown
+{
+ HRESULT BeginUIElement(
+ [in] ITfUIElement *element,
+ [in, out] BOOL *show,
+ [out] DWORD *id);
+
+ HRESULT UpdateUIElement(
+ [in] DWORD id);
+
+ HRESULT EndUIElement(
+ [in] DWORD id);
+
+ HRESULT GetUIElement(
+ [in] DWORD id,
+ [out] ITfUIElement **element);
+
+ HRESULT EnumUIElements(
+ [out] IEnumTfUIElements **enum_elements);
+}
[
object,
HRESULT UnadviseSingleSink(
[in] TfClientId tid,
[in] REFIID riid);
-};
+}
[
object,
HRESULT OnSetThreadFocus();
HRESULT OnKillThreadFocus();
-};
+}
[
object,