iphlpapi: Add GetPerTcpConnectionEStats stub.
[wine.git] / include / msctf.idl
blobdd9997211a4822bdd408a24c0b4edaba4f06d4e0
1 /*
2 * Copyright 2008 Aric Stewart, CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 #ifndef DO_NO_IMPORTS
20 import "oaidl.idl";
21 import "comcat.idl";
22 import "textstor.idl";
23 import "ctfutb.idl";
24 #endif
26 cpp_quote("#define TF_E_STACKFULL MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0501)")
27 cpp_quote("#define TF_E_DISCONNECTED MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0504)")
28 cpp_quote("#define TF_E_ALREADY_EXISTS MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0506)")
29 cpp_quote("#define TF_E_NOLOCK MAKE_HRESULT(SEVERITY_ERROR, FACILITY_ITF, 0x0201)")
31 cpp_quote("HRESULT WINAPI TF_CreateThreadMgr(ITfThreadMgr **pptim);")
32 cpp_quote("HRESULT WINAPI TF_GetThreadMgr(ITfThreadMgr **pptim);")
33 cpp_quote("HRESULT WINAPI TF_CreateInputProcessorProfiles(ITfInputProcessorProfiles **ppipr);")
34 cpp_quote("HRESULT WINAPI TF_CreateLangBarMgr(ITfLangBarMgr **pppbm);")
35 cpp_quote("HRESULT WINAPI TF_CreateLangBarItemMgr(ITfLangBarItemMgr **pplbim);")
36 cpp_quote("HRESULT WINAPI TF_InvalidAssemblyListCacheIfExist(void);")
38 cpp_quote("EXTERN_C const GUID GUID_PROP_TEXTOWNER;")
39 cpp_quote("DEFINE_GUID(GUID_PROP_ATTRIBUTE,0x34b45670,0x7526,0x11d2,0xa1,0x47,0x00,0x10,0x5a,0x27,0x99,0xb5);")
40 cpp_quote("EXTERN_C const GUID GUID_PROP_LANGID;")
41 cpp_quote("EXTERN_C const GUID GUID_PROP_READING;")
42 cpp_quote("EXTERN_C const GUID GUID_PROP_COMPOSING;")
44 cpp_quote("EXTERN_C const CLSID CLSID_TF_ThreadMgr;")
45 cpp_quote("EXTERN_C const CLSID CLSID_TF_InputProcessorProfiles;")
46 cpp_quote("EXTERN_C const CLSID CLSID_TF_LangBarMgr;")
47 cpp_quote("EXTERN_C const CLSID CLSID_TF_CategoryMgr;")
48 cpp_quote("EXTERN_C const CLSID CLSID_TF_DisplayAttributeMgr;")
50 /* GUIDs for Compartments */
51 cpp_quote("EXTERN_C const GUID GUID_COMPARTMENT_KEYBOARD_DISABLED;")
52 cpp_quote("EXTERN_C const GUID GUID_COMPARTMENT_KEYBOARD_OPENCLOSE;")
53 cpp_quote("EXTERN_C const GUID GUID_COMPARTMENT_HANDWRITING_OPENCLOSE;")
54 cpp_quote("EXTERN_C const GUID GUID_COMPARTMENT_SPEECH_DISABLED;")
55 cpp_quote("EXTERN_C const GUID GUID_COMPARTMENT_SPEECH_OPENCLOSE;")
56 cpp_quote("EXTERN_C const GUID GUID_COMPARTMENT_SPEECH_GLOBALSTATE;")
57 cpp_quote("EXTERN_C const GUID GUID_COMPARTMENT_PERSISTMENUENABLED;")
58 cpp_quote("EXTERN_C const GUID GUID_COMPARTMENT_EMPTYCONTEXT;")
59 cpp_quote("EXTERN_C const GUID GUID_COMPARTMENT_TIPUISTATUS;")
61 /* GUIDs for Categories */
62 cpp_quote("EXTERN_C const GUID GUID_TFCAT_TIP_KEYBOARD;")
63 cpp_quote("EXTERN_C const GUID GUID_TFCAT_TIP_SPEECH;")
64 cpp_quote("EXTERN_C const GUID GUID_TFCAT_TIP_HANDWRITING;")
65 cpp_quote("EXTERN_C const GUID GUID_TFCAT_DISPLAYATTRIBUTEPROVIDER;")
67 typedef [uuid(7213778c-7bb0-4270-b050-6189ee594e97)] DWORD TfEditCookie;
68 typedef [uuid(de403c21-89fd-4f85-8b87-64584d063fbc)] DWORD TfClientId;
69 typedef [uuid(88a9c478-f3ec-4763-8345-cd9250443f8d)] DWORD TfGuidAtom;
71 cpp_quote("#define TF_MOD_ALT 0x0001")
72 cpp_quote("#define TF_MOD_CONTROL 0x0002")
73 cpp_quote("#define TF_MOD_SHIFT 0x0004")
74 cpp_quote("#define TF_MOD_RALT 0x0008")
75 cpp_quote("#define TF_MOD_RCONTROL 0x0010")
76 cpp_quote("#define TF_MOD_RSHIFT 0x0020")
77 cpp_quote("#define TF_MOD_LALT 0x0040")
78 cpp_quote("#define TF_MOD_LCONTROL 0x0080")
79 cpp_quote("#define TF_MOD_LSHIFT 0x0100")
80 cpp_quote("#define TF_MOD_ON_KEYUP 0x0200")
81 cpp_quote("#define TF_MOD_IGNORE_ALL_MODIFIER 0x0400")
83 cpp_quote("#define TF_PROFILETYPE_INPUTPROCESSOR 0x0001")
84 cpp_quote("#define TF_PROFILETYPE_KEYBOARDLAYOUT 0x0002")
86 cpp_quote("#define TF_IPSINK_FLAG_ACTIVE 0x0001")
88 cpp_quote("#define TF_TMAE_NOACTIVATETIP 0x00000001")
89 cpp_quote("#define TF_TMAE_SECUREMODE 0x00000002")
90 cpp_quote("#define TF_TMAE_UIELEMENTENABLEDONLY 0x00000004")
91 cpp_quote("#define TF_TMAE_COMLESS 0x00000008")
92 cpp_quote("#define TF_TMAE_WOW16 0x00000010")
93 cpp_quote("#define TF_TMAE_NOACTIVATEKEYBOARDLAYOUT 0x00000020")
94 cpp_quote("#define TF_TMAE_CONSOLE 0x00000040")
96 cpp_quote("#define TF_TMF_NOACTIVATETIP TF_TMAE_NOACTIVATETIP")
97 cpp_quote("#define TF_TMF_SECUREMODE TF_TMAE_SECUREMODE")
98 cpp_quote("#define TF_TMF_UIELEMENTENABLEDONLY TF_TMAE_UIELEMENTENABLEDONLY")
99 cpp_quote("#define TF_TMF_COMLESS TF_TMAE_COMLESS")
100 cpp_quote("#define TF_TMF_WOW16 TF_TMAE_WOW16")
101 cpp_quote("#define TF_TMF_CONSOLE TF_TMAE_CONSOLE")
102 cpp_quote("#define TF_TMF_IMMERSIVEMODE 0x40000000")
103 cpp_quote("#define TF_TMF_ACTIVATED 0x80000000")
105 interface ITfDocumentMgr;
106 interface ITfContext;
107 interface IEnumTfDocumentMgrs;
108 interface IEnumTfContexts;
109 interface ITfCompartmentMgr;
110 interface ITfEditSession;
111 interface ITfRange;
112 interface ITfProperty;
113 interface ITfReadOnlyProperty;
114 interface IEnumTfLanguageProfiles;
115 interface ITfCompositionView;
116 interface ITfKeyEventSink;
117 interface ITfPersistentPropertyLoaderACP;
118 interface ITfRangeACP;
120 cpp_quote("#if 0")
121 typedef [uuid(4f5d560f-5ab5-4dde-8c4d-404592857ab0)] UINT_PTR HKL;
122 cpp_quote("#endif")
124 typedef [uuid(e26d9e1d-691e-4f29-90d7-338dcf1f8cef)] struct TF_PERSISTENT_PROPERTY_HEADER_ACP
126 GUID guidType;
127 LONG ichStart;
128 LONG cch;
129 ULONG cb;
130 DWORD dwPrivate;
131 CLSID clsidTIP;
132 } TF_PERSISTENT_PROPERTY_HEADER_ACP;
134 typedef [uuid(e1b5808d-1e46-4c19-84dc-68c5f5978cc8)] struct TF_LANGUAGEPROFILE
136 CLSID clsid;
137 LANGID langid;
138 GUID catid;
139 BOOL fActive;
140 GUID guidProfile;
141 } TF_LANGUAGEPROFILE;
143 typedef [uuid(77c12f95-b783-450d-879f-1cd2362c6521)] struct TF_PRESERVEDKEY
145 UINT uVKey;
146 UINT uModifiers;
147 } TF_PRESERVEDKEY;
149 typedef [uuid(5a886226-ae9a-489b-b991-2b1e25ee59a9)] enum { TF_ANCHOR_START = 0, TF_ANCHOR_END = 1 } TfAnchor;
152 object,
153 uuid(101d6610-0990-11d3-8df0-00105a2799b5),
154 pointer_default(unique)
156 interface ITfFunctionProvider : IUnknown
158 HRESULT GetType(
159 [out] GUID *guid);
161 HRESULT GetDescription(
162 [out] BSTR *desc);
164 HRESULT GetFunction(
165 [in] REFGUID guid,
166 [in] REFIID riid,
167 [out, iid_is(riid)] IUnknown **func);
171 object,
172 uuid(e4b24db0-0990-11d3-8df0-00105a2799b5),
173 pointer_default(unique)
175 interface IEnumTfFunctionProviders : IUnknown
177 HRESULT Clone(
178 [out] IEnumTfFunctionProviders **ret);
180 HRESULT Next(
181 [in] ULONG count,
182 [out, size_is(count), length_is(*fetched)] ITfFunctionProvider **prov,
183 [out] ULONG *fetched);
185 HRESULT Reset();
187 HRESULT Skip(
188 [in] ULONG count);
192 object,
193 uuid(aa80e801-2021-11d2-93e0-0060b067b86e),
194 pointer_default(unique)
196 interface ITfThreadMgr: IUnknown
198 HRESULT Activate(
199 [out] TfClientId *ptid);
201 HRESULT Deactivate();
203 HRESULT CreateDocumentMgr(
204 [out] ITfDocumentMgr **ppdim);
206 HRESULT EnumDocumentMgrs(
207 [out] IEnumTfDocumentMgrs **ppEnum);
209 HRESULT GetFocus(
210 [out] ITfDocumentMgr **ppdimFocus);
212 HRESULT SetFocus(
213 [in] ITfDocumentMgr *pdimFocus);
215 HRESULT AssociateFocus(
216 [in] HWND hwnd,
217 [in, unique] ITfDocumentMgr *pdimNew,
218 [out] ITfDocumentMgr **ppdimPrev);
220 HRESULT IsThreadFocus(
221 [out] BOOL *pfThreadFocus);
223 HRESULT GetFunctionProvider(
224 [in] REFCLSID clsid,
225 [out] ITfFunctionProvider **ppFuncProv);
227 HRESULT EnumFunctionProviders(
228 [out] IEnumTfFunctionProviders **ppEnum);
230 HRESULT GetGlobalCompartment(
231 [out] ITfCompartmentMgr **ppCompMgr);
235 object,
236 uuid(3e90ade3-7594-4cb0-bb58-69628f5f458c),
237 pointer_default(unique)
239 interface ITfThreadMgrEx : ITfThreadMgr
241 HRESULT ActivateEx(
242 [out] TfClientId *id,
243 [in] DWORD flags);
244 HRESULT GetActiveFlags(
245 [out] DWORD *flags);
249 object,
250 uuid(d7540241-f9a1-4364-befc-dbcd2c4395b7),
251 pointer_default(unique)
253 interface ITfCompositionView : IUnknown
255 HRESULT GetOwnerClsid([out] CLSID *pclsid);
257 HRESULT GetRange([out] ITfRange **ppRange);
261 object,
262 uuid(aa80e7f4-2021-11d2-93e0-0060b067b86e),
263 pointer_default(unique)
265 interface ITfDocumentMgr: IUnknown
267 HRESULT CreateContext(
268 [in] TfClientId tidOwner,
269 [in] DWORD dwFlags,
270 [in, unique] IUnknown *punk,
271 [out] ITfContext **ppic,
272 [out] TfEditCookie *pecTextStore);
274 HRESULT Push(
275 [in] ITfContext *pic);
277 const DWORD TF_POPF_ALL = 0x0001;
279 HRESULT Pop(
280 [in] DWORD dwFlags);
282 HRESULT GetTop(
283 [out] ITfContext **ppic);
285 HRESULT GetBase(
286 [out] ITfContext **ppic);
288 HRESULT EnumContexts(
289 [out] IEnumTfContexts **ppEnum);
293 object,
294 uuid(2433bf8e-0f9b-435c-ba2c-180611978c30),
295 pointer_default(unique)
297 interface ITfContextView : IUnknown
299 HRESULT GetRangeFromPoint(
300 [in] TfEditCookie cookie,
301 [in] const POINT *pt,
302 [in] DWORD flags,
303 [out] ITfRange **range);
305 HRESULT GetTextExt(
306 [in] TfEditCookie cookie,
307 [in] ITfRange *range,
308 [out] RECT *rect,
309 [out] BOOL *clipped);
311 HRESULT GetScreenExt(
312 [out] RECT *rect);
314 HRESULT GetWnd(
315 [out] HWND *hwnd);
319 object,
320 uuid(f0c0f8dd-cf38-44e1-bb0f-68cf0d551c78),
321 pointer_default(unique)
323 interface IEnumTfContextViews : IUnknown
325 HRESULT Clone(
326 [out] IEnumTfContextViews **ret);
328 HRESULT Next(
329 [in] ULONG count,
330 [out, size_is(count), length_is(*fetched)] ITfContextView **views,
331 [out] ULONG *fetched);
333 HRESULT Reset();
335 HRESULT Skip(
336 [in] ULONG count);
340 object,
341 uuid(19188cb0-aca9-11d2-afc5-00105a2799b5),
342 pointer_default(unique)
344 interface IEnumTfProperties : IUnknown
346 HRESULT Clone(
347 [out] IEnumTfProperties **ret);
349 HRESULT Next(
350 [in] ULONG count,
351 [out, size_is(count), length_is(*fetched)] ITfProperty **props,
352 [out] ULONG *fetched);
354 HRESULT Reset();
356 HRESULT Skip(
357 [in] ULONG count);
361 object,
362 uuid(463a506d-6992-49d2-9b88-93d55e70bb16),
363 pointer_default(unique)
365 interface ITfRangeBackup : IUnknown
367 HRESULT Restore(
368 [in] TfEditCookie cookie,
369 [in] ITfRange *range);
373 object,
374 uuid(aa80e901-2021-11d2-93e0-0060b067b86e),
375 pointer_default(unique)
377 interface ITextStoreACPServices : IUnknown
379 HRESULT Serialize(
380 [in] ITfProperty *prop,
381 [in] ITfRange *range,
382 [out] TF_PERSISTENT_PROPERTY_HEADER_ACP *header,
383 [in] IStream *stream);
385 HRESULT Unserialize(
386 [in] ITfProperty *prop,
387 [in] const TF_PERSISTENT_PROPERTY_HEADER_ACP *header,
388 [in] IStream *stream,
389 [in] ITfPersistentPropertyLoaderACP *loader);
391 HRESULT ForceLoadProperty(
392 [in] ITfProperty *prop);
394 HRESULT CreateRange(
395 [in] LONG start,
396 [in] LONG end,
397 [out] ITfRangeACP **range);
401 object,
402 uuid(aa80e7fd-2021-11d2-93e0-0060b067b86e),
403 pointer_default(unique)
405 interface ITfContext : IUnknown
407 const DWORD TF_ES_ASYNCDONTCARE = 0x0;
408 const DWORD TF_ES_SYNC = 0x1;
409 const DWORD TF_ES_READ = 0x2;
410 const DWORD TF_ES_READWRITE = 0x6;
411 const DWORD TF_ES_ASYNC = 0x8;
413 HRESULT RequestEditSession(
414 [in] TfClientId tid,
415 [in] ITfEditSession *pes,
416 [in] DWORD dwFlags,
417 [out] HRESULT *phrSession);
419 HRESULT InWriteSession(
420 [in] TfClientId tid,
421 [out] BOOL *pfWriteSession);
423 typedef [uuid(1690be9b-d3e9-49f6-8d8b-51b905af4c43)] enum { TF_AE_NONE, TF_AE_START, TF_AE_END } TfActiveSelEnd;
425 typedef [uuid(36ae42a4-6989-4bdc-b48a-6137b7bf2e42)] struct TF_SELECTIONSTYLE
427 TfActiveSelEnd ase;
428 BOOL fInterimChar;
429 } TF_SELECTIONSTYLE;
431 typedef [uuid(75eb22f2-b0bf-46a8-8006-975a3b6efcf1)] struct TF_SELECTION
433 ITfRange *range;
434 TF_SELECTIONSTYLE style;
435 } TF_SELECTION;
437 const ULONG TF_DEFAULT_SELECTION = TS_DEFAULT_SELECTION;
439 HRESULT GetSelection(
440 [in] TfEditCookie ec,
441 [in] ULONG ulIndex,
442 [in] ULONG ulCount,
443 [out, size_is(ulCount), length_is(*pcFetched)] TF_SELECTION *pSelection,
444 [out] ULONG *pcFetched);
446 HRESULT SetSelection(
447 [in] TfEditCookie ec,
448 [in] ULONG ulCount,
449 [in, size_is(ulCount)] const TF_SELECTION *pSelection);
451 HRESULT GetStart(
452 [in] TfEditCookie ec,
453 [out] ITfRange **ppStart);
455 HRESULT GetEnd(
456 [in] TfEditCookie ec,
457 [out] ITfRange **ppEnd);
459 typedef [uuid(bc7d979a-846a-444d-afef-0a9bfa82b961)] TS_STATUS TF_STATUS;
460 const DWORD TF_SD_READONLY = TS_SD_READONLY;
461 const DWORD TF_SD_LOADING = TS_SD_LOADING;
462 const DWORD TF_SS_DISJOINTSEL = TS_SS_DISJOINTSEL;
463 const DWORD TF_SS_REGIONS = TS_SS_REGIONS;
464 const DWORD TF_SS_TRANSITORY = TS_SS_TRANSITORY;
467 HRESULT GetActiveView(
468 [out] ITfContextView **ppView);
470 HRESULT EnumViews(
471 [out] IEnumTfContextViews **ppEnum);
473 HRESULT GetStatus(
474 [out] TF_STATUS *pdcs);
476 HRESULT GetProperty(
477 [in] REFGUID guidProp,
478 [out] ITfProperty **ppProp);
480 HRESULT GetAppProperty(
481 [in] REFGUID guidProp,
482 [out] ITfReadOnlyProperty **ppProp);
484 HRESULT TrackProperties(
485 [in, size_is(cProp)] const GUID **prgProp,
486 [in] ULONG cProp,
487 [in, size_is(cAppProp)] const GUID **prgAppProp,
488 [in] ULONG cAppProp,
489 [out] ITfReadOnlyProperty **ppProperty);
491 HRESULT EnumProperties(
492 [out] IEnumTfProperties **ppEnum);
494 HRESULT GetDocumentMgr(
495 [out] ITfDocumentMgr **ppDm);
497 HRESULT CreateRangeBackup(
498 [in] TfEditCookie ec,
499 [in] ITfRange *pRange,
500 [out] ITfRangeBackup **ppBackup);
503 const DWORD TF_INVALID_COOKIE = 0xffffffff;
506 object,
507 uuid(4ea48a35-60ae-446f-8fd6-e6a8d82459f7),
508 pointer_default(unique)
510 interface ITfSource : IUnknown
512 HRESULT AdviseSink(
513 [in] REFIID riid,
514 [in, iid_is(riid)] IUnknown *punk,
515 [out] DWORD *pdwCookie);
517 HRESULT UnadviseSink(
518 [in] DWORD dwCookie);
522 object,
523 local,
524 uuid(1F02B6C5-7842-4EE6-8A0B-9A24183A95CA),
525 pointer_default(unique)
527 interface ITfInputProcessorProfiles : IUnknown
529 HRESULT Register(
530 [in] REFCLSID rclsid);
532 HRESULT Unregister(
533 [in] REFCLSID rclsid);
535 HRESULT AddLanguageProfile(
536 [in] REFCLSID rclsid,
537 [in] LANGID langid,
538 [in] REFGUID guidProfile,
539 [in, size_is(cchDesc)] const WCHAR *pchDesc,
540 [in] ULONG cchDesc,
541 [in, size_is(cchFile)] const WCHAR *pchIconFile,
542 [in] ULONG cchFile,
543 [in] ULONG uIconIndex);
545 HRESULT RemoveLanguageProfile(
546 [in] REFCLSID rclsid,
547 [in] LANGID langid,
548 [in] REFGUID guidProfile);
550 HRESULT EnumInputProcessorInfo(
551 [out] IEnumGUID **ppEnum);
553 HRESULT GetDefaultLanguageProfile(
554 [in] LANGID langid,
555 [in] REFGUID catid,
556 [out] CLSID *pclsid,
557 [out] GUID *pguidProfile);
559 HRESULT SetDefaultLanguageProfile(
560 [in] LANGID langid,
561 [in] REFCLSID rclsid,
562 [in] REFGUID guidProfiles);
564 HRESULT ActivateLanguageProfile(
565 [in] REFCLSID rclsid,
566 [in] LANGID langid,
567 [in] REFGUID guidProfiles);
569 HRESULT GetActiveLanguageProfile(
570 [in] REFCLSID rclsid,
571 [out] LANGID *plangid,
572 [out] GUID *pguidProfile);
574 HRESULT GetLanguageProfileDescription(
575 [in] REFCLSID rclsid,
576 [in] LANGID langid,
577 [in] REFGUID guidProfile,
578 [out] BSTR *pbstrProfile);
580 HRESULT GetCurrentLanguage(
581 [out] LANGID *plangid);
583 HRESULT ChangeCurrentLanguage(
584 [in] LANGID langid);
586 HRESULT GetLanguageList(
587 [out] LANGID **ppLangId,
588 [out] ULONG *pulCount);
590 HRESULT EnumLanguageProfiles(
591 [in] LANGID langid,
592 [out] IEnumTfLanguageProfiles **ppEnum);
594 HRESULT EnableLanguageProfile(
595 [in] REFCLSID rclsid,
596 [in] LANGID langid,
597 [in] REFGUID guidProfile,
598 [in] BOOL fEnable);
600 HRESULT IsEnabledLanguageProfile(
601 [in] REFCLSID rclsid,
602 [in] LANGID langid,
603 [in] REFGUID guidProfile,
604 [out] BOOL *pfEnable);
606 HRESULT EnableLanguageProfileByDefault(
607 [in] REFCLSID rclsid,
608 [in] LANGID langid,
609 [in] REFGUID guidProfile,
610 [in] BOOL fEnable);
612 HRESULT SubstituteKeyboardLayout(
613 [in] REFCLSID rclsid,
614 [in] LANGID langid,
615 [in] REFGUID guidProfile,
616 [in] HKL hKL);
619 typedef [uuid(44d2825a-10e5-43b2-877f-6cb2f43b7e7e)]
620 struct TF_INPUTPROCESSORPROFILE {
621 DWORD dwProfileType;
622 LANGID langid;
623 CLSID clsid;
624 GUID guidProfile;
625 GUID catid;
626 HKL hklSubstitute;
627 DWORD dwCaps;
628 HKL hkl;
629 DWORD dwFlags;
630 } TF_INPUTPROCESSORPROFILE;
633 object,
634 uuid(71c6e74d-0f28-11d8-a82a-00065b84435c),
635 pointer_default(unique)
637 interface IEnumTfInputProcessorProfiles : IUnknown
639 HRESULT Clone(
640 [out] IEnumTfInputProcessorProfiles **ppEnum);
642 HRESULT Next(
643 [in] ULONG ulCount,
644 [out, size_is(ulCount), length_is(*pcFetch)] TF_INPUTPROCESSORPROFILE *pProfile,
645 [out] ULONG *pcFetch);
647 HRESULT Reset();
649 HRESULT Skip(
650 [in] ULONG ulCount);
654 object,
655 uuid(71c6e74c-0f28-11d8-a82a-00065b84435c),
656 pointer_default(unique)
658 interface ITfInputProcessorProfileMgr : IUnknown
660 HRESULT ActivateProfile(
661 [in] DWORD dwProfileType,
662 [in] LANGID langid,
663 [in] REFCLSID clsid,
664 [in] REFGUID guidProfile,
665 [in] HKL hkl,
666 [in] DWORD dwFlags);
668 HRESULT DeactivateProfile(
669 [in] DWORD dwProfileType,
670 [in] LANGID langid,
671 [in] REFCLSID clsid,
672 [in] REFGUID guidProfile,
673 [in] HKL hkl,
674 [in] DWORD dwFlags);
676 HRESULT GetProfile(
677 [in] DWORD dwProfileType,
678 [in] LANGID langid,
679 [in] REFCLSID clsid,
680 [in] REFGUID guidProfile,
681 [in] HKL hkl,
682 [out] TF_INPUTPROCESSORPROFILE *pProfile);
685 HRESULT EnumProfiles(
686 [in] LANGID langid,
687 [out] IEnumTfInputProcessorProfiles **ppEnum);
689 HRESULT ReleaseInputProcessor(
690 [in] REFCLSID rclsid,
691 [in] DWORD dwFlags);
693 HRESULT RegisterProfile(
694 [in] REFCLSID rclsid,
695 [in] LANGID langid,
696 [in] REFGUID guidProfile,
697 [in, size_is(cchDesc)] const WCHAR *pchDesc,
698 [in] ULONG cchDesc,
699 [in, size_is(cchFile)] const WCHAR *pchIconFile,
700 [in] ULONG cchFile,
701 [in] ULONG uIconIndex,
702 [in] HKL hklsubstitute,
703 [in] DWORD dwPreferredLayout,
704 [in] BOOL bEnabledByDefault,
705 [in] DWORD dwFlags);
707 HRESULT UnregisterProfile(
708 [in] REFCLSID rclsid,
709 [in] LANGID langid,
710 [in] REFGUID guidProfile,
711 [in] DWORD dwFlags);
713 HRESULT GetActiveProfile(
714 [in] REFGUID catid,
715 [out] TF_INPUTPROCESSORPROFILE *pProfile);
718 typedef [uuid(c4cc07f1-80cc-4a7b-bc54-98512782cbe3)]
719 enum {
720 TF_LS_NONE = 0,
721 TF_LS_SOLID = 1,
722 TF_LS_DOT = 2,
723 TF_LS_DASH = 3,
724 TF_LS_SQUIGGLE = 4
725 } TF_DA_LINESTYLE;
727 typedef [uuid(d9b92e21-084a-401b-9c64-1e6dad91a1ab)]
728 enum {
729 TF_CT_NONE = 0,
730 TF_CT_SYSCOLOR = 1,
731 TF_CT_COLORREF = 2
732 } TF_DA_COLORTYPE;
734 typedef [uuid(90d0cb5e-6520-4a0f-b47c-c39bd955f0d6)]
735 struct TF_DA_COLOR {
736 TF_DA_COLORTYPE type;
737 [switch_type(TF_DA_COLORTYPE), switch_is(type)]
738 union {
739 [case(TF_CT_SYSCOLOR)] int nIndex;
740 [case(TF_CT_COLORREF)] COLORREF cr;
742 } TF_DA_COLOR;
744 typedef [uuid(33d2fe4b-6c24-4f67-8d75-3bc1819e4126)]
745 enum {
746 TF_ATTR_INPUT = 0,
747 TF_ATTR_TARGET_CONVERTED = 1,
748 TF_ATTR_CONVERTED = 2,
749 TF_ATTR_TARGET_NOTCONVERTED = 3,
750 TF_ATTR_INPUT_ERROR = 4,
751 TF_ATTR_FIXEDCONVERTED = 5,
752 TF_ATTR_OTHER = -1
753 } TF_DA_ATTR_INFO;
755 typedef [uuid(1bf1c305-419b-4182-a4d2-9bfadc3f021f)]
756 struct TF_DISPLAYATTRIBUTE {
757 TF_DA_COLOR crText;
758 TF_DA_COLOR crBk;
759 TF_DA_LINESTYLE lsStyle;
760 BOOL fBoldLine;
761 TF_DA_COLOR crLine;
762 TF_DA_ATTR_INFO bAttr;
763 } TF_DISPLAYATTRIBUTE;
766 object,
767 uuid(70528852-2f26-4aea-8c96-215150578932),
768 pointer_default(unique)
770 interface ITfDisplayAttributeInfo : IUnknown
772 HRESULT GetGUID([out] GUID *pguid);
774 HRESULT GetDescription([out] BSTR *pbstrDesc);
776 HRESULT GetAttributeInfo([out] TF_DISPLAYATTRIBUTE *pda);
778 HRESULT SetAttributeInfo([in] const TF_DISPLAYATTRIBUTE *pda);
780 HRESULT Reset();
784 object,
785 uuid(7cef04d7-cb75-4e80-a7ab-5f5bc7d332de),
786 pointer_default(unique)
788 interface IEnumTfDisplayAttributeInfo : IUnknown
790 HRESULT Clone([out] IEnumTfDisplayAttributeInfo **ppEnum);
792 HRESULT Next(
793 [in] ULONG ulCount,
794 [out, size_is(ulCount), length_is(*pcFetched)] ITfDisplayAttributeInfo **rgInfo,
795 [out] ULONG *pcFetched);
797 HRESULT Reset();
799 HRESULT Skip([in] ULONG ulCount);
803 object,
804 local,
805 uuid(8ded7393-5db1-475c-9e71-a39111b0ff67),
806 pointer_default(unique)
808 interface ITfDisplayAttributeMgr : IUnknown
810 HRESULT OnUpdateInfo();
812 HRESULT EnumDisplayAttributeInfo([out] IEnumTfDisplayAttributeInfo **ppEnum);
814 HRESULT GetDisplayAttributeInfo(
815 [in] REFGUID guid,
816 [out] ITfDisplayAttributeInfo **ppInfo,
817 [out] CLSID *pclsidOwner);
822 object,
823 local,
824 uuid(c3acefb5-f69d-4905-938f-fcadcf4be830),
825 pointer_default(unique)
827 interface ITfCategoryMgr : IUnknown
829 HRESULT RegisterCategory([in] REFCLSID rclsid,
830 [in] REFGUID rcatid,
831 [in] REFGUID rguid);
833 HRESULT UnregisterCategory([in] REFCLSID rclsid,
834 [in] REFGUID rcatid,
835 [in] REFGUID rguid);
837 HRESULT EnumCategoriesInItem([in] REFGUID rguid,
838 [out] IEnumGUID **ppEnum);
840 HRESULT EnumItemsInCategory([in] REFGUID rcatid,
841 [out] IEnumGUID **ppEnum);
843 HRESULT FindClosestCategory([in] REFGUID rguid,
844 [out] GUID *pcatid,
845 [in, size_is(ulCount)] const GUID **ppcatidList,
846 [in] ULONG ulCount);
848 HRESULT RegisterGUIDDescription([in] REFCLSID rclsid,
849 [in] REFGUID rguid,
850 [in, size_is(cch)] const WCHAR *pchDesc,
851 [in] ULONG cch);
853 HRESULT UnregisterGUIDDescription([in] REFCLSID rclsid,
854 [in] REFGUID rguid);
856 HRESULT GetGUIDDescription([in] REFGUID rguid,
857 [out] BSTR *pbstrDesc);
859 HRESULT RegisterGUIDDWORD([in] REFCLSID rclsid,
860 [in] REFGUID rguid,
861 [in] DWORD dw);
863 HRESULT UnregisterGUIDDWORD([in] REFCLSID rclsid,
864 [in] REFGUID rguid);
866 HRESULT GetGUIDDWORD([in] REFGUID rguid,
867 [out] DWORD *pdw);
869 HRESULT RegisterGUID([in] REFGUID rguid,
870 [out] TfGuidAtom *pguidatom);
872 HRESULT GetGUID([in] TfGuidAtom guidatom,
873 [out] GUID *pguid);
875 HRESULT IsEqualTfGuidAtom([in] TfGuidAtom guidatom,
876 [in] REFGUID rguid,
877 [out] BOOL *pfEqual);
881 object,
882 uuid(f99d3f40-8e32-11d2-bf46-00105a2799b5),
883 pointer_default(unique)
885 interface IEnumTfRanges : IUnknown
887 HRESULT Clone([out] IEnumTfRanges **ppEnum);
889 HRESULT Next(
890 [in] ULONG ulCount,
891 [out, size_is(ulCount), length_is(*pcFetched)] ITfRange **ppRange,
892 [out] ULONG *pcFetched);
894 HRESULT Reset();
896 HRESULT Skip(ULONG ulCount);
900 object,
901 uuid(42d4d099-7c1a-4a89-b836-6c6f22160df0),
902 pointer_default(unique)
904 interface ITfEditRecord : IUnknown
906 const DWORD TF_GTP_INCL_TEXT = 0x1;
908 HRESULT GetSelectionStatus(
909 [out] BOOL *changed);
911 HRESULT GetTextAndPropertyUpdates(
912 [in] DWORD flags,
913 [in, size_is(count)] const GUID **props,
914 [in] ULONG count,
915 [out] IEnumTfRanges **ret);
919 object,
920 uuid(8127d409-ccd3-4683-967a-b43d5b482bf7),
921 pointer_default(unique)
923 interface ITfTextEditSink : IUnknown
925 HRESULT OnEndEdit(
926 [in] ITfContext *pic,
927 [in] TfEditCookie ecReadOnly,
928 [in] ITfEditRecord *pEditRecord);
932 object,
933 uuid(5F20AA40-B57A-4F34-96AB-3576F377CC79),
934 pointer_default(unique)
936 interface ITfContextOwnerCompositionSink : IUnknown
938 HRESULT OnStartComposition(
939 [in] ITfCompositionView *pComposition,
940 [out] BOOL *pfOk);
942 HRESULT OnUpdateComposition(
943 [in] ITfCompositionView *pComposition,
944 [in] ITfRange *pRangeNew);
946 HRESULT OnEndComposition(
947 [in] ITfCompositionView *pComposition);
951 object,
952 uuid(b246cb75-a93e-4652-bf8c-b3fe0cfd7e57),
953 pointer_default(unique)
955 interface ITfActiveLanguageProfileNotifySink : IUnknown
957 HRESULT OnActivated(
958 [in] REFCLSID clsid,
959 [in] REFGUID guidProfile,
960 [in] BOOL fActivated);
964 object,
965 uuid(3d61bf11-ac5f-42c8-a4cb-931bcc28c744),
966 pointer_default(unique)
968 interface IEnumTfLanguageProfiles : IUnknown
970 HRESULT Clone(
971 [out] IEnumTfLanguageProfiles **ppEnum);
973 HRESULT Next(
974 [in] ULONG ulCount,
975 [out, size_is(ulCount), length_is(*pcFetch)] TF_LANGUAGEPROFILE *pProfile,
976 [out] ULONG *pcFetch);
978 HRESULT Reset();
980 HRESULT Skip(
981 [in] ULONG ulCount);
985 object,
986 local,
987 uuid(aa80e7f7-2021-11d2-93e0-0060b067b86e),
988 pointer_default(unique)
990 interface ITfTextInputProcessor : IUnknown
992 HRESULT Activate(
993 [in] ITfThreadMgr *ptim,
994 [in] TfClientId tid);
996 HRESULT Deactivate();
1000 object,
1001 uuid(aa80e80e-2021-11d2-93e0-0060b067b86e),
1002 pointer_default(unique)
1004 interface ITfThreadMgrEventSink : IUnknown
1006 HRESULT OnInitDocumentMgr(
1007 [in] ITfDocumentMgr *pdim);
1009 HRESULT OnUninitDocumentMgr(
1010 [in] ITfDocumentMgr *pdim);
1012 HRESULT OnSetFocus(
1013 [in] ITfDocumentMgr *pdimFocus,
1014 [in] ITfDocumentMgr *pdimPrevFocus);
1016 HRESULT OnPushContext(
1017 [in] ITfContext *pic);
1019 HRESULT OnPopContext(
1020 [in] ITfContext *pic);
1024 object,
1025 local,
1026 uuid(aa80e7f0-2021-11d2-93e0-0060b067b86e),
1027 pointer_default(unique)
1029 interface ITfKeystrokeMgr : IUnknown
1031 HRESULT AdviseKeyEventSink(
1032 [in] TfClientId tid,
1033 [in] ITfKeyEventSink *pSink,
1034 [in] BOOL fForeground);
1036 HRESULT UnadviseKeyEventSink(
1037 [in] TfClientId tid);
1039 HRESULT GetForeground(
1040 [out] CLSID *pclsid);
1042 HRESULT TestKeyDown(
1043 [in] WPARAM wParam,
1044 [in] LPARAM lParam,
1045 [out] BOOL *pfEaten);
1047 HRESULT TestKeyUp(
1048 [in] WPARAM wParam,
1049 [in] LPARAM lParam,
1050 [out] BOOL *pfEaten);
1052 HRESULT KeyDown(
1053 [in] WPARAM wParam,
1054 [in] LPARAM lParam,
1055 [out] BOOL *pfEaten);
1057 HRESULT KeyUp(
1058 [in] WPARAM wParam,
1059 [in] LPARAM lParam,
1060 [out] BOOL *pfEaten);
1062 HRESULT GetPreservedKey(
1063 [in] ITfContext *pic,
1064 [in] const TF_PRESERVEDKEY *pprekey,
1065 [out] GUID *pguid);
1067 HRESULT IsPreservedKey(
1068 [in] REFGUID rguid,
1069 [in] const TF_PRESERVEDKEY *pprekey,
1070 [out] BOOL *pfRegistered);
1072 HRESULT PreserveKey(
1073 [in] TfClientId tid,
1074 [in] REFGUID rguid,
1075 [in] const TF_PRESERVEDKEY *prekey,
1076 [in, size_is(cchDesc)] const WCHAR *pchDesc,
1077 [in] ULONG cchDesc);
1079 HRESULT UnpreserveKey(
1080 [in] REFGUID rguid,
1081 [in] const TF_PRESERVEDKEY *pprekey);
1083 HRESULT SetPreservedKeyDescription(
1084 [in] REFGUID rguid,
1085 [in, size_is(cchDesc)] const WCHAR *pchDesc,
1086 [in] ULONG cchDesc);
1088 HRESULT GetPreservedKeyDescription(
1089 [in] REFGUID rguid,
1090 [out] BSTR *pbstrDesc);
1092 HRESULT SimulatePreservedKey(
1093 [in] ITfContext *pic,
1094 [in] REFGUID rguid,
1095 [out] BOOL *pfEaten);
1099 object,
1100 local,
1101 uuid(aa80e7f5-2021-11d2-93e0-0060b067b86e),
1102 pointer_default(unique)
1104 interface ITfKeyEventSink : IUnknown
1106 HRESULT OnSetFocus(
1107 [in] BOOL fForeground);
1109 HRESULT OnTestKeyDown(
1110 [in] ITfContext *pic,
1111 [in] WPARAM wParam,
1112 [in] LPARAM lParam,
1113 [out] BOOL *pfEaten);
1115 HRESULT OnTestKeyUp(
1116 [in] ITfContext *pic,
1117 [in] WPARAM wParam,
1118 [in] LPARAM lParam,
1119 [out] BOOL *pfEaten);
1121 HRESULT OnKeyDown(
1122 [in] ITfContext *pic,
1123 [in] WPARAM wParam,
1124 [in] LPARAM lParam,
1125 [out] BOOL *pfEaten);
1127 HRESULT OnKeyUp(
1128 [in] ITfContext *pic,
1129 [in] WPARAM wParam,
1130 [in] LPARAM lParam,
1131 [out] BOOL *pfEaten);
1133 HRESULT OnPreservedKey(
1134 [in] ITfContext *pic,
1135 [in] REFGUID rguid,
1136 [out] BOOL *pfEaten);
1140 object,
1141 local,
1142 uuid(1cd4c13b-1c36-4191-a70a-7f3e611f367d),
1143 pointer_default(unique)
1145 interface ITfKeyTraceEventSink : IUnknown
1147 HRESULT OnKeyTraceDown(
1148 [in] WPARAM wParam,
1149 [in] LPARAM lParam);
1151 HRESULT OnKeyTraceUp(
1152 [in] WPARAM wParam,
1153 [in] LPARAM lParam);
1157 object,
1158 local,
1159 uuid(ea1ea136-19df-11d7-a6d2-00065b84435c),
1160 pointer_default(unique)
1162 interface ITfUIElementSink : IUnknown
1164 HRESULT BeginUIElement(
1165 [in] DWORD id,
1166 [in, out] BOOL *show);
1168 HRESULT UpdateUIElement(
1169 [in] DWORD id);
1171 HRESULT EndUIElement(
1172 [in] DWORD id);
1176 object,
1177 local,
1178 uuid(8f1b8ad8-0b6b-4874-90c5-bd76011e8f7c),
1179 pointer_default(unique)
1181 interface ITfMessagePump : IUnknown
1183 HRESULT PeekMessageA(
1184 [out] LPMSG pMsg,
1185 [in] HWND hwnd,
1186 [in] UINT wMsgFilterMin,
1187 [in] UINT wMsgFilterMax,
1188 [in] UINT wRemoveMsg,
1189 [out] BOOL *pfResult);
1191 HRESULT GetMessageA(
1192 [out] LPMSG pMsg,
1193 [in] HWND hwnd,
1194 [in] UINT wMsgFilterMin,
1195 [in] UINT wMsgFilterMax,
1196 [out] BOOL *pfResult);
1198 HRESULT PeekMessageW(
1199 [out] LPMSG pMsg,
1200 [in] HWND hwnd,
1201 [in] UINT wMsgFilterMin,
1202 [in] UINT wMsgFilterMax,
1203 [in] UINT wRemoveMsg,
1204 [out] BOOL *pfResult);
1206 HRESULT GetMessageW(
1207 [out] LPMSG pMsg,
1208 [in] HWND hwnd,
1209 [in] UINT wMsgFilterMin,
1210 [in] UINT wMsgFilterMax,
1211 [out] BOOL *pfResult);
1215 object,
1216 local,
1217 uuid(d60a7b49-1b9f-4be2-b702-47e9dc05dec3),
1218 pointer_default(unique)
1220 interface ITfClientId : IUnknown
1222 HRESULT GetClientId(
1223 [in] REFCLSID rclsid,
1224 [out] TfClientId *ptid);
1228 object,
1229 uuid(43c9fe15-f494-4c17-9de2-b8a4ac350aa8),
1230 pointer_default(unique)
1232 interface ITfLanguageProfileNotifySink : IUnknown
1234 HRESULT OnLanguageChange(
1235 [in] LANGID langid,
1236 [out] BOOL *pfAccept);
1238 HRESULT OnLanguageChanged();
1242 object,
1243 uuid(aa80e803-2021-11d2-93e0-0060b067b86e),
1244 pointer_default(unique)
1246 interface ITfEditSession : IUnknown
1248 HRESULT DoEditSession(
1249 [in] TfEditCookie ec);
1253 object,
1254 uuid(aa80e7ff-2021-11d2-93e0-0060b067b86e),
1255 pointer_default(unique)
1257 interface ITfRange : IUnknown
1259 const WCHAR TF_CHAR_EMBEDDED = TS_CHAR_EMBEDDED;
1261 typedef [uuid(cf610f06-2882-46f6-abe5-298568b664c4)] enum { TF_GRAVITY_BACKWARD = 0, TF_GRAVITY_FORWARD = 1 } TfGravity;
1263 typedef [uuid(1e512533-bbdc-4530-9a8e-a1dc0af67468)] enum { TF_SD_BACKWARD = 0, TF_SD_FORWARD = 1 } TfShiftDir;
1265 const DWORD TF_HF_OBJECT = 1;
1266 const DWORD TF_TF_MOVESTART = 1;
1267 const DWORD TF_TF_IGNOREEND = 2;
1268 const DWORD TF_ST_CORRECTION = 1;
1269 const DWORD TF_IE_CORRECTION = 1;
1271 typedef [uuid(49930d51-7d93-448c-a48c-fea5dac192b1)] struct TF_HALTCOND
1273 ITfRange *pHaltRange;
1274 TfAnchor aHaltPos;
1275 DWORD dwFlags;
1276 } TF_HALTCOND;
1278 HRESULT GetText(
1279 [in] TfEditCookie ec,
1280 [in] DWORD dwFlags,
1281 [out, size_is(cchMax), length_is(*pcch)] WCHAR *pchText,
1282 [in] ULONG cchMax,
1283 [out] ULONG *pcch);
1285 HRESULT SetText(
1286 [in] TfEditCookie ec,
1287 [in] DWORD dwFlags,
1288 [in, size_is(cch), unique] const WCHAR *pchText,
1289 [in] LONG cch);
1291 HRESULT GetFormattedText(
1292 [in] TfEditCookie ec,
1293 [out] IDataObject **ppDataObject);
1295 HRESULT GetEmbedded(
1296 [in] TfEditCookie ec,
1297 [in] REFGUID rguidService,
1298 [in] REFIID riid,
1299 [out, iid_is(riid)] IUnknown **ppunk);
1301 HRESULT InsertEmbedded(
1302 [in] TfEditCookie ec,
1303 [in] DWORD dwFlags,
1304 [in] IDataObject *pDataObject);
1306 HRESULT ShiftStart(
1307 [in] TfEditCookie ec,
1308 [in] LONG cchReq,
1309 [out] LONG *pcch,
1310 [in, unique] const TF_HALTCOND *pHalt);
1312 HRESULT ShiftEnd(
1313 [in] TfEditCookie ec,
1314 [in] LONG cchReq,
1315 [out] LONG *pcch,
1316 [in, unique] const TF_HALTCOND *pHalt);
1318 HRESULT ShiftStartToRange(
1319 [in] TfEditCookie ec,
1320 [in] ITfRange *pRange,
1321 [in] TfAnchor aPos);
1323 HRESULT ShiftEndToRange(
1324 [in] TfEditCookie ec,
1325 [in] ITfRange *pRange,
1326 [in] TfAnchor aPos);
1328 HRESULT ShiftStartRegion(
1329 [in] TfEditCookie ec,
1330 [in] TfShiftDir dir,
1331 [out] BOOL *pfNoRegion);
1333 HRESULT ShiftEndRegion(
1334 [in] TfEditCookie ec,
1335 [in] TfShiftDir dir,
1336 [out] BOOL *pfNoRegion);
1338 HRESULT IsEmpty(
1339 [in] TfEditCookie ec,
1340 [out] BOOL *pfEmpty);
1342 HRESULT Collapse(
1343 [in] TfEditCookie ec,
1344 [in] TfAnchor aPos);
1346 HRESULT IsEqualStart(
1347 [in] TfEditCookie ec,
1348 [in] ITfRange *pWith,
1349 [in] TfAnchor aPos,
1350 [out] BOOL *pfEqual);
1352 HRESULT IsEqualEnd(
1353 [in] TfEditCookie ec,
1354 [in] ITfRange *pWith,
1355 [in] TfAnchor aPos,
1356 [out] BOOL *pfEqual);
1358 HRESULT CompareStart(
1359 [in] TfEditCookie ec,
1360 [in] ITfRange *pWith,
1361 [in] TfAnchor aPos,
1362 [out] LONG *plResult);
1364 HRESULT CompareEnd(
1365 [in] TfEditCookie ec,
1366 [in] ITfRange *pWith,
1367 [in] TfAnchor aPos,
1368 [out] LONG *plResult);
1370 HRESULT AdjustForInsert(
1371 [in] TfEditCookie ec,
1372 [in] ULONG cchInsert,
1373 [out] BOOL *pfInsertOk);
1375 HRESULT GetGravity(
1376 [out] TfGravity *pgStart,
1377 [out] TfGravity *pgEnd);
1379 HRESULT SetGravity(
1380 [in] TfEditCookie ec,
1381 [in] TfGravity gStart,
1382 [in] TfGravity gEnd);
1384 HRESULT Clone(
1385 [out] ITfRange **ppClone);
1387 HRESULT GetContext(
1388 [out] ITfContext **ppContext);
1392 object,
1393 uuid(057a6296-029b-4154-b79a-0d461d4ea94c),
1394 pointer_default(unique)
1396 interface ITfRangeACP : ITfRange
1398 HRESULT GetExtent([out] LONG *pacpAnchor,
1399 [out] LONG *pcch);
1401 HRESULT SetExtent([in] LONG acpAnchor,
1402 [in] LONG cch);
1406 object,
1407 uuid(55ce16ba-3014-41c1-9ceb-fade1446ac6c),
1408 pointer_default(unique)
1410 interface ITfInsertAtSelection : IUnknown
1412 const DWORD TF_IAS_NOQUERY = 0x1;
1413 const DWORD TF_IAS_QUERYONLY = 0x2;
1414 const DWORD TF_IAS_NO_DEFAULT_COMPOSITION = 0x80000000;
1416 HRESULT InsertTextAtSelection(
1417 [in] TfEditCookie ec,
1418 [in] DWORD dwFlags,
1419 [in, size_is(cch)] const WCHAR *pchText,
1420 [in] LONG cch,
1421 [out] ITfRange **ppRange);
1423 HRESULT InsertEmbeddedAtSelection(
1424 [in] TfEditCookie ec,
1425 [in] DWORD dwFlags,
1426 [in] IDataObject *pDataObject,
1427 [out] ITfRange **ppRange);
1431 object,
1432 uuid(6834b120-88cb-11d2-bf45-00105a2799b5),
1433 pointer_default(unique)
1435 interface ITfPropertyStore : IUnknown
1437 const DWORD TF_TU_CORRECTION = 0x1;
1439 HRESULT GetType([out] GUID *pguid);
1441 HRESULT GetDataType([out] DWORD *pdwReserved);
1443 HRESULT GetData([out] VARIANT *pvarValue);
1445 HRESULT OnTextUpdated(
1446 [in] DWORD dwFlags,
1447 [in] ITfRange *pRangeNew,
1448 [out] BOOL *pfAccept);
1450 HRESULT Shrink(
1451 [in] ITfRange *pRangeNew,
1452 [out] BOOL *pfFree);
1454 HRESULT Divide(
1455 [in] ITfRange *pRangeThis,
1456 [in] ITfRange *pRangeNew,
1457 [out] ITfPropertyStore **ppPropStore);
1459 HRESULT Clone(
1460 [out] ITfPropertyStore **pPropStore);
1462 HRESULT GetPropertyRangeCreator(
1463 [out] CLSID *pclsid);
1465 HRESULT Serialize(
1466 [in] IStream *pStream,
1467 [out] ULONG *pcb);
1471 object,
1472 uuid(5efd22Ba-7838-46cb-88e2-cadb14124f8f),
1473 pointer_default(unique)
1475 interface IEnumITfCompositionView : IUnknown
1477 HRESULT Clone([out] IEnumITfCompositionView **ppEnum);
1479 HRESULT Next(
1480 [in] ULONG ulCount,
1481 [out, size_is(ulCount), length_is(*pcFetched)] ITfCompositionView **rgCompositionView,
1482 [out] ULONG *pcFetched);
1484 HRESULT Reset();
1486 HRESULT Skip([in] ULONG ulCount);
1490 object,
1491 uuid(20168d64-5a8f-4a5a-b7bd-cfa29f4D0fd9),
1492 pointer_default(unique)
1494 interface ITfComposition : IUnknown
1496 HRESULT GetRange([out] ITfRange **ppRange);
1498 HRESULT ShiftStart(
1499 [in] TfEditCookie ecWrite,
1500 [in] ITfRange *pNewStart);
1502 HRESULT ShiftEnd(
1503 [in] TfEditCookie ecWrite,
1504 [in] ITfRange *pNewEnd);
1506 HRESULT EndComposition([in] TfEditCookie ecWrite);
1510 object,
1511 uuid(a781718c-579a-4b15-a280-32b8577acc5e),
1512 pointer_default(unique)
1514 interface ITfCompositionSink : IUnknown
1516 HRESULT OnCompositionTerminated(
1517 [in] TfEditCookie ecWrite,
1518 [in] ITfComposition *pComposition);
1522 object,
1523 uuid(d40C8aae-aC92-4fc7-9a11-0ee0e23aa39b),
1524 pointer_default(unique)
1526 interface ITfContextComposition : IUnknown
1528 HRESULT StartComposition(
1529 [in] TfEditCookie ecWrite,
1530 [in] ITfRange *pCompositionRange,
1531 [in] ITfCompositionSink *pSink,
1532 [out] ITfComposition **ppComposition);
1534 HRESULT EnumCompositions([out] IEnumITfCompositionView **ppEnum);
1536 HRESULT FindComposition(
1537 [in] TfEditCookie ecRead,
1538 [in] ITfRange *pTestRange,
1539 [out] IEnumITfCompositionView **ppEnum);
1541 HRESULT TakeOwnership(
1542 [in] TfEditCookie ecWrite,
1543 [in] ITfCompositionView *pComposition,
1544 [in] ITfCompositionSink *pSink,
1545 [out] ITfComposition **ppComposition);
1549 object,
1550 uuid(86462810-593b-4916-9764-19c08e9ce110),
1551 pointer_default(unique)
1553 interface ITfContextOwnerCompositionServices : ITfContextComposition
1555 HRESULT TerminateComposition([in] ITfCompositionView *pComposition);
1559 object,
1560 uuid(4ef89150-0807-11d3-8df0-00105a2799b5),
1561 pointer_default(unique)
1563 interface ITfPersistentPropertyLoaderACP : IUnknown
1565 HRESULT LoadProperty(
1566 [in] const TF_PERSISTENT_PROPERTY_HEADER_ACP *pHdr,
1567 [out] IStream **ppStream);
1571 object,
1572 uuid(b23eb630-3e1c-11d3-a745-0050040ab407),
1573 pointer_default(unique)
1575 interface ITfContextOwnerServices : IUnknown
1577 HRESULT OnLayoutChange();
1579 HRESULT OnStatusChange([in] DWORD dwFlags);
1581 HRESULT OnAttributeChange([in] REFGUID rguidAttribute);
1583 HRESULT Serialize(
1584 [in] ITfProperty *pProp,
1585 [in] ITfRange *pRange,
1586 [out] TF_PERSISTENT_PROPERTY_HEADER_ACP *pHdr,
1587 [in] IStream *pStream);
1589 HRESULT Unserialize(
1590 [in] ITfProperty *pProp,
1591 [in] const TF_PERSISTENT_PROPERTY_HEADER_ACP *pHdr,
1592 [in] IStream *pStream,
1593 [in] ITfPersistentPropertyLoaderACP *pLoader);
1595 HRESULT ForceLoadProperty([in] ITfProperty *pProp);
1597 HRESULT CreateRange(
1598 [in] LONG acpStart,
1599 [in] LONG acpEnd,
1600 [out] ITfRangeACP **ppRange);
1604 object,
1605 uuid(17d49a3d-f8b8-4b2f-b254-52319dd64c53),
1606 pointer_default(unique)
1608 interface ITfReadOnlyProperty : IUnknown
1610 HRESULT GetType([out] GUID *pguid);
1612 HRESULT EnumRanges(
1613 [in] TfEditCookie ec,
1614 [out] IEnumTfRanges **ppEnum,
1615 [in] ITfRange *pTargetRange);
1617 HRESULT GetValue(
1618 [in] TfEditCookie ec,
1619 [in] ITfRange *pRange,
1620 [out] VARIANT *pvarValue);
1622 HRESULT GetContext([out] ITfContext **ppContext);
1626 object,
1627 uuid(e2449660-9542-11d2-bf46-00105a2799b5),
1628 pointer_default(unique)
1630 interface ITfProperty : ITfReadOnlyProperty
1632 HRESULT FindRange(
1633 [in] TfEditCookie ec,
1634 [in] ITfRange *pRange,
1635 [out] ITfRange **ppRange,
1636 [in] TfAnchor aPos);
1638 HRESULT SetValueStore(
1639 [in] TfEditCookie ec,
1640 [in] ITfRange *pRange,
1641 [in] ITfPropertyStore *pPropStore);
1643 HRESULT SetValue(
1644 [in] TfEditCookie ec,
1645 [in] ITfRange *pRange,
1646 [in] const VARIANT *pvarValue);
1648 HRESULT Clear(
1649 [in] TfEditCookie ec,
1650 [in] ITfRange *pRange);
1654 object,
1655 uuid(bb08f7a9-607a-4384-8623-056892b64371),
1656 pointer_default(unique)
1658 interface ITfCompartment : IUnknown
1660 HRESULT SetValue(
1661 [in] TfClientId tid,
1662 [in] const VARIANT *pvarValue);
1664 HRESULT GetValue(
1665 [out] VARIANT *pvarValue);
1669 object,
1670 uuid(7dcf57ac-18ad-438b-824d-979bffb74b7c),
1671 pointer_default(unique)
1673 interface ITfCompartmentMgr : IUnknown
1675 HRESULT GetCompartment(
1676 [in] REFGUID rguid,
1677 [out] ITfCompartment **ppcomp);
1679 HRESULT ClearCompartment(
1680 [in] TfClientId tid,
1681 [in] REFGUID rguid);
1683 HRESULT EnumCompartments(
1684 [out] IEnumGUID **ppEnum);
1688 object,
1689 uuid(743abd5f-f26d-48df-8cc5-238492419b64),
1690 pointer_default(unique)
1692 interface ITfCompartmentEventSink : IUnknown
1694 HRESULT OnChange(
1695 [in] REFGUID rguid);
1699 object,
1700 uuid(8f1a7ea6-1654-4502-a86e-b2902344d507),
1701 pointer_default(unique)
1703 interface IEnumTfContexts : IUnknown
1705 HRESULT Clone(
1706 [out] IEnumTfContexts **ppEnum);
1708 HRESULT Next(
1709 [in] ULONG ulCount,
1710 [out, size_is(ulCount), length_is(*pcFetched)] ITfContext **rgContext,
1711 [out] ULONG *pcFetched);
1713 HRESULT Reset();
1715 HRESULT Skip(
1716 [in] ULONG ulCount);
1720 object,
1721 uuid(aa80e808-2021-11d2-93e0-0060b067b86e),
1722 pointer_default(unique)
1724 interface IEnumTfDocumentMgrs : IUnknown
1726 HRESULT Clone(
1727 [out] IEnumTfDocumentMgrs **ppEnum);
1729 HRESULT Next(
1730 [in] ULONG ulCount,
1731 [out, size_is(ulCount), length_is(*pcFetched)] ITfDocumentMgr **rgDocumentMgr,
1732 [out] ULONG *pcFetched);
1734 HRESULT Reset();
1736 HRESULT Skip(
1737 [in] ULONG ulCount);
1741 object,
1742 local,
1743 uuid(ea1ea137-19df-11d7-a6d2-00065b84435c),
1744 pointer_default(unique)
1746 interface ITfUIElement : IUnknown
1748 HRESULT GetDescription(
1749 [out] BSTR *description);
1751 HRESULT GetGUID(
1752 [out] GUID *guid);
1754 HRESULT Show(
1755 [in] BOOL show);
1757 HRESULT IsShown(
1758 [out] BOOL *show);
1762 object,
1763 local,
1764 uuid(887aa91e-acba-4931-84da-3c5208cf543f),
1765 pointer_default(unique)
1767 interface IEnumTfUIElements : IUnknown
1769 HRESULT Clone(
1770 [out] IEnumTfUIElements **enum_elements);
1772 HRESULT Next(
1773 [in] ULONG count,
1774 [out, size_is(count), length_is(fetched)] ITfUIElement **element,
1775 [out] ULONG fetched);
1777 HRESULT Reset();
1779 HRESULT Skip(
1780 [in] ULONG count);
1784 object,
1785 local,
1786 uuid(ea1ea135-19df-11d7-a6d2-00065b84435c),
1787 pointer_default(unique)
1789 interface ITfUIElementMgr : IUnknown
1791 HRESULT BeginUIElement(
1792 [in] ITfUIElement *element,
1793 [in, out] BOOL *show,
1794 [out] DWORD *id);
1796 HRESULT UpdateUIElement(
1797 [in] DWORD id);
1799 HRESULT EndUIElement(
1800 [in] DWORD id);
1802 HRESULT GetUIElement(
1803 [in] DWORD id,
1804 [out] ITfUIElement **element);
1806 HRESULT EnumUIElements(
1807 [out] IEnumTfUIElements **enum_elements);
1811 object,
1812 uuid(73131f9c-56a9-49dd-b0ee-d046633f7528),
1813 pointer_default(unique)
1815 interface ITfSourceSingle : IUnknown
1817 HRESULT AdviseSingleSink(
1818 [in] TfClientId tid,
1819 [in] REFIID riid,
1820 [in, iid_is(riid)] IUnknown *punk);
1822 HRESULT UnadviseSingleSink(
1823 [in] TfClientId tid,
1824 [in] REFIID riid);
1828 object,
1829 local,
1830 uuid(c0f1db0c-3a20-405c-a303-96b6010a885f),
1831 pointer_default(unique)
1833 interface ITfThreadFocusSink : IUnknown
1835 HRESULT OnSetThreadFocus();
1837 HRESULT OnKillThreadFocus();
1841 object,
1842 uuid(71c6e74e-0f28-11d8-a82a-00065b84435c),
1843 pointer_default(unique)
1845 interface ITfInputProcessorProfileActivationSink : IUnknown
1847 HRESULT OnActivated(
1848 [in] DWORD dwProfileType,
1849 [in] LANGID langid,
1850 [in] REFCLSID clsid,
1851 [in] REFGUID catid,
1852 [in] REFGUID guidProfile,
1853 [in] HKL hkl,
1854 [in] DWORD dwFlags);
1858 object,
1859 local,
1860 uuid(a1adaaa2-3a24-449d-ac96-5183e7f5c217),
1861 pointer_default(unique)
1863 interface ITfMouseSink : IUnknown
1865 HRESULT OnMouseEvent(
1866 [in] ULONG uEdge,
1867 [in] ULONG uQuadrant,
1868 [in] DWORD dwBtnStatus,
1869 [out] BOOL *pfEaten);
1873 object,
1874 uuid(09d146cd-a544-4132-925b-7afa8ef322d0),
1875 pointer_default(unique)
1877 interface ITfMouseTracker : IUnknown
1879 HRESULT AdviseMouseSink(
1880 [in] ITfRange *range,
1881 [in] ITfMouseSink *pSink,
1882 [out] DWORD *pdwCookie);
1884 HRESULT UnadviseMouseSink([in] DWORD dwCookie);
1888 object,
1889 uuid(3bdd78e2-c16e-47fd-b883-ce6facc1a208),
1890 pointer_default(unique)
1892 interface ITfMouseTrackerACP : IUnknown
1894 HRESULT AdviseMouseSink(
1895 [in] ITfRangeACP *range,
1896 [in] ITfMouseSink *pSink,
1897 [out] DWORD *pdwCookie);
1899 HRESULT UnadviseMouseSink([in] DWORD dwCookie);
1903 object,
1904 local,
1905 uuid(a615096f-1c57-4813-8a15-55ee6e5a839c),
1906 pointer_default(unique)
1908 interface ITfTransitoryExtensionSink : IUnknown
1910 HRESULT OnTransitoryExtensionUpdated(
1911 [in] ITfContext *pic,
1912 [in] TfEditCookie ecReadOnly,
1913 [in] ITfRange *pResultRange,
1914 [in] ITfRange *pCompositionRange,
1915 [out] BOOL *pfDeleteResultRange);