configure: Only check for libgettextpo when explicitly requested.
[wine.git] / include / msctf.idl
blob0cfaacff0dbaa6161fb6dd754bbfddbcd050705e
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 interface ITfDocumentMgr;
89 interface ITfContext;
90 interface IEnumTfDocumentMgrs;
91 interface IEnumTfContexts;
92 interface ITfCompartmentMgr;
93 interface ITfEditSession;
94 interface ITfRange;
95 interface ITfProperty;
96 interface ITfReadOnlyProperty;
97 interface IEnumTfLanguageProfiles;
98 interface ITfCompositionView;
99 interface ITfKeyEventSink;
101 cpp_quote("#if 0")
102 typedef [uuid(4f5d560f-5ab5-4dde-8c4d-404592857ab0)] UINT_PTR HKL;
103 cpp_quote("#endif")
105 typedef [uuid(e26d9e1d-691e-4f29-90d7-338dcf1f8cef)] struct TF_PERSISTENT_PROPERTY_HEADER_ACP
107 GUID guidType;
108 LONG ichStart;
109 LONG cch;
110 ULONG cb;
111 DWORD dwPrivate;
112 CLSID clsidTIP;
113 } TF_PERSISTENT_PROPERTY_HEADER_ACP;
115 typedef [uuid(e1b5808d-1e46-4c19-84dc-68c5f5978cc8)] struct TF_LANGUAGEPROFILE
117 CLSID clsid;
118 LANGID langid;
119 GUID catid;
120 BOOL fActive;
121 GUID guidProfile;
122 } TF_LANGUAGEPROFILE;
124 typedef [uuid(77c12f95-b783-450d-879f-1cd2362c6521)] struct TF_PRESERVEDKEY
126 UINT uVKey;
127 UINT uModifiers;
128 } TF_PRESERVEDKEY;
130 typedef [uuid(5a886226-ae9a-489b-b991-2b1e25ee59a9)] enum { TF_ANCHOR_START = 0, TF_ANCHOR_END = 1 } TfAnchor;
133 object,
134 uuid(101d6610-0990-11d3-8df0-00105a2799b5),
135 pointer_default(unique)
137 interface ITfFunctionProvider : IUnknown
139 HRESULT GetType(
140 [out] GUID *guid);
142 HRESULT GetDescription(
143 [out] BSTR *desc);
145 HRESULT GetFunction(
146 [in] REFGUID guid,
147 [in] REFIID riid,
148 [out, iid_is(riid)] IUnknown **func);
152 object,
153 uuid(e4b24db0-0990-11d3-8df0-00105a2799b5),
154 pointer_default(unique)
156 interface IEnumTfFunctionProviders : IUnknown
158 HRESULT Clone(
159 [out] IEnumTfFunctionProviders **ret);
161 HRESULT Next(
162 [in] ULONG count,
163 [out, size_is(count), length_is(*fetched)] ITfFunctionProvider **prov,
164 [out] ULONG *fetched);
166 HRESULT Reset();
168 HRESULT Skip(
169 [in] ULONG count);
173 object,
174 uuid(aa80e801-2021-11d2-93e0-0060b067b86e),
175 pointer_default(unique)
177 interface ITfThreadMgr: IUnknown
179 HRESULT Activate(
180 [out] TfClientId *ptid);
182 HRESULT Deactivate();
184 HRESULT CreateDocumentMgr(
185 [out] ITfDocumentMgr **ppdim);
187 HRESULT EnumDocumentMgrs(
188 [out] IEnumTfDocumentMgrs **ppEnum);
190 HRESULT GetFocus(
191 [out] ITfDocumentMgr **ppdimFocus);
193 HRESULT SetFocus(
194 [in] ITfDocumentMgr *pdimFocus);
196 HRESULT AssociateFocus(
197 [in] HWND hwnd,
198 [in, unique] ITfDocumentMgr *pdimNew,
199 [out] ITfDocumentMgr **ppdimPrev);
201 HRESULT IsThreadFocus(
202 [out] BOOL *pfThreadFocus);
204 HRESULT GetFunctionProvider(
205 [in] REFCLSID clsid,
206 [out] ITfFunctionProvider **ppFuncProv);
208 HRESULT EnumFunctionProviders(
209 [out] IEnumTfFunctionProviders **ppEnum);
211 HRESULT GetGlobalCompartment(
212 [out] ITfCompartmentMgr **ppCompMgr);
216 object,
217 uuid(3e90ade3-7594-4cb0-bb58-69628f5f458c),
218 pointer_default(unique)
220 interface ITfThreadMgrEx : ITfThreadMgr
222 HRESULT ActivateEx(
223 [out] TfClientId *id,
224 [in] DWORD flags);
225 HRESULT GetActiveFlags(
226 [out] DWORD *flags);
230 object,
231 uuid(d7540241-f9a1-4364-befc-dbcd2c4395b7),
232 pointer_default(unique)
234 interface ITfCompositionView : IUnknown
236 HRESULT GetOwnerClsid([out] CLSID *pclsid);
238 HRESULT GetRange([out] ITfRange **ppRange);
242 object,
243 uuid(aa80e7f4-2021-11d2-93e0-0060b067b86e),
244 pointer_default(unique)
246 interface ITfDocumentMgr: IUnknown
248 HRESULT CreateContext(
249 [in] TfClientId tidOwner,
250 [in] DWORD dwFlags,
251 [in, unique] IUnknown *punk,
252 [out] ITfContext **ppic,
253 [out] TfEditCookie *pecTextStore);
255 HRESULT Push(
256 [in] ITfContext *pic);
258 const DWORD TF_POPF_ALL = 0x0001;
260 HRESULT Pop(
261 [in] DWORD dwFlags);
263 HRESULT GetTop(
264 [out] ITfContext **ppic);
266 HRESULT GetBase(
267 [out] ITfContext **ppic);
269 HRESULT EnumContexts(
270 [out] IEnumTfContexts **ppEnum);
274 object,
275 uuid(2433bf8e-0f9b-435c-ba2c-180611978c30),
276 pointer_default(unique)
278 interface ITfContextView : IUnknown
280 HRESULT GetRangeFromPoint(
281 [in] TfEditCookie cookie,
282 [in] const POINT *pt,
283 [in] DWORD flags,
284 [out] ITfRange **range);
286 HRESULT GetTextExt(
287 [in] TfEditCookie cookie,
288 [in] ITfRange *range,
289 [out] RECT *rect,
290 [out] BOOL *clipped);
292 HRESULT GetScreenExt(
293 [out] RECT *rect);
295 HRESULT GetWnd(
296 [out] HWND *hwnd);
300 object,
301 uuid(f0c0f8dd-cf38-44e1-bb0f-68cf0d551c78),
302 pointer_default(unique)
304 interface IEnumTfContextViews : IUnknown
306 HRESULT Clone(
307 [out] IEnumTfContextViews **ret);
309 HRESULT Next(
310 [in] ULONG count,
311 [out, size_is(count), length_is(*fetched)] ITfContextView **views,
312 [out] ULONG *fetched);
314 HRESULT Reset();
316 HRESULT Skip(
317 [in] ULONG count);
321 object,
322 uuid(19188cb0-aca9-11d2-afc5-00105a2799b5),
323 pointer_default(unique)
325 interface IEnumTfProperties : IUnknown
327 HRESULT Clone(
328 [out] IEnumTfProperties **ret);
330 HRESULT Next(
331 [in] ULONG count,
332 [out, size_is(count), length_is(*fetched)] ITfProperty **props,
333 [out] ULONG *fetched);
335 HRESULT Reset();
337 HRESULT Skip(
338 [in] ULONG count);
342 object,
343 uuid(463a506d-6992-49d2-9b88-93d55e70bb16),
344 pointer_default(unique)
346 interface ITfRangeBackup : IUnknown
348 HRESULT Restore(
349 [in] TfEditCookie cookie,
350 [in] ITfRange *range);
354 object,
355 uuid(aa80e7fd-2021-11d2-93e0-0060b067b86e),
356 pointer_default(unique)
358 interface ITfContext : IUnknown
360 const DWORD TF_ES_ASYNCDONTCARE = 0x0;
361 const DWORD TF_ES_SYNC = 0x1;
362 const DWORD TF_ES_READ = 0x2;
363 const DWORD TF_ES_READWRITE = 0x6;
364 const DWORD TF_ES_ASYNC = 0x8;
366 HRESULT RequestEditSession(
367 [in] TfClientId tid,
368 [in] ITfEditSession *pes,
369 [in] DWORD dwFlags,
370 [out] HRESULT *phrSession);
372 HRESULT InWriteSession(
373 [in] TfClientId tid,
374 [out] BOOL *pfWriteSession);
376 typedef [uuid(1690be9b-d3e9-49f6-8d8b-51b905af4c43)] enum { TF_AE_NONE, TF_AE_START, TF_AE_END } TfActiveSelEnd;
378 typedef [uuid(36ae42a4-6989-4bdc-b48a-6137b7bf2e42)] struct TF_SELECTIONSTYLE
380 TfActiveSelEnd ase;
381 BOOL fInterimChar;
382 } TF_SELECTIONSTYLE;
384 typedef [uuid(75eb22f2-b0bf-46a8-8006-975a3b6efcf1)] struct TF_SELECTION
386 ITfRange *range;
387 TF_SELECTIONSTYLE style;
388 } TF_SELECTION;
390 const ULONG TF_DEFAULT_SELECTION = TS_DEFAULT_SELECTION;
392 HRESULT GetSelection(
393 [in] TfEditCookie ec,
394 [in] ULONG ulIndex,
395 [in] ULONG ulCount,
396 [out, size_is(ulCount), length_is(*pcFetched)] TF_SELECTION *pSelection,
397 [out] ULONG *pcFetched);
399 HRESULT SetSelection(
400 [in] TfEditCookie ec,
401 [in] ULONG ulCount,
402 [in, size_is(ulCount)] const TF_SELECTION *pSelection);
404 HRESULT GetStart(
405 [in] TfEditCookie ec,
406 [out] ITfRange **ppStart);
408 HRESULT GetEnd(
409 [in] TfEditCookie ec,
410 [out] ITfRange **ppEnd);
412 typedef [uuid(bc7d979a-846a-444d-afef-0a9bfa82b961)] TS_STATUS TF_STATUS;
413 const DWORD TF_SD_READONLY = TS_SD_READONLY;
414 const DWORD TF_SD_LOADING = TS_SD_LOADING;
415 const DWORD TF_SS_DISJOINTSEL = TS_SS_DISJOINTSEL;
416 const DWORD TF_SS_REGIONS = TS_SS_REGIONS;
417 const DWORD TF_SS_TRANSITORY = TS_SS_TRANSITORY;
420 HRESULT GetActiveView(
421 [out] ITfContextView **ppView);
423 HRESULT EnumViews(
424 [out] IEnumTfContextViews **ppEnum);
426 HRESULT GetStatus(
427 [out] TF_STATUS *pdcs);
429 HRESULT GetProperty(
430 [in] REFGUID guidProp,
431 [out] ITfProperty **ppProp);
433 HRESULT GetAppProperty(
434 [in] REFGUID guidProp,
435 [out] ITfReadOnlyProperty **ppProp);
437 HRESULT TrackProperties(
438 [in, size_is(cProp)] const GUID **prgProp,
439 [in] ULONG cProp,
440 [in, size_is(cAppProp)] const GUID **prgAppProp,
441 [in] ULONG cAppProp,
442 [out] ITfReadOnlyProperty **ppProperty);
444 HRESULT EnumProperties(
445 [out] IEnumTfProperties **ppEnum);
447 HRESULT GetDocumentMgr(
448 [out] ITfDocumentMgr **ppDm);
450 HRESULT CreateRangeBackup(
451 [in] TfEditCookie ec,
452 [in] ITfRange *pRange,
453 [out] ITfRangeBackup **ppBackup);
456 const DWORD TF_INVALID_COOKIE = 0xffffffff;
459 object,
460 uuid(4ea48a35-60ae-446f-8fd6-e6a8d82459f7),
461 pointer_default(unique)
463 interface ITfSource : IUnknown
465 HRESULT AdviseSink(
466 [in] REFIID riid,
467 [in, iid_is(riid)] IUnknown *punk,
468 [out] DWORD *pdwCookie);
470 HRESULT UnadviseSink(
471 [in] DWORD dwCookie);
475 object,
476 local,
477 uuid(1F02B6C5-7842-4EE6-8A0B-9A24183A95CA),
478 pointer_default(unique)
480 interface ITfInputProcessorProfiles : IUnknown
482 HRESULT Register(
483 [in] REFCLSID rclsid);
485 HRESULT Unregister(
486 [in] REFCLSID rclsid);
488 HRESULT AddLanguageProfile(
489 [in] REFCLSID rclsid,
490 [in] LANGID langid,
491 [in] REFGUID guidProfile,
492 [in, size_is(cchDesc)] const WCHAR *pchDesc,
493 [in] ULONG cchDesc,
494 [in, size_is(cchFile)] const WCHAR *pchIconFile,
495 [in] ULONG cchFile,
496 [in] ULONG uIconIndex);
498 HRESULT RemoveLanguageProfile(
499 [in] REFCLSID rclsid,
500 [in] LANGID langid,
501 [in] REFGUID guidProfile);
503 HRESULT EnumInputProcessorInfo(
504 [out] IEnumGUID **ppEnum);
506 HRESULT GetDefaultLanguageProfile(
507 [in] LANGID langid,
508 [in] REFGUID catid,
509 [out] CLSID *pclsid,
510 [out] GUID *pguidProfile);
512 HRESULT SetDefaultLanguageProfile(
513 [in] LANGID langid,
514 [in] REFCLSID rclsid,
515 [in] REFGUID guidProfiles);
517 HRESULT ActivateLanguageProfile(
518 [in] REFCLSID rclsid,
519 [in] LANGID langid,
520 [in] REFGUID guidProfiles);
522 HRESULT GetActiveLanguageProfile(
523 [in] REFCLSID rclsid,
524 [out] LANGID *plangid,
525 [out] GUID *pguidProfile);
527 HRESULT GetLanguageProfileDescription(
528 [in] REFCLSID rclsid,
529 [in] LANGID langid,
530 [in] REFGUID guidProfile,
531 [out] BSTR *pbstrProfile);
533 HRESULT GetCurrentLanguage(
534 [out] LANGID *plangid);
536 HRESULT ChangeCurrentLanguage(
537 [in] LANGID langid);
539 HRESULT GetLanguageList(
540 [out] LANGID **ppLangId,
541 [out] ULONG *pulCount);
543 HRESULT EnumLanguageProfiles(
544 [in] LANGID langid,
545 [out] IEnumTfLanguageProfiles **ppEnum);
547 HRESULT EnableLanguageProfile(
548 [in] REFCLSID rclsid,
549 [in] LANGID langid,
550 [in] REFGUID guidProfile,
551 [in] BOOL fEnable);
553 HRESULT IsEnabledLanguageProfile(
554 [in] REFCLSID rclsid,
555 [in] LANGID langid,
556 [in] REFGUID guidProfile,
557 [out] BOOL *pfEnable);
559 HRESULT EnableLanguageProfileByDefault(
560 [in] REFCLSID rclsid,
561 [in] LANGID langid,
562 [in] REFGUID guidProfile,
563 [in] BOOL fEnable);
565 HRESULT SubstituteKeyboardLayout(
566 [in] REFCLSID rclsid,
567 [in] LANGID langid,
568 [in] REFGUID guidProfile,
569 [in] HKL hKL);
572 typedef [uuid(44d2825a-10e5-43b2-877f-6cb2f43b7e7e)]
573 struct TF_INPUTPROCESSORPROFILE {
574 DWORD dwProfileType;
575 LANGID langid;
576 CLSID clsid;
577 GUID guidProfile;
578 GUID catid;
579 HKL hklSubstitute;
580 DWORD dwCaps;
581 HKL hkl;
582 DWORD dwFlags;
583 } TF_INPUTPROCESSORPROFILE;
586 object,
587 uuid(71c6e74d-0f28-11d8-a82a-00065b84435c),
588 pointer_default(unique)
590 interface IEnumTfInputProcessorProfiles : IUnknown
592 HRESULT Clone(
593 [out] IEnumTfInputProcessorProfiles **ppEnum);
595 HRESULT Next(
596 [in] ULONG ulCount,
597 [out, size_is(ulCount), length_is(*pcFetch)] TF_INPUTPROCESSORPROFILE *pProfile,
598 [out] ULONG *pcFetch);
600 HRESULT Reset();
602 HRESULT Skip(
603 [in] ULONG ulCount);
607 object,
608 uuid(71c6e74c-0f28-11d8-a82a-00065b84435c),
609 pointer_default(unique)
611 interface ITfInputProcessorProfileMgr : IUnknown
613 HRESULT ActivateProfile(
614 [in] DWORD dwProfileType,
615 [in] LANGID langid,
616 [in] REFCLSID clsid,
617 [in] REFGUID guidProfile,
618 [in] HKL hkl,
619 [in] DWORD dwFlags);
621 HRESULT DeactivateProfile(
622 [in] DWORD dwProfileType,
623 [in] LANGID langid,
624 [in] REFCLSID clsid,
625 [in] REFGUID guidProfile,
626 [in] HKL hkl,
627 [in] DWORD dwFlags);
629 HRESULT GetProfile(
630 [in] DWORD dwProfileType,
631 [in] LANGID langid,
632 [in] REFCLSID clsid,
633 [in] REFGUID guidProfile,
634 [in] HKL hkl,
635 [out] TF_INPUTPROCESSORPROFILE *pProfile);
638 HRESULT EnumProfiles(
639 [in] LANGID langid,
640 [out] IEnumTfInputProcessorProfiles **ppEnum);
642 HRESULT ReleaseInputProcessor(
643 [in] REFCLSID rclsid,
644 [in] DWORD dwFlags);
646 HRESULT RegisterProfile(
647 [in] REFCLSID rclsid,
648 [in] LANGID langid,
649 [in] REFGUID guidProfile,
650 [in, size_is(cchDesc)] const WCHAR *pchDesc,
651 [in] ULONG cchDesc,
652 [in, size_is(cchFile)] const WCHAR *pchIconFile,
653 [in] ULONG cchFile,
654 [in] ULONG uIconIndex,
655 [in] HKL hklsubstitute,
656 [in] DWORD dwPreferredLayout,
657 [in] BOOL bEnabledByDefault,
658 [in] DWORD dwFlags);
660 HRESULT UnregisterProfile(
661 [in] REFCLSID rclsid,
662 [in] LANGID langid,
663 [in] REFGUID guidProfile,
664 [in] DWORD dwFlags);
666 HRESULT GetActiveProfile(
667 [in] REFGUID catid,
668 [out] TF_INPUTPROCESSORPROFILE *pProfile);
671 typedef [uuid(c4cc07f1-80cc-4a7b-bc54-98512782cbe3)]
672 enum {
673 TF_LS_NONE = 0,
674 TF_LS_SOLID = 1,
675 TF_LS_DOT = 2,
676 TF_LS_DASH = 3,
677 TF_LS_SQUIGGLE = 4
678 } TF_DA_LINESTYLE;
680 typedef [uuid(d9b92e21-084a-401b-9c64-1e6dad91a1ab)]
681 enum {
682 TF_CT_NONE = 0,
683 TF_CT_SYSCOLOR = 1,
684 TF_CT_COLORREF = 2
685 } TF_DA_COLORTYPE;
687 typedef [uuid(90d0cb5e-6520-4a0f-b47c-c39bd955f0d6)]
688 struct TF_DA_COLOR {
689 TF_DA_COLORTYPE type;
690 [switch_type(TF_DA_COLORTYPE), switch_is(type)]
691 union {
692 [case(TF_CT_SYSCOLOR)] int nIndex;
693 [case(TF_CT_COLORREF)] COLORREF cr;
695 } TF_DA_COLOR;
697 typedef [uuid(33d2fe4b-6c24-4f67-8d75-3bc1819e4126)]
698 enum {
699 TF_ATTR_INPUT = 0,
700 TF_ATTR_TARGET_CONVERTED = 1,
701 TF_ATTR_CONVERTED = 2,
702 TF_ATTR_TARGET_NOTCONVERTED = 3,
703 TF_ATTR_INPUT_ERROR = 4,
704 TF_ATTR_FIXEDCONVERTED = 5,
705 TF_ATTR_OTHER = -1
706 } TF_DA_ATTR_INFO;
708 typedef [uuid(1bf1c305-419b-4182-a4d2-9bfadc3f021f)]
709 struct TF_DISPLAYATTRIBUTE {
710 TF_DA_COLOR crText;
711 TF_DA_COLOR crBk;
712 TF_DA_LINESTYLE lsStyle;
713 BOOL fBoldLine;
714 TF_DA_COLOR crLine;
715 TF_DA_ATTR_INFO bAttr;
716 } TF_DISPLAYATTRIBUTE;
719 object,
720 uuid(70528852-2f26-4aea-8c96-215150578932),
721 pointer_default(unique)
723 interface ITfDisplayAttributeInfo : IUnknown
725 HRESULT GetGUID([out] GUID *pguid);
727 HRESULT GetDescription([out] BSTR *pbstrDesc);
729 HRESULT GetAttributeInfo([out] TF_DISPLAYATTRIBUTE *pda);
731 HRESULT SetAttributeInfo([in] const TF_DISPLAYATTRIBUTE *pda);
733 HRESULT Reset();
737 object,
738 uuid(7cef04d7-cb75-4e80-a7ab-5f5bc7d332de),
739 pointer_default(unique)
741 interface IEnumTfDisplayAttributeInfo : IUnknown
743 HRESULT Clone([out] IEnumTfDisplayAttributeInfo **ppEnum);
745 HRESULT Next(
746 [in] ULONG ulCount,
747 [out, size_is(ulCount), length_is(*pcFetched)] ITfDisplayAttributeInfo **rgInfo,
748 [out] ULONG *pcFetched);
750 HRESULT Reset();
752 HRESULT Skip([in] ULONG ulCount);
756 object,
757 local,
758 uuid(8ded7393-5db1-475c-9e71-a39111b0ff67),
759 pointer_default(unique)
761 interface ITfDisplayAttributeMgr : IUnknown
763 HRESULT OnUpdateInfo();
765 HRESULT EnumDisplayAttributeInfo([out] IEnumTfDisplayAttributeInfo **ppEnum);
767 HRESULT GetDisplayAttributeInfo(
768 [in] REFGUID guid,
769 [out] ITfDisplayAttributeInfo **ppInfo,
770 [out] CLSID *pclsidOwner);
775 object,
776 local,
777 uuid(c3acefb5-f69d-4905-938f-fcadcf4be830),
778 pointer_default(unique)
780 interface ITfCategoryMgr : IUnknown
782 HRESULT RegisterCategory([in] REFCLSID rclsid,
783 [in] REFGUID rcatid,
784 [in] REFGUID rguid);
786 HRESULT UnregisterCategory([in] REFCLSID rclsid,
787 [in] REFGUID rcatid,
788 [in] REFGUID rguid);
790 HRESULT EnumCategoriesInItem([in] REFGUID rguid,
791 [out] IEnumGUID **ppEnum);
793 HRESULT EnumItemsInCategory([in] REFGUID rcatid,
794 [out] IEnumGUID **ppEnum);
796 HRESULT FindClosestCategory([in] REFGUID rguid,
797 [out] GUID *pcatid,
798 [in, size_is(ulCount)] const GUID **ppcatidList,
799 [in] ULONG ulCount);
801 HRESULT RegisterGUIDDescription([in] REFCLSID rclsid,
802 [in] REFGUID rguid,
803 [in, size_is(cch)] const WCHAR *pchDesc,
804 [in] ULONG cch);
806 HRESULT UnregisterGUIDDescription([in] REFCLSID rclsid,
807 [in] REFGUID rguid);
809 HRESULT GetGUIDDescription([in] REFGUID rguid,
810 [out] BSTR *pbstrDesc);
812 HRESULT RegisterGUIDDWORD([in] REFCLSID rclsid,
813 [in] REFGUID rguid,
814 [in] DWORD dw);
816 HRESULT UnregisterGUIDDWORD([in] REFCLSID rclsid,
817 [in] REFGUID rguid);
819 HRESULT GetGUIDDWORD([in] REFGUID rguid,
820 [out] DWORD *pdw);
822 HRESULT RegisterGUID([in] REFGUID rguid,
823 [out] TfGuidAtom *pguidatom);
825 HRESULT GetGUID([in] TfGuidAtom guidatom,
826 [out] GUID *pguid);
828 HRESULT IsEqualTfGuidAtom([in] TfGuidAtom guidatom,
829 [in] REFGUID rguid,
830 [out] BOOL *pfEqual);
834 object,
835 uuid(f99d3f40-8e32-11d2-bf46-00105a2799b5),
836 pointer_default(unique)
838 interface IEnumTfRanges : IUnknown
840 HRESULT Clone([out] IEnumTfRanges **ppEnum);
842 HRESULT Next(
843 [in] ULONG ulCount,
844 [out, size_is(ulCount), length_is(*pcFetched)] ITfRange **ppRange,
845 [out] ULONG *pcFetched);
847 HRESULT Reset();
849 HRESULT Skip(ULONG ulCount);
853 object,
854 uuid(42d4d099-7c1a-4a89-b836-6c6f22160df0),
855 pointer_default(unique)
857 interface ITfEditRecord : IUnknown
859 const DWORD TF_GTP_INCL_TEXT = 0x1;
861 HRESULT GetSelectionStatus(
862 [out] BOOL *changed);
864 HRESULT GetTextAndPropertyUpdates(
865 [in] DWORD flags,
866 [in, size_is(count)] const GUID **props,
867 [in] ULONG count,
868 [out] IEnumTfRanges **ret);
872 object,
873 uuid(8127d409-ccd3-4683-967a-b43d5b482bf7),
874 pointer_default(unique)
876 interface ITfTextEditSink : IUnknown
878 HRESULT OnEndEdit(
879 [in] ITfContext *pic,
880 [in] TfEditCookie ecReadOnly,
881 [in] ITfEditRecord *pEditRecord);
885 object,
886 uuid(5F20AA40-B57A-4F34-96AB-3576F377CC79),
887 pointer_default(unique)
889 interface ITfContextOwnerCompositionSink : IUnknown
891 HRESULT OnStartComposition(
892 [in] ITfCompositionView *pComposition,
893 [out] BOOL *pfOk);
895 HRESULT OnUpdateComposition(
896 [in] ITfCompositionView *pComposition,
897 [in] ITfRange *pRangeNew);
899 HRESULT OnEndComposition(
900 [in] ITfCompositionView *pComposition);
904 object,
905 uuid(b246cb75-a93e-4652-bf8c-b3fe0cfd7e57),
906 pointer_default(unique)
908 interface ITfActiveLanguageProfileNotifySink : IUnknown
910 HRESULT OnActivated(
911 [in] REFCLSID clsid,
912 [in] REFGUID guidProfile,
913 [in] BOOL fActivated);
917 object,
918 uuid(3d61bf11-ac5f-42c8-a4cb-931bcc28c744),
919 pointer_default(unique)
921 interface IEnumTfLanguageProfiles : IUnknown
923 HRESULT Clone(
924 [out] IEnumTfLanguageProfiles **ppEnum);
926 HRESULT Next(
927 [in] ULONG ulCount,
928 [out, size_is(ulCount), length_is(*pcFetch)] TF_LANGUAGEPROFILE *pProfile,
929 [out] ULONG *pcFetch);
931 HRESULT Reset();
933 HRESULT Skip(
934 [in] ULONG ulCount);
938 object,
939 local,
940 uuid(aa80e7f7-2021-11d2-93e0-0060b067b86e),
941 pointer_default(unique)
943 interface ITfTextInputProcessor : IUnknown
945 HRESULT Activate(
946 [in] ITfThreadMgr *ptim,
947 [in] TfClientId tid);
949 HRESULT Deactivate();
953 object,
954 uuid(aa80e80e-2021-11d2-93e0-0060b067b86e),
955 pointer_default(unique)
957 interface ITfThreadMgrEventSink : IUnknown
959 HRESULT OnInitDocumentMgr(
960 [in] ITfDocumentMgr *pdim);
962 HRESULT OnUninitDocumentMgr(
963 [in] ITfDocumentMgr *pdim);
965 HRESULT OnSetFocus(
966 [in] ITfDocumentMgr *pdimFocus,
967 [in] ITfDocumentMgr *pdimPrevFocus);
969 HRESULT OnPushContext(
970 [in] ITfContext *pic);
972 HRESULT OnPopContext(
973 [in] ITfContext *pic);
977 object,
978 local,
979 uuid(aa80e7f0-2021-11d2-93e0-0060b067b86e),
980 pointer_default(unique)
982 interface ITfKeystrokeMgr : IUnknown
984 HRESULT AdviseKeyEventSink(
985 [in] TfClientId tid,
986 [in] ITfKeyEventSink *pSink,
987 [in] BOOL fForeground);
989 HRESULT UnadviseKeyEventSink(
990 [in] TfClientId tid);
992 HRESULT GetForeground(
993 [out] CLSID *pclsid);
995 HRESULT TestKeyDown(
996 [in] WPARAM wParam,
997 [in] LPARAM lParam,
998 [out] BOOL *pfEaten);
1000 HRESULT TestKeyUp(
1001 [in] WPARAM wParam,
1002 [in] LPARAM lParam,
1003 [out] BOOL *pfEaten);
1005 HRESULT KeyDown(
1006 [in] WPARAM wParam,
1007 [in] LPARAM lParam,
1008 [out] BOOL *pfEaten);
1010 HRESULT KeyUp(
1011 [in] WPARAM wParam,
1012 [in] LPARAM lParam,
1013 [out] BOOL *pfEaten);
1015 HRESULT GetPreservedKey(
1016 [in] ITfContext *pic,
1017 [in] const TF_PRESERVEDKEY *pprekey,
1018 [out] GUID *pguid);
1020 HRESULT IsPreservedKey(
1021 [in] REFGUID rguid,
1022 [in] const TF_PRESERVEDKEY *pprekey,
1023 [out] BOOL *pfRegistered);
1025 HRESULT PreserveKey(
1026 [in] TfClientId tid,
1027 [in] REFGUID rguid,
1028 [in] const TF_PRESERVEDKEY *prekey,
1029 [in, size_is(cchDesc)] const WCHAR *pchDesc,
1030 [in] ULONG cchDesc);
1032 HRESULT UnpreserveKey(
1033 [in] REFGUID rguid,
1034 [in] const TF_PRESERVEDKEY *pprekey);
1036 HRESULT SetPreservedKeyDescription(
1037 [in] REFGUID rguid,
1038 [in, size_is(cchDesc)] const WCHAR *pchDesc,
1039 [in] ULONG cchDesc);
1041 HRESULT GetPreservedKeyDescription(
1042 [in] REFGUID rguid,
1043 [out] BSTR *pbstrDesc);
1045 HRESULT SimulatePreservedKey(
1046 [in] ITfContext *pic,
1047 [in] REFGUID rguid,
1048 [out] BOOL *pfEaten);
1052 object,
1053 local,
1054 uuid(aa80e7f5-2021-11d2-93e0-0060b067b86e),
1055 pointer_default(unique)
1057 interface ITfKeyEventSink : IUnknown
1059 HRESULT OnSetFocus(
1060 [in] BOOL fForeground);
1062 HRESULT OnTestKeyDown(
1063 [in] ITfContext *pic,
1064 [in] WPARAM wParam,
1065 [in] LPARAM lParam,
1066 [out] BOOL *pfEaten);
1068 HRESULT OnTestKeyUp(
1069 [in] ITfContext *pic,
1070 [in] WPARAM wParam,
1071 [in] LPARAM lParam,
1072 [out] BOOL *pfEaten);
1074 HRESULT OnKeyDown(
1075 [in] ITfContext *pic,
1076 [in] WPARAM wParam,
1077 [in] LPARAM lParam,
1078 [out] BOOL *pfEaten);
1080 HRESULT OnKeyUp(
1081 [in] ITfContext *pic,
1082 [in] WPARAM wParam,
1083 [in] LPARAM lParam,
1084 [out] BOOL *pfEaten);
1086 HRESULT OnPreservedKey(
1087 [in] ITfContext *pic,
1088 [in] REFGUID rguid,
1089 [out] BOOL *pfEaten);
1093 object,
1094 local,
1095 uuid(8f1b8ad8-0b6b-4874-90c5-bd76011e8f7c),
1096 pointer_default(unique)
1098 interface ITfMessagePump : IUnknown
1100 HRESULT PeekMessageA(
1101 [out] LPMSG pMsg,
1102 [in] HWND hwnd,
1103 [in] UINT wMsgFilterMin,
1104 [in] UINT wMsgFilterMax,
1105 [in] UINT wRemoveMsg,
1106 [out] BOOL *pfResult);
1108 HRESULT GetMessageA(
1109 [out] LPMSG pMsg,
1110 [in] HWND hwnd,
1111 [in] UINT wMsgFilterMin,
1112 [in] UINT wMsgFilterMax,
1113 [out] BOOL *pfResult);
1115 HRESULT PeekMessageW(
1116 [out] LPMSG pMsg,
1117 [in] HWND hwnd,
1118 [in] UINT wMsgFilterMin,
1119 [in] UINT wMsgFilterMax,
1120 [in] UINT wRemoveMsg,
1121 [out] BOOL *pfResult);
1123 HRESULT GetMessageW(
1124 [out] LPMSG pMsg,
1125 [in] HWND hwnd,
1126 [in] UINT wMsgFilterMin,
1127 [in] UINT wMsgFilterMax,
1128 [out] BOOL *pfResult);
1132 object,
1133 local,
1134 uuid(d60a7b49-1b9f-4be2-b702-47e9dc05dec3),
1135 pointer_default(unique)
1137 interface ITfClientId : IUnknown
1139 HRESULT GetClientId(
1140 [in] REFCLSID rclsid,
1141 [out] TfClientId *ptid);
1145 object,
1146 uuid(43c9fe15-f494-4c17-9de2-b8a4ac350aa8),
1147 pointer_default(unique)
1149 interface ITfLanguageProfileNotifySink : IUnknown
1151 HRESULT OnLanguageChange(
1152 [in] LANGID langid,
1153 [out] BOOL *pfAccept);
1155 HRESULT OnLanguageChanged();
1159 object,
1160 uuid(aa80e803-2021-11d2-93e0-0060b067b86e),
1161 pointer_default(unique)
1163 interface ITfEditSession : IUnknown
1165 HRESULT DoEditSession(
1166 [in] TfEditCookie ec);
1170 object,
1171 uuid(aa80e7ff-2021-11d2-93e0-0060b067b86e),
1172 pointer_default(unique)
1174 interface ITfRange : IUnknown
1176 const WCHAR TF_CHAR_EMBEDDED = TS_CHAR_EMBEDDED;
1178 typedef [uuid(cf610f06-2882-46f6-abe5-298568b664c4)] enum { TF_GRAVITY_BACKWARD = 0, TF_GRAVITY_FORWARD = 1 } TfGravity;
1180 typedef [uuid(1e512533-bbdc-4530-9a8e-a1dc0af67468)] enum { TF_SD_BACKWARD = 0, TF_SD_FORWARD = 1 } TfShiftDir;
1182 const DWORD TF_HF_OBJECT = 1;
1183 const DWORD TF_TF_MOVESTART = 1;
1184 const DWORD TF_TF_IGNOREEND = 2;
1185 const DWORD TF_ST_CORRECTION = 1;
1186 const DWORD TF_IE_CORRECTION = 1;
1188 typedef [uuid(49930d51-7d93-448c-a48c-fea5dac192b1)] struct TF_HALTCOND
1190 ITfRange *pHaltRange;
1191 TfAnchor aHaltPos;
1192 DWORD dwFlags;
1193 } TF_HALTCOND;
1195 HRESULT GetText(
1196 [in] TfEditCookie ec,
1197 [in] DWORD dwFlags,
1198 [out, size_is(cchMax), length_is(*pcch)] WCHAR *pchText,
1199 [in] ULONG cchMax,
1200 [out] ULONG *pcch);
1202 HRESULT SetText(
1203 [in] TfEditCookie ec,
1204 [in] DWORD dwFlags,
1205 [in, size_is(cch), unique] const WCHAR *pchText,
1206 [in] LONG cch);
1208 HRESULT GetFormattedText(
1209 [in] TfEditCookie ec,
1210 [out] IDataObject **ppDataObject);
1212 HRESULT GetEmbedded(
1213 [in] TfEditCookie ec,
1214 [in] REFGUID rguidService,
1215 [in] REFIID riid,
1216 [out, iid_is(riid)] IUnknown **ppunk);
1218 HRESULT InsertEmbedded(
1219 [in] TfEditCookie ec,
1220 [in] DWORD dwFlags,
1221 [in] IDataObject *pDataObject);
1223 HRESULT ShiftStart(
1224 [in] TfEditCookie ec,
1225 [in] LONG cchReq,
1226 [out] LONG *pcch,
1227 [in, unique] const TF_HALTCOND *pHalt);
1229 HRESULT ShiftEnd(
1230 [in] TfEditCookie ec,
1231 [in] LONG cchReq,
1232 [out] LONG *pcch,
1233 [in, unique] const TF_HALTCOND *pHalt);
1235 HRESULT ShiftStartToRange(
1236 [in] TfEditCookie ec,
1237 [in] ITfRange *pRange,
1238 [in] TfAnchor aPos);
1240 HRESULT ShiftEndToRange(
1241 [in] TfEditCookie ec,
1242 [in] ITfRange *pRange,
1243 [in] TfAnchor aPos);
1245 HRESULT ShiftStartRegion(
1246 [in] TfEditCookie ec,
1247 [in] TfShiftDir dir,
1248 [out] BOOL *pfNoRegion);
1250 HRESULT ShiftEndRegion(
1251 [in] TfEditCookie ec,
1252 [in] TfShiftDir dir,
1253 [out] BOOL *pfNoRegion);
1255 HRESULT IsEmpty(
1256 [in] TfEditCookie ec,
1257 [out] BOOL *pfEmpty);
1259 HRESULT Collapse(
1260 [in] TfEditCookie ec,
1261 [in] TfAnchor aPos);
1263 HRESULT IsEqualStart(
1264 [in] TfEditCookie ec,
1265 [in] ITfRange *pWith,
1266 [in] TfAnchor aPos,
1267 [out] BOOL *pfEqual);
1269 HRESULT IsEqualEnd(
1270 [in] TfEditCookie ec,
1271 [in] ITfRange *pWith,
1272 [in] TfAnchor aPos,
1273 [out] BOOL *pfEqual);
1275 HRESULT CompareStart(
1276 [in] TfEditCookie ec,
1277 [in] ITfRange *pWith,
1278 [in] TfAnchor aPos,
1279 [out] LONG *plResult);
1281 HRESULT CompareEnd(
1282 [in] TfEditCookie ec,
1283 [in] ITfRange *pWith,
1284 [in] TfAnchor aPos,
1285 [out] LONG *plResult);
1287 HRESULT AdjustForInsert(
1288 [in] TfEditCookie ec,
1289 [in] ULONG cchInsert,
1290 [out] BOOL *pfInsertOk);
1292 HRESULT GetGravity(
1293 [out] TfGravity *pgStart,
1294 [out] TfGravity *pgEnd);
1296 HRESULT SetGravity(
1297 [in] TfEditCookie ec,
1298 [in] TfGravity gStart,
1299 [in] TfGravity gEnd);
1301 HRESULT Clone(
1302 [out] ITfRange **ppClone);
1304 HRESULT GetContext(
1305 [out] ITfContext **ppContext);
1309 object,
1310 uuid(057a6296-029b-4154-b79a-0d461d4ea94c),
1311 pointer_default(unique)
1313 interface ITfRangeACP : ITfRange
1315 HRESULT GetExtent([out] LONG *pacpAnchor,
1316 [out] LONG *pcch);
1318 HRESULT SetExtent([in] LONG acpAnchor,
1319 [in] LONG cch);
1323 object,
1324 uuid(55ce16ba-3014-41c1-9ceb-fade1446ac6c),
1325 pointer_default(unique)
1327 interface ITfInsertAtSelection : IUnknown
1329 const DWORD TF_IAS_NOQUERY = 0x1;
1330 const DWORD TF_IAS_QUERYONLY = 0x2;
1331 const DWORD TF_IAS_NO_DEFAULT_COMPOSITION = 0x80000000;
1333 HRESULT InsertTextAtSelection(
1334 [in] TfEditCookie ec,
1335 [in] DWORD dwFlags,
1336 [in, size_is(cch)] const WCHAR *pchText,
1337 [in] LONG cch,
1338 [out] ITfRange **ppRange);
1340 HRESULT InsertEmbeddedAtSelection(
1341 [in] TfEditCookie ec,
1342 [in] DWORD dwFlags,
1343 [in] IDataObject *pDataObject,
1344 [out] ITfRange **ppRange);
1348 object,
1349 uuid(6834b120-88cb-11d2-bf45-00105a2799b5),
1350 pointer_default(unique)
1352 interface ITfPropertyStore : IUnknown
1354 const DWORD TF_TU_CORRECTION = 0x1;
1356 HRESULT GetType([out] GUID *pguid);
1358 HRESULT GetDataType([out] DWORD *pdwReserved);
1360 HRESULT GetData([out] VARIANT *pvarValue);
1362 HRESULT OnTextUpdated(
1363 [in] DWORD dwFlags,
1364 [in] ITfRange *pRangeNew,
1365 [out] BOOL *pfAccept);
1367 HRESULT Shrink(
1368 [in] ITfRange *pRangeNew,
1369 [out] BOOL *pfFree);
1371 HRESULT Divide(
1372 [in] ITfRange *pRangeThis,
1373 [in] ITfRange *pRangeNew,
1374 [out] ITfPropertyStore **ppPropStore);
1376 HRESULT Clone(
1377 [out] ITfPropertyStore **pPropStore);
1379 HRESULT GetPropertyRangeCreator(
1380 [out] CLSID *pclsid);
1382 HRESULT Serialize(
1383 [in] IStream *pStream,
1384 [out] ULONG *pcb);
1388 object,
1389 uuid(5efd22Ba-7838-46cb-88e2-cadb14124f8f),
1390 pointer_default(unique)
1392 interface IEnumITfCompositionView : IUnknown
1394 HRESULT Clone([out] IEnumITfCompositionView **ppEnum);
1396 HRESULT Next(
1397 [in] ULONG ulCount,
1398 [out, size_is(ulCount), length_is(*pcFetched)] ITfCompositionView **rgCompositionView,
1399 [out] ULONG *pcFetched);
1401 HRESULT Reset();
1403 HRESULT Skip([in] ULONG ulCount);
1407 object,
1408 uuid(20168d64-5a8f-4a5a-b7bd-cfa29f4D0fd9),
1409 pointer_default(unique)
1411 interface ITfComposition : IUnknown
1413 HRESULT GetRange([out] ITfRange **ppRange);
1415 HRESULT ShiftStart(
1416 [in] TfEditCookie ecWrite,
1417 [in] ITfRange *pNewStart);
1419 HRESULT ShiftEnd(
1420 [in] TfEditCookie ecWrite,
1421 [in] ITfRange *pNewEnd);
1423 HRESULT EndComposition([in] TfEditCookie ecWrite);
1427 object,
1428 uuid(a781718c-579a-4b15-a280-32b8577acc5e),
1429 pointer_default(unique)
1431 interface ITfCompositionSink : IUnknown
1433 HRESULT OnCompositionTerminated(
1434 [in] TfEditCookie ecWrite,
1435 [in] ITfComposition *pComposition);
1439 object,
1440 uuid(d40C8aae-aC92-4fc7-9a11-0ee0e23aa39b),
1441 pointer_default(unique)
1443 interface ITfContextComposition : IUnknown
1445 HRESULT StartComposition(
1446 [in] TfEditCookie ecWrite,
1447 [in] ITfRange *pCompositionRange,
1448 [in] ITfCompositionSink *pSink,
1449 [out] ITfComposition **ppComposition);
1451 HRESULT EnumCompositions([out] IEnumITfCompositionView **ppEnum);
1453 HRESULT FindComposition(
1454 [in] TfEditCookie ecRead,
1455 [in] ITfRange *pTestRange,
1456 [out] IEnumITfCompositionView **ppEnum);
1458 HRESULT TakeOwnership(
1459 [in] TfEditCookie ecWrite,
1460 [in] ITfCompositionView *pComposition,
1461 [in] ITfCompositionSink *pSink,
1462 [out] ITfComposition **ppComposition);
1466 object,
1467 uuid(86462810-593b-4916-9764-19c08e9ce110),
1468 pointer_default(unique)
1470 interface ITfContextOwnerCompositionServices : ITfContextComposition
1472 HRESULT TerminateComposition([in] ITfCompositionView *pComposition);
1476 object,
1477 uuid(4ef89150-0807-11d3-8df0-00105a2799b5),
1478 pointer_default(unique)
1480 interface ITfPersistentPropertyLoaderACP : IUnknown
1482 HRESULT LoadProperty(
1483 [in] const TF_PERSISTENT_PROPERTY_HEADER_ACP *pHdr,
1484 [out] IStream **ppStream);
1488 object,
1489 uuid(b23eb630-3e1c-11d3-a745-0050040ab407),
1490 pointer_default(unique)
1492 interface ITfContextOwnerServices : IUnknown
1494 HRESULT OnLayoutChange();
1496 HRESULT OnStatusChange([in] DWORD dwFlags);
1498 HRESULT OnAttributeChange([in] REFGUID rguidAttribute);
1500 HRESULT Serialize(
1501 [in] ITfProperty *pProp,
1502 [in] ITfRange *pRange,
1503 [out] TF_PERSISTENT_PROPERTY_HEADER_ACP *pHdr,
1504 [in] IStream *pStream);
1506 HRESULT Unserialize(
1507 [in] ITfProperty *pProp,
1508 [in] const TF_PERSISTENT_PROPERTY_HEADER_ACP *pHdr,
1509 [in] IStream *pStream,
1510 [in] ITfPersistentPropertyLoaderACP *pLoader);
1512 HRESULT ForceLoadProperty([in] ITfProperty *pProp);
1514 HRESULT CreateRange(
1515 [in] LONG acpStart,
1516 [in] LONG acpEnd,
1517 [out] ITfRangeACP **ppRange);
1521 object,
1522 uuid(17d49a3d-f8b8-4b2f-b254-52319dd64c53),
1523 pointer_default(unique)
1525 interface ITfReadOnlyProperty : IUnknown
1527 HRESULT GetType([out] GUID *pguid);
1529 HRESULT EnumRanges(
1530 [in] TfEditCookie ec,
1531 [out] IEnumTfRanges **ppEnum,
1532 [in] ITfRange *pTargetRange);
1534 HRESULT GetValue(
1535 [in] TfEditCookie ec,
1536 [in] ITfRange *pRange,
1537 [out] VARIANT *pvarValue);
1539 HRESULT GetContext([out] ITfContext **ppContext);
1543 object,
1544 uuid(e2449660-9542-11d2-bf46-00105a2799b5),
1545 pointer_default(unique)
1547 interface ITfProperty : ITfReadOnlyProperty
1549 HRESULT FindRange(
1550 [in] TfEditCookie ec,
1551 [in] ITfRange *pRange,
1552 [out] ITfRange **ppRange,
1553 [in] TfAnchor aPos);
1555 HRESULT SetValueStore(
1556 [in] TfEditCookie ec,
1557 [in] ITfRange *pRange,
1558 [in] ITfPropertyStore *pPropStore);
1560 HRESULT SetValue(
1561 [in] TfEditCookie ec,
1562 [in] ITfRange *pRange,
1563 [in] const VARIANT *pvarValue);
1565 HRESULT Clear(
1566 [in] TfEditCookie ec,
1567 [in] ITfRange *pRange);
1571 object,
1572 uuid(bb08f7a9-607a-4384-8623-056892b64371),
1573 pointer_default(unique)
1575 interface ITfCompartment : IUnknown
1577 HRESULT SetValue(
1578 [in] TfClientId tid,
1579 [in] const VARIANT *pvarValue);
1581 HRESULT GetValue(
1582 [out] VARIANT *pvarValue);
1586 object,
1587 uuid(7dcf57ac-18ad-438b-824d-979bffb74b7c),
1588 pointer_default(unique)
1590 interface ITfCompartmentMgr : IUnknown
1592 HRESULT GetCompartment(
1593 [in] REFGUID rguid,
1594 [out] ITfCompartment **ppcomp);
1596 HRESULT ClearCompartment(
1597 [in] TfClientId tid,
1598 [in] REFGUID rguid);
1600 HRESULT EnumCompartments(
1601 [out] IEnumGUID **ppEnum);
1605 object,
1606 uuid(743abd5f-f26d-48df-8cc5-238492419b64),
1607 pointer_default(unique)
1609 interface ITfCompartmentEventSink : IUnknown
1611 HRESULT OnChange(
1612 [in] REFGUID rguid);
1616 object,
1617 uuid(8f1a7ea6-1654-4502-a86e-b2902344d507),
1618 pointer_default(unique)
1620 interface IEnumTfContexts : IUnknown
1622 HRESULT Clone(
1623 [out] IEnumTfContexts **ppEnum);
1625 HRESULT Next(
1626 [in] ULONG ulCount,
1627 [out, size_is(ulCount), length_is(*pcFetched)] ITfContext **rgContext,
1628 [out] ULONG *pcFetched);
1630 HRESULT Reset();
1632 HRESULT Skip(
1633 [in] ULONG ulCount);
1637 object,
1638 uuid(aa80e808-2021-11d2-93e0-0060b067b86e),
1639 pointer_default(unique)
1641 interface IEnumTfDocumentMgrs : IUnknown
1643 HRESULT Clone(
1644 [out] IEnumTfDocumentMgrs **ppEnum);
1646 HRESULT Next(
1647 [in] ULONG ulCount,
1648 [out, size_is(ulCount), length_is(*pcFetched)] ITfDocumentMgr **rgDocumentMgr,
1649 [out] ULONG *pcFetched);
1651 HRESULT Reset();
1653 HRESULT Skip(
1654 [in] ULONG ulCount);
1658 object,
1659 local,
1660 uuid(ea1ea137-19df-11d7-a6d2-00065b84435c),
1661 pointer_default(unique)
1663 interface ITfUIElement : IUnknown
1665 HRESULT GetDescription(
1666 [out] BSTR *description);
1668 HRESULT GetGUID(
1669 [out] GUID *guid);
1671 HRESULT Show(
1672 [in] BOOL show);
1674 HRESULT IsShown(
1675 [out] BOOL *show);
1679 object,
1680 local,
1681 uuid(887aa91e-acba-4931-84da-3c5208cf543f),
1682 pointer_default(unique)
1684 interface IEnumTfUIElements : IUnknown
1686 HRESULT Clone(
1687 [out] IEnumTfUIElements **enum_elements);
1689 HRESULT Next(
1690 [in] ULONG count,
1691 [out, size_is(count), length_is(fetched)] ITfUIElement **element,
1692 [out] ULONG fetched);
1694 HRESULT Reset();
1696 HRESULT Skip(
1697 [in] ULONG count);
1701 object,
1702 local,
1703 uuid(ea1ea135-19df-11d7-a6d2-00065b84435c),
1704 pointer_default(unique)
1706 interface ITfUIElementMgr : IUnknown
1708 HRESULT BeginUIElement(
1709 [in] ITfUIElement *element,
1710 [in, out] BOOL *show,
1711 [out] DWORD *id);
1713 HRESULT UpdateUIElement(
1714 [in] DWORD id);
1716 HRESULT EndUIElement(
1717 [in] DWORD id);
1719 HRESULT GetUIElement(
1720 [in] DWORD id,
1721 [out] ITfUIElement **element);
1723 HRESULT EnumUIElements(
1724 [out] IEnumTfUIElements **enum_elements);
1728 object,
1729 uuid(73131f9c-56a9-49dd-b0ee-d046633f7528),
1730 pointer_default(unique)
1732 interface ITfSourceSingle : IUnknown
1734 HRESULT AdviseSingleSink(
1735 [in] TfClientId tid,
1736 [in] REFIID riid,
1737 [in, iid_is(riid)] IUnknown *punk);
1739 HRESULT UnadviseSingleSink(
1740 [in] TfClientId tid,
1741 [in] REFIID riid);
1745 object,
1746 local,
1747 uuid(c0f1db0c-3a20-405c-a303-96b6010a885f),
1748 pointer_default(unique)
1750 interface ITfThreadFocusSink : IUnknown
1752 HRESULT OnSetThreadFocus();
1754 HRESULT OnKillThreadFocus();
1758 object,
1759 uuid(71c6e74e-0f28-11d8-a82a-00065b84435c),
1760 pointer_default(unique)
1762 interface ITfInputProcessorProfileActivationSink : IUnknown
1764 HRESULT OnActivated(
1765 [in] DWORD dwProfileType,
1766 [in] LANGID langid,
1767 [in] REFCLSID clsid,
1768 [in] REFGUID catid,
1769 [in] REFGUID guidProfile,
1770 [in] HKL hkl,
1771 [in] DWORD dwFlags);
1775 object,
1776 local,
1777 uuid(a1adaaa2-3a24-449d-ac96-5183e7f5c217),
1778 pointer_default(unique)
1780 interface ITfMouseSink : IUnknown
1782 HRESULT OnMouseEvent(
1783 [in] ULONG uEdge,
1784 [in] ULONG uQuadrant,
1785 [in] DWORD dwBtnStatus,
1786 [out] BOOL *pfEaten);
1790 object,
1791 uuid(09d146cd-a544-4132-925b-7afa8ef322d0),
1792 pointer_default(unique)
1794 interface ITfMouseTracker : IUnknown
1796 HRESULT AdviseMouseSink(
1797 [in] ITfRange *range,
1798 [in] ITfMouseSink *pSink,
1799 [out] DWORD *pdwCookie);
1801 HRESULT UnadviseMouseSink([in] DWORD dwCookie);
1805 object,
1806 uuid(3bdd78e2-c16e-47fd-b883-ce6facc1a208),
1807 pointer_default(unique)
1809 interface ITfMouseTrackerACP : IUnknown
1811 HRESULT AdviseMouseSink(
1812 [in] ITfRangeACP *range,
1813 [in] ITfMouseSink *pSink,
1814 [out] DWORD *pdwCookie);
1816 HRESULT UnadviseMouseSink([in] DWORD dwCookie);