Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1666 lines
44 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1992-1999.
  5. //
  6. // File: mscandui.idl
  7. //
  8. // Contents: UIM declarations.
  9. //
  10. //
  11. //--------------------------------------------------------------------------
  12. cpp_quote("//=--------------------------------------------------------------------------=")
  13. cpp_quote("// mscandui.h")
  14. cpp_quote("")
  15. cpp_quote("")
  16. cpp_quote("// UIM declarations.")
  17. cpp_quote("")
  18. cpp_quote("//=--------------------------------------------------------------------------=")
  19. cpp_quote("// (C) Copyright 1995-1999 Microsoft Corporation. All Rights Reserved.")
  20. cpp_quote("//")
  21. cpp_quote("// THIS CODE AND INFORMATION IS PROVIDED \"AS IS\" WITHOUT WARRANTY OF")
  22. cpp_quote("// ANY KIND, EITHER EXPRESSED OR TFPLIED, INCLUDING BUT NOT LIMITED TO")
  23. cpp_quote("// THE TFPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A")
  24. cpp_quote("// PARTICULAR PURPOSE.")
  25. cpp_quote("//=--------------------------------------------------------------------------=")
  26. cpp_quote("")
  27. cpp_quote("#ifndef MSCANDUI_DEFINED")
  28. cpp_quote("#define MSCANDUI_DEFINED")
  29. cpp_quote("")
  30. cpp_quote("#include <windows.h>")
  31. cpp_quote("")
  32. import "oaidl.idl";
  33. import "msctf.idl";
  34. import "ctffunc.idl";
  35. // =-------------------------------------------------------------------------=
  36. //
  37. // T Y P E D E F I N I T I O N
  38. //
  39. // =-------------------------------------------------------------------------=
  40. /* Logical Font */
  41. #define LF_FACESIZE 32
  42. cpp_quote( "#ifndef _WINGDI_")
  43. typedef [uuid(b02357f0-f5c7-4ffa-91f5-8c0fb8ba4256)] struct LOGFONTA
  44. {
  45. LONG lfHeight;
  46. LONG lfWidth;
  47. LONG lfEscapement;
  48. LONG lfOrientation;
  49. LONG lfWeight;
  50. BYTE lfItalic;
  51. BYTE lfUnderline;
  52. BYTE lfStrikeOut;
  53. BYTE lfCharSet;
  54. BYTE lfOutPrecision;
  55. BYTE lfClipPrecision;
  56. BYTE lfQuality;
  57. BYTE lfPitchAndFamily;
  58. CHAR lfFaceName[LF_FACESIZE];
  59. } LOGFONTA;
  60. typedef [uuid(22fe0f52-31fd-4959-9101-25f07148b7b5)] struct LOGFONTW
  61. {
  62. LONG lfHeight;
  63. LONG lfWidth;
  64. LONG lfEscapement;
  65. LONG lfOrientation;
  66. LONG lfWeight;
  67. BYTE lfItalic;
  68. BYTE lfUnderline;
  69. BYTE lfStrikeOut;
  70. BYTE lfCharSet;
  71. BYTE lfOutPrecision;
  72. BYTE lfClipPrecision;
  73. BYTE lfQuality;
  74. BYTE lfPitchAndFamily;
  75. WCHAR lfFaceName[LF_FACESIZE];
  76. } LOGFONTW;
  77. #ifdef UNICODE
  78. typedef [uuid(2d8938c1-6125-4bff-9ed9-e91479afe8b5)] LOGFONTW LOGFONT;
  79. #else
  80. typedef [uuid(41a50afb-8c61-4900-a3e1-e13b602b91bb)] LOGFONTA LOGFONT;
  81. #endif // UNICODE
  82. cpp_quote( "#endif")
  83. //
  84. // CandidateUI color type
  85. //
  86. // CANDUICOL_DEFAULT ........... default color
  87. // CANDUICOL_SYSTEM ............ system color
  88. // CANDUICOL_COLORREF .......... color ref
  89. //
  90. typedef [uuid(73636d07-a343-4875-82dd-da74bc27c70b)] enum {
  91. CANDUICOL_DEFAULT = 0,
  92. CANDUICOL_SYSTEM = 1,
  93. CANDUICOL_COLORREF = 2
  94. } CANDUICOLORTYPE;
  95. //
  96. // CandidateUI color
  97. //
  98. // type ........................ color type
  99. // nIndex ...................... system color index
  100. // (CANDUICOL_SYSTEM)
  101. // cr .......................... color ref
  102. // (CANDUICOL_COLORREF)
  103. //
  104. typedef [uuid(a39152b2-8124-484c-a313-985a799ed78b)] struct CANDUICOLOR
  105. {
  106. CANDUICOLORTYPE type;
  107. [switch_type(CANDUICOLORTYPE), switch_is(type)] union {
  108. [case(CANDUICOL_SYSTEM)] int nIndex;
  109. [case(CANDUICOL_COLORREF)] COLORREF cr;
  110. };
  111. } CANDUICOLOR;
  112. //
  113. // CandidateUI raw data type
  114. //
  115. // CANDUIRDT_STRING ............ string data
  116. // CANDUIRDT_BITMAP ............ bitmap data
  117. // CANDUIRDT_METAFILE .......... enhanced-format metafile data
  118. //
  119. typedef [uuid(e918b745-7267-4849-bf67-4206ffdef009)] enum {
  120. CANDUIRDT_STRING = 0,
  121. CANDUIRDT_BITMAP = 1,
  122. CANDUIRDT_METAFILE = 2,
  123. } CANDUIRAWDATATYPE;
  124. //
  125. // CandidateUI raw data information
  126. //
  127. // type ........................ raw data type
  128. // bstr ........................ string data
  129. // (CANDUIRDT_STRING)
  130. // hbmp ........................ bitmap data
  131. // (CANDUIRDT_BITMAP)
  132. // hemf ........................ enhanced-format metafile data
  133. // (CANDUIRDT_METAFILE)
  134. //
  135. typedef [uuid(530658a8-9297-4098-acdd-4e3980badf73)] struct CANDUIRAWDATA
  136. {
  137. CANDUIRAWDATATYPE type;
  138. [switch_type(CANDUIRAWDATATYPE), switch_is(type)] union {
  139. [case(CANDUIRDT_STRING)] BSTR bstr;
  140. [case(CANDUIRDT_BITMAP)] HBITMAP hbmp;
  141. [case(CANDUIRDT_METAFILE)] HENHMETAFILE hemf;
  142. };
  143. } CANDUIRAWDATA;
  144. //
  145. // CandidateUI UI direction
  146. //
  147. // CANDUIDIR_TOPTOBOTTOM ........ Horizontal list - top to bottom
  148. // CANDUIDIR_BOTTOMTOTOP ........ Horizontal list - bottom to top
  149. // CANDUIDIR_RIGHTTOLEFT ........ Vertical list - right to left
  150. // CANDUIDIR_LEFTTORIGHT ........ Vertical list - left to right
  151. //
  152. typedef [uuid(296fd808-e8e1-4f70-8440-5fe312c8c0c8)] enum {
  153. CANDUIDIR_TOPTOBOTTOM = 0,
  154. CANDUIDIR_RIGHTTOLEFT = 1,
  155. CANDUIDIR_BOTTOMTOTOP = 2,
  156. CANDUIDIR_LEFTTORIGHT = 3
  157. } CANDUIUIDIRECTION;
  158. //
  159. // CandidateUI UI style
  160. //
  161. // CANDUISTY_LIST .............. apply vertical listbox style to CandidateUI.
  162. // (KK style)
  163. // CANDUISTY_ROW ............... apply horizontal row style to CandidateUI.
  164. // (CHS style)
  165. //
  166. typedef [uuid(b382f954-0602-4865-90b8-379f361c157c)] enum {
  167. CANDUISTY_LIST = 0,
  168. CANDUISTY_ROW = 1,
  169. } CANDUISTYLE;
  170. //
  171. // CandidateUI UI option
  172. //
  173. // CANDUIOPT_ENABLETHEME ....... enable rendaering with theme API
  174. //
  175. const DWORD CANDUIOPT_ENABLETHEME = 0x00000001;
  176. //
  177. // CandidateUI command
  178. //
  179. // Command ID Command Parameter of command
  180. // ---------------------------------------------------------------------------------------------
  181. // CANDUICMD_NONE .............. none (invalid) n/a (must be 0)
  182. // CANDUICMD_NOP ............... no operation n/a (must be 0)
  183. // CANDUICMD_COMPLETE .......... complete w/ current selection n/a (must be 0)
  184. // CANDUICMD_CANCEL ............ cancel n/a (must be 0)
  185. // CANDUICMD_SELECTITEM ........ select item candidate string index
  186. // CANDUICMD_SELECTLINE ........ select n-th line line numder (valid:1-9)
  187. // CANDUICMD_MOVESELNEXT ....... move selection to next item n/a (must be 0)
  188. // CANDUICMD_MOVESELPREV ....... move selection to previous item n/a (must be 0)
  189. // CANDUICMD_MOVESELNEXTPG ..... move selection to next page n/a (must be 0)
  190. // CANDUICMD_MOVESELPREVPG ..... move selection to previous page n/a (must be 0)
  191. // CANDUICMD_MOVESELFIRST ...... move selection to first item n/a (must be 0)
  192. // CANDUICMD_MOVESELLAST ....... move selection to last item n/a (must be 0)
  193. // CANDUICMD_MOVESELUP ......... move selection up (dir) n/a (must be 0)
  194. // CANDUICMD_MOVESELDOWN ....... move selection down (dir) n/a (must be 0)
  195. // CANDUICMD_MOVESELLEFT ....... move selection left (dir) n/a (must be 0)
  196. // CANDUICMD_MOVESELRIGHT ...... move selection right (dir) n/a (must be 0)
  197. // CANDUICMD_OPENCANDMENU ...... open candidate menu n/a (must be 0)
  198. // CANDUICMD_SELECTRAWDATA ..... select rawdata (if exist) n/a (must be 0)
  199. // CANDUICMD_SELECTEXTRACAND ... select extra candidate (if exist) n/a (must be 0)
  200. //
  201. typedef [uuid(86ca05b3-7976-4eb5-a293-6e896e200cc6)] enum {
  202. CANDUICMD_NONE = (-1),
  203. CANDUICMD_NOP = 0,
  204. CANDUICMD_COMPLETE = 1,
  205. CANDUICMD_CANCEL = 2,
  206. CANDUICMD_SELECTITEM = 3,
  207. CANDUICMD_SELECTLINE = 4,
  208. CANDUICMD_MOVESELNEXT = 5,
  209. CANDUICMD_MOVESELPREV = 6,
  210. CANDUICMD_MOVESELNEXTPG = 7,
  211. CANDUICMD_MOVESELPREVPG = 8,
  212. CANDUICMD_MOVESELFIRST = 9,
  213. CANDUICMD_MOVESELLAST = 10,
  214. CANDUICMD_MOVESELUP = 11,
  215. CANDUICMD_MOVESELDOWN = 12,
  216. CANDUICMD_MOVESELLEFT = 13,
  217. CANDUICMD_MOVESELRIGHT = 14,
  218. CANDUICMD_OPENCANDMENU = 15,
  219. CANDUICMD_SELECTRAWDATA = 16,
  220. CANDUICMD_SELECTEXTRACAND = 17,
  221. } CANDUICOMMAND;
  222. //
  223. // CandidateUI key data flag
  224. //
  225. // CANDUIKEY_VKEY .............. key is defined in VKey
  226. // CANDUIKEY_SHIFT ............. key has combination with shift key
  227. // CANDUIKEY_NOSHIFT ........... key has no combination with shift key
  228. // CANDUIKEY_CTRL .............. key has combination with ctrl key
  229. // CANDUIKEY_NOCTRL ............ key has no combination with ctrl key
  230. // CANDUIKEY_RELATIVEDIR ....... key direction is relative on UI direction
  231. // (will be rotated automatically)
  232. // CANDUIKEY_CHAR .............. key is defined in character
  233. //
  234. // * if both of CANDUIKEY_SHIFT and CANDUIKEY_NOSHIFT is specified,
  235. // key doesn't matter about shift key state.
  236. // * if both of CANDUIKEY_CTRL and CANDUIKEY_NOCTRL is specified,
  237. // key doesn't matter about ctrl key state.
  238. //
  239. const DWORD CANDUIKEY_VKEY = 0x00000000;
  240. const DWORD CANDUIKEY_SHIFT = 0x00000001;
  241. const DWORD CANDUIKEY_NOSHIFT = 0x00000002;
  242. const DWORD CANDUIKEY_CTRL = 0x00000004;
  243. const DWORD CANDUIKEY_NOCTRL = 0x00000008;
  244. const DWORD CANDUIKEY_RELATIVEDIR = 0x00000010;
  245. const DWORD CANDUIKEY_CHAR = 0xFFFFFFFF;
  246. //
  247. // CandidateUI key data
  248. //
  249. // dwFlag ...................... key data flag
  250. // uiKey ....................... key
  251. // cmd ......................... CandidateUI command
  252. // uiParam ..................... command paramater
  253. //
  254. typedef [uuid(ffa2c2aa-bbbc-45ca-b3c6-39823e92296a)] struct CANDUIKEYDATA
  255. {
  256. DWORD dwFlag;
  257. UINT uiKey;
  258. CANDUICOMMAND cmd;
  259. UINT uiParam;
  260. } CANDUIKEYDATA;
  261. //
  262. // CandidateUI filtering string type
  263. //
  264. // CANDUIFST_COMPLETE ........... whole candidate string of filtering
  265. // result (= determined + undetermined)
  266. // CANDUIFST_DETERMINED ......... string that user typed
  267. // CANDUIFST_UNDETERMINED ....... string that probably coming after
  268. // the string user typed
  269. //
  270. typedef [uuid(b164a6e5-fd2c-4fb6-b31d-086fa6da183d)] enum {
  271. CANDUIFST_COMPLETE = 0,
  272. CANDUIFST_DETERMINED = 1,
  273. CANDUIFST_UNDETERMINED = 2
  274. } CANDUIFILTERSTR;
  275. //
  276. // CandidateUI filtering event
  277. //
  278. // CANDUIFEV_ENABLED ............ start filtering mode
  279. // CANDUIFEV_DISABLED ........... end filtering mode
  280. // CANDUIFEV_UPDATED ............ filtering string has been updated
  281. // CANDUIFEV_ADDCHARTOFILTER..... Ask the client if it wants to handle this character
  282. // when this char is going to add to filter string.
  283. //
  284. typedef [uuid(971c2ef2-fa8a-4423-831f-da979c52ddd4)] enum {
  285. CANDUIFEV_ENABLED = 0,
  286. CANDUIFEV_DISABLED = 1,
  287. CANDUIFEV_UPDATED = 2,
  288. CANDUIFEV_NONMATCH = 3
  289. } CANDUIFILTEREVENT;
  290. //
  291. // CandidateUI sort event
  292. //
  293. // CANDUISEV_SORTED ............. candidate list has sorted
  294. // CANDUISEV_RESTORED ........... candidate list has restored (unsorted)
  295. //
  296. typedef [uuid(b5f63c6a-d188-4f7b-a9fd-a15c738912fd)] enum {
  297. CANDUISEV_SORTED = 0,
  298. CANDUISEV_RESTORED = 1,
  299. } CANDUISORTEVENT;
  300. //
  301. // CandidateUI string extra info flag
  302. //
  303. // CANDUISTR_HASINLINECOMMENT ... candidate string has inline comment
  304. // CANDUISTR_HASPOPUPCOMMENT .... candidate string has popup comment
  305. // CANDUISTR_HASCOLOR ........... candidate string has color
  306. // CANDUISTR_HASFIXTURE ......... candidate string has prefix/suffix string
  307. // CANDUISTR_HASICON ............ candidate string has icon
  308. //
  309. const DWORD CANDUISTR_HASINLINECOMMENT = 0x00000001;
  310. const DWORD CANDUISTR_HASPOPUPCOMMENT = 0x00000002;
  311. const DWORD CANDUISTR_HASCOLOR = 0x00000004;
  312. const DWORD CANDUISTR_HASFIXTURE = 0x00000008;
  313. const DWORD CANDUISTR_HASICON = 0x00000010;
  314. // =-------------------------------------------------------------------------=
  315. //
  316. // I N T E R F A C E D E F I N I T I O N
  317. //
  318. // =-------------------------------------------------------------------------=
  319. //
  320. // ITfCandidateStringFlag
  321. // - candidate string extra info : flag
  322. // - implemented by TIPs
  323. //
  324. [
  325. object,
  326. uuid(91114c09-1fb3-4771-9701-74fd18e1309a),
  327. pointer_default(unique)
  328. ]
  329. interface ITfCandidateStringFlag : IUnknown
  330. {
  331. //
  332. // ITfCandidateStringFlag method
  333. // - get flag of candidate string extra info
  334. //
  335. HRESULT GetFlag([out] DWORD *pdwFlag);
  336. };
  337. //
  338. // ITfCandidateStringInlineComment
  339. // - candidate string extra info : inline comment
  340. // - implemented by TIPs
  341. [
  342. object,
  343. uuid(a55119cc-fed4-49de-85b2-b6b55f26b00f),
  344. pointer_default(unique)
  345. ]
  346. interface ITfCandidateStringInlineComment : IUnknown
  347. {
  348. //
  349. // GetInlineCommentString method
  350. // - get inline comment string
  351. //
  352. HRESULT GetInlineCommentString([out] BSTR *pbstr);
  353. };
  354. //
  355. // ITfCandidateStringPopupComment
  356. // - candidate string extra info : popup comment
  357. // - implemented by TIPs
  358. [
  359. object,
  360. uuid(66d2ab70-d46c-4543-a4a9-c68b00b43b4c),
  361. pointer_default(unique)
  362. ]
  363. interface ITfCandidateStringPopupComment : IUnknown
  364. {
  365. //
  366. // GetPopupCommentString method
  367. // - get popup comment string
  368. //
  369. HRESULT GetPopupCommentString([out] BSTR *pbstr);
  370. //
  371. // GetPopupCommentGroupID method
  372. // - get popup comment group ID
  373. //
  374. HRESULT GetPopupCommentGroupID([out] DWORD *pdwGroupID);
  375. };
  376. //
  377. // ITfCandidateStringColor
  378. // - candidate string extra info : color
  379. // - implemented by TIPs
  380. [
  381. object,
  382. uuid(43fb8eee-ff1c-42a1-810c-77201df6717e),
  383. pointer_default(unique)
  384. ]
  385. interface ITfCandidateStringColor : IUnknown
  386. {
  387. //
  388. // GetColor method
  389. // - get candidate item color
  390. //
  391. HRESULT GetColor([out] CANDUICOLOR *pcol);
  392. };
  393. //
  394. // ITfCandidateStringFixture
  395. // - candidate string extra info : fixture
  396. // - implemented by TIPs
  397. [
  398. object,
  399. uuid(b85c0208-4fec-418c-85d0-c62ad29a092b),
  400. pointer_default(unique)
  401. ]
  402. interface ITfCandidateStringFixture : IUnknown
  403. {
  404. //
  405. // GetPrefixString method
  406. // - get prefix string
  407. //
  408. HRESULT GetPrefixString([out] BSTR *pbstr);
  409. //
  410. // GetSuffixString method
  411. // - get suffix string
  412. //
  413. HRESULT GetSuffixString([out] BSTR *pbstr);
  414. };
  415. //
  416. // ITfCandidateStringIcon
  417. // - candidate string extra info : icon
  418. // - implemented by TIPs
  419. [
  420. object,
  421. uuid(46275059-c606-41b0-aac8-c8aa48b82998),
  422. pointer_default(unique)
  423. ]
  424. interface ITfCandidateStringIcon : IUnknown
  425. {
  426. //
  427. // GetIcon method
  428. // - get icon of candidate item
  429. //
  430. HRESULT GetIcon([out] HICON *phIcon);
  431. };
  432. //
  433. // ITfCandidateListRawData
  434. // - candidate list extra info : raw data
  435. // - implemented by TIPs
  436. //
  437. [
  438. object,
  439. uuid(cdd01281-8228-45a0-9b55-cc44c2a2a091),
  440. pointer_default(unique)
  441. ]
  442. interface ITfCandidateListRawData : IUnknown
  443. {
  444. //
  445. // GetRawData method
  446. // - get raw data about candidate list
  447. //
  448. HRESULT GetRawData([out] CANDUIRAWDATA *prd);
  449. //
  450. // GetRawDataIndex method
  451. // - get index of candidate list raw data
  452. //
  453. HRESULT GetRawDataIndex([out] ULONG *pnIndex);
  454. };
  455. //
  456. // ITfCandidateListExtraCandidate
  457. // - candidate list extra info : extra candidate string
  458. // - implemented by TIPs
  459. //
  460. [
  461. object,
  462. uuid(85bbeeb5-ba64-411e-abb3-ed379275fab4),
  463. pointer_default(unique)
  464. ]
  465. interface ITfCandidateListExtraCandidate : IUnknown
  466. {
  467. //
  468. // GetExtraCandidate method
  469. // - get extra candidate item
  470. //
  471. HRESULT GetExtraCandidate([out] ITfCandidateString **ppCand);
  472. };
  473. //
  474. // ITfOptionsCandidateList
  475. //
  476. [
  477. object,
  478. uuid(605133F7-758D-42fc-A3FE-10146A7D52F9),
  479. pointer_default(unique)
  480. ]
  481. interface ITfOptionsCandidateList : IUnknown
  482. {
  483. HRESULT EnumOptionsCandidates([out] IEnumTfCandidates **ppEnum);
  484. HRESULT GetOptionsCandidate([in] ULONG nIndex,
  485. [out] ITfCandidateString **ppCand);
  486. HRESULT GetOptionsCandidateNum([out] ULONG *pnCnt);
  487. HRESULT SetOptionsResult([in] ULONG nIndex,
  488. [in] TfCandidateResult imcr);
  489. }
  490. //
  491. // ITfCandidateListTip
  492. // - candidate list extra info : extra candidate string
  493. // - implemented by TIPs
  494. //
  495. [
  496. object,
  497. uuid(c28a9c90-16b1-4064-a190-0b9e5f592539),
  498. pointer_default(unique)
  499. ]
  500. interface ITfCandidateListTip : IUnknown
  501. {
  502. //
  503. // GetTipString method
  504. // - get candidate list tip string
  505. //
  506. HRESULT GetTipString([out] BSTR *pbstr);
  507. };
  508. //
  509. // ITfCandUIKeyTable
  510. // - candidate ui keyboard command table
  511. // - Implemented by TIPs and MSCANDUI.DLL
  512. //
  513. [
  514. object,
  515. uuid(4f9d0bca-c834-4a46-8def-b7544671d602),
  516. pointer_default(unique)
  517. ]
  518. interface ITfCandUIKeyTable : IUnknown
  519. {
  520. //
  521. // GetKeyDataNum method
  522. // - get number of keydata
  523. //
  524. HRESULT GetKeyDataNum([out] int *pnCnt);
  525. //
  526. // GetKeyData method
  527. // - get keydata
  528. //
  529. HRESULT GetKeyData([in] int iKeyData, [out] CANDUIKEYDATA *pKeyData);
  530. };
  531. //
  532. // ITfCandUIMenuExtension
  533. // - CandidateUI menu extension
  534. // - Implemented by MSCANDUI.DLL
  535. //
  536. [
  537. object,
  538. uuid(6875610e-8912-44c6-bcab-48c6cff915e3),
  539. pointer_default(unique)
  540. ]
  541. interface ITfCandUIMenuExtension : IUnknown
  542. {
  543. //
  544. // SetFont method
  545. // - set font of menu
  546. //
  547. HRESULT SetFont([in] LOGFONTW *pLogFont);
  548. //
  549. // GetFont method
  550. // - get font of menu
  551. //
  552. HRESULT GetFont([out] LOGFONTW *pLogFont);
  553. };
  554. //
  555. // ITfCandUIMenuEventSink
  556. // - callback functions for candidate menu events.
  557. // - Implemented by TIPs.
  558. //
  559. [
  560. object,
  561. uuid(944f237e-f03b-4bb9-b8f3-7afa51582d1a),
  562. pointer_default(unique)
  563. ]
  564. interface ITfCandUIMenuEventSink : IUnknown
  565. {
  566. //
  567. // InitMenu method
  568. // - callback to initialize candidate menu
  569. //
  570. HRESULT InitMenu([in] ITfMenu *pMenu);
  571. //
  572. // OnMenuCommand method
  573. // - callback on menu command event
  574. //
  575. HRESULT OnMenuCommand([in] UINT uiCmd);
  576. };
  577. //
  578. // ITfCandUIAutoFilterEventSink
  579. // - callback functions for auto filter events
  580. // - Implemented by TIPs.
  581. //
  582. [
  583. object,
  584. uuid(28ae3d7b-c38f-4efa-aedb-f8cacc1b7422),
  585. pointer_default(unique)
  586. ]
  587. interface ITfCandUIAutoFilterEventSink : IUnknown
  588. {
  589. //
  590. // OnFilterEvent method
  591. // - callback on filter event
  592. //
  593. HRESULT OnFilterEvent([in] CANDUIFILTEREVENT ev);
  594. };
  595. //
  596. // ITfCandUISortEventSink
  597. // - callback functions for sort events.
  598. // - Implemented by TIPs.
  599. //
  600. [
  601. object,
  602. uuid(212d4632-58aa-433e-9aea-67a2efe70cb9),
  603. pointer_default(unique)
  604. ]
  605. interface ITfCandUISortEventSink : IUnknown
  606. {
  607. //
  608. // OnSortEvent method
  609. // - callback on sort event
  610. //
  611. HRESULT OnSortEvent([in] CANDUISORTEVENT ev);
  612. //
  613. // CompareItem method
  614. // - compare item procedure for custom sorting
  615. //
  616. HRESULT CompareItem([in] ITfCandidateString *pCand1, [in] ITfCandidateString *pCand2, [out] LONG *plResult);
  617. };
  618. //
  619. // ITfCandUIExtButtonEventSink
  620. // - callback functions for button extension events.
  621. // - Implemented by TIPs.
  622. //
  623. [
  624. object,
  625. uuid(5c0fb534-1c7e-48c2-908f-008566c1cbb0),
  626. pointer_default(unique)
  627. ]
  628. interface ITfCandUIExtButtonEventSink : IUnknown
  629. {
  630. //
  631. // OnButtonPressed method
  632. // - callback on button event
  633. //
  634. HRESULT OnButtonPushed([in] LONG id);
  635. };
  636. //
  637. // ITfCandUIFnAutoFilter
  638. // - CandidateUI function : auto filtering
  639. // - Implemented by MSCANDUI.DLL
  640. //
  641. [
  642. object,
  643. uuid(499394ab-67c3-48a5-a45c-5080509e0ffb),
  644. pointer_default(unique)
  645. ]
  646. interface ITfCandUIFnAutoFilter : IUnknown
  647. {
  648. //
  649. // Advise method
  650. // - advise eventsink for auto filtering
  651. //
  652. HRESULT Advise([in] ITfCandUIAutoFilterEventSink *pSink);
  653. //
  654. // Disable method
  655. // - unadvise eventsink for auto filtering
  656. //
  657. HRESULT Unadvise();
  658. //
  659. // Enable method
  660. // - enable/disable auto filtering
  661. //
  662. HRESULT Enable([in] BOOL fEnable);
  663. //
  664. // GetFilteringString method
  665. // - get string of filtering
  666. // - must be in filtering mode
  667. //
  668. HRESULT GetFilteringString([in] CANDUIFILTERSTR strtype, [out] BSTR *pbstr);
  669. };
  670. //
  671. // ITfCandUIFnSort
  672. // - CandidateUI function : sort
  673. // - Implemented by MSCANDUI.DLL
  674. //
  675. [
  676. object,
  677. uuid(db7495f7-bc6c-420c-a49d-7470e41b1a41),
  678. pointer_default(unique)
  679. ]
  680. interface ITfCandUIFnSort : IUnknown
  681. {
  682. //
  683. // Advise method
  684. // - advise eventsink for sorting
  685. //
  686. HRESULT Advise([in] ITfCandUISortEventSink *pSink);
  687. //
  688. // Disable method
  689. // - unadvise eventsink for sorting
  690. //
  691. HRESULT Unadvise();
  692. //
  693. // SortCandidateList method
  694. // - sort candidate list
  695. //
  696. HRESULT SortCandidateList([in] BOOL fSort);
  697. //
  698. // IsCandidateListSorted method
  699. // - get sort status
  700. //
  701. HRESULT IsCandidateListSorted([out] BOOL *pfSorted);
  702. };
  703. //
  704. // ITfCandUIFnKeyConfig
  705. // - CandidateUI function : key configuration
  706. // - Implemented by MSCANDUI.DLL
  707. //
  708. [
  709. object,
  710. uuid(2ccde6d6-6e0a-4231-9496-ce0da8aaa22b),
  711. pointer_default(unique)
  712. ]
  713. interface ITfCandUIFnKeyConfig : IUnknown
  714. {
  715. //
  716. // SetKeyTable method
  717. // - set key table in candidate UI
  718. //
  719. HRESULT SetKeyTable([in] ITfContext *pic, [in]ITfCandUIKeyTable *pCandUIKeyTable);
  720. //
  721. // GetKeyTable method
  722. // - get key table in candidate UI
  723. //
  724. HRESULT GetKeyTable([in] ITfContext *pic, [out]ITfCandUIKeyTable **ppCandUIKeyTable);
  725. //
  726. // ResetKeyTable method
  727. // - reset key table in candidate UI
  728. //
  729. HRESULT ResetKeyTable([in] ITfContext *pic);
  730. };
  731. //
  732. // ITfCandUIFnUIConfig
  733. // - CandidateUI function : UI stlyle configuration
  734. // - Implemented by MSCANDUI.DLL
  735. //
  736. [
  737. object,
  738. uuid(1037334c-8422-4c73-b854-f1a4616169d7),
  739. pointer_default(unique)
  740. ]
  741. interface ITfCandUIFnUIConfig : IUnknown
  742. {
  743. //
  744. // SetUIStyle method
  745. // - set the ui style of CandidateUI
  746. //
  747. HRESULT SetUIStyle([in] ITfContext *pic, [in] CANDUISTYLE style);
  748. //
  749. // GetUIStyle method
  750. // - get the ui style of CandidateUI
  751. //
  752. HRESULT GetUIStyle([in] ITfContext *pic, [out] CANDUISTYLE *pstyle);
  753. //
  754. // SetUIOption method
  755. // - set the ui option of CandidateUI
  756. //
  757. HRESULT SetUIOption([in] ITfContext *pic, [in] DWORD dwOption);
  758. //
  759. // GetUIOption method
  760. // - get the ui option of CandidateUI
  761. //
  762. HRESULT GetUIOption([in] ITfContext *pic, [out] DWORD *pdwOption);
  763. };
  764. //
  765. // ITfCandUIFnExtension
  766. // - CandidateUI function : extension manager
  767. // - Implemented by MSCANDUI.DLL
  768. //
  769. [
  770. object,
  771. uuid(c441b720-c7a0-4823-a257-8c3cd7bf14ba),
  772. pointer_default(unique)
  773. ]
  774. interface ITfCandUIFnExtension : IUnknown
  775. {
  776. //
  777. // AddExtObject
  778. // - add extension object
  779. //
  780. HRESULT AddExtObject([in] LONG id, [in] REFIID riid, [out] IUnknown **ppunk);
  781. //
  782. // GetExtObject method
  783. // - get extension object
  784. //
  785. HRESULT GetExtObject([in] LONG id, [in] REFIID riid, [out] IUnknown **ppunk);
  786. //
  787. // DeleteExtObject method
  788. // - delete extension object
  789. //
  790. HRESULT DeleteExtObject([in] LONG id);
  791. };
  792. //
  793. // ITfCandUIObject
  794. // - CandidateUI UI object : base interface
  795. // - Implemented by MSCANDUI.DLL
  796. //
  797. [
  798. object,
  799. uuid(c45d5b93-f651-41f0-ac45-13252f35bfdc),
  800. pointer_default(unique)
  801. ]
  802. interface ITfCandUIObject : IUnknown
  803. {
  804. //
  805. // Enable method
  806. // - enable/disable object
  807. //
  808. HRESULT Enable([in] BOOL fEnable);
  809. //
  810. // IsEnabled method
  811. // - get enable status of object
  812. //
  813. HRESULT IsEnabled([out] BOOL *pfEnabled);
  814. //
  815. // Show method
  816. // - show/hide object
  817. //
  818. HRESULT Show([in] BOOL fShow);
  819. //
  820. // IsVisible method
  821. // - get visible status of object
  822. //
  823. HRESULT IsVisible([out] BOOL *pfVisible);
  824. //
  825. // SetPosition method
  826. // - set position of object
  827. //
  828. HRESULT SetPosition([in] POINT *pptPos);
  829. //
  830. // GetPosition method
  831. // - get position of object
  832. //
  833. HRESULT GetPosition([out] POINT *pptPos);
  834. //
  835. // SetSize method
  836. // - set size of object
  837. //
  838. HRESULT SetSize([in] SIZE *psize);
  839. //
  840. // GetSize method
  841. // - get size of object
  842. //
  843. HRESULT GetSize([out] SIZE *psize);
  844. //
  845. // SetFont method
  846. // - set font of object
  847. //
  848. HRESULT SetFont([in] LOGFONTW *pLogFont);
  849. //
  850. // GetFont method
  851. // - get font of object
  852. //
  853. HRESULT GetFont([out] LOGFONTW *pLogFont);
  854. //
  855. // SetText method
  856. // - set text of object
  857. //
  858. HRESULT SetText([in] BSTR bstr);
  859. //
  860. // GetText method
  861. // - get text of object
  862. //
  863. HRESULT GetText([out] BSTR *pbtr);
  864. //
  865. // SetToolTipString method
  866. // - set tooltip string of object
  867. //
  868. HRESULT SetToolTipString([in] BSTR bstr);
  869. //
  870. // GetToolTipString method
  871. // - get tooltip string of object
  872. //
  873. HRESULT GetToolTipString([out] BSTR *pbtr);
  874. };
  875. //
  876. // ITfCandUICandWindow
  877. // - CandidateUI UI object : candidate window
  878. // - Implemented by MSCANDUI.DLL
  879. //
  880. [
  881. object,
  882. uuid(483324b6-c1a8-4a48-a543-c4f26fd32a29),
  883. pointer_default(unique)
  884. ]
  885. interface ITfCandUICandWindow : ITfCandUIObject
  886. {
  887. //
  888. // GetWindow method
  889. // - get window handle of candidate window
  890. //
  891. HRESULT GetWindow([out] HWND *phWnd);
  892. //
  893. // SetUIDirection method
  894. // - set UI direction
  895. //
  896. HRESULT SetUIDirection([in] CANDUIUIDIRECTION UIDir);
  897. //
  898. // GetUIDirection method
  899. // - get UI direction
  900. //
  901. HRESULT GetUIDirection([out] CANDUIUIDIRECTION *pUIDir);
  902. //
  903. // EnableAutoMove method
  904. // - enable auto moving candidate window on layout update
  905. //
  906. HRESULT EnableAutoMove([in] BOOL fEnable);
  907. //
  908. // EnableAutoMove method
  909. // - getenable status of auto moving
  910. //
  911. HRESULT IsAutoMoveEnabled([out] BOOL *pfEnabled);
  912. };
  913. //
  914. // ITfCandUIPopupCommentWindow
  915. // - CandidateUI UI object : popup comment window
  916. // - Implemented by MSCANDUI.DLL
  917. //
  918. [
  919. object,
  920. uuid(6ec789d1-7e81-4ecf-b726-f944c69e9987),
  921. pointer_default(unique)
  922. ]
  923. interface ITfCandUIPopupCommentWindow : ITfCandUIObject
  924. {
  925. //
  926. // GetWindow method
  927. // - get window handle of candidate window
  928. //
  929. HRESULT GetWindow([out] HWND *phWnd);
  930. //
  931. // SetDelayTime method
  932. // - set delaytime to popup window appeares in milliseconds
  933. // - set lTime to -1 to return the delay time to default value
  934. //
  935. HRESULT SetDelayTime([in] LONG lTime);
  936. //
  937. // GetDelayTime method
  938. // - get delaytime to popup window appeares in milliseconds
  939. //
  940. HRESULT GetDelayTime([in] LONG *plTime);
  941. //
  942. // EnableAutoMove method
  943. // - enable auto moving candidate window on layout update
  944. //
  945. HRESULT EnableAutoMove([in] BOOL fEnable);
  946. //
  947. // EnableAutoMove method
  948. // - getenable status of auto moving
  949. //
  950. HRESULT IsAutoMoveEnabled([out] BOOL *pfEnabled);
  951. };
  952. //
  953. // ITfCandUICandTipWindow
  954. // - CandidateUI UI object : candidate tip window
  955. // - Implemented by MSCANDUI.DLL
  956. //
  957. [
  958. object,
  959. uuid(2650d06e-6ee7-40bb-989f-73ee917e00ce),
  960. pointer_default(unique)
  961. ]
  962. interface ITfCandUICandTipWindow : ITfCandUIObject
  963. {
  964. //
  965. // GetWindow method
  966. // - get window handle of candidate window
  967. //
  968. HRESULT GetWindow([out] HWND *phWnd);
  969. };
  970. //
  971. // ITfCandUICandListBox
  972. // - CandidateUI UI object : candidate list box
  973. // - Implemented by MSCANDUI.DLL
  974. //
  975. [
  976. object,
  977. uuid(81defe18-4363-4e9f-a0e4-205bf3d2159e),
  978. pointer_default(unique)
  979. ]
  980. interface ITfCandUICandListBox : ITfCandUIObject
  981. {
  982. //
  983. // SetHeight method
  984. // - set candidate list height (in lines)
  985. // - valid 1 through 9 for fixed candidate list lines and -1 for auto (default=-1)
  986. // - succees while CandidateUI is not opened
  987. //
  988. HRESULT SetHeight([in] LONG lLines);
  989. //
  990. // GetHeight method
  991. // - get candidate list height (in lines)
  992. //
  993. HRESULT GetHeight([out] LONG *plLines);
  994. //
  995. // GetCandidateStringRect
  996. // - get candidate string position in screen coodinate
  997. // - return null rectangle if candidate string is not visible
  998. //
  999. HRESULT GetCandidateStringRect([in] ULONG nIndex, [out] RECT *prc);
  1000. };
  1001. //
  1002. // ITfCandUIMenuButton
  1003. // - CandidateUI UI object : menu button
  1004. // - Implemented by MSCANDUI.DLL
  1005. //
  1006. [
  1007. object,
  1008. uuid(77d031f3-87e5-458d-999c-237d9ae4d897),
  1009. pointer_default(unique)
  1010. ]
  1011. interface ITfCandUIMenuButton : ITfCandUIObject
  1012. {
  1013. //
  1014. // Advise method
  1015. // - advise eventsink for candidate menu
  1016. //
  1017. HRESULT Advise([in] ITfCandUIMenuEventSink *pSink);
  1018. //
  1019. // Disable method
  1020. // - unadvise eventsink for candidate menu
  1021. //
  1022. HRESULT Unadvise();
  1023. };
  1024. //
  1025. // ITfCandUICaption
  1026. // - CandidateUI UI object : caption
  1027. // - Implemented by MSCANDUI.DLL
  1028. //
  1029. [
  1030. object,
  1031. uuid(7243c0cd-474a-4b71-99a7-f88428e04a57),
  1032. pointer_default(unique)
  1033. ]
  1034. interface ITfCandUICaption : ITfCandUIObject
  1035. {
  1036. };
  1037. //
  1038. // ITfCandUIExtraCandidate
  1039. // - CandidateUI UI object : extra candidate
  1040. // - Implemented by MSCANDUI.DLL
  1041. //
  1042. [
  1043. object,
  1044. uuid(f6510bb9-f697-43d1-a5e2-eff290d00dfc),
  1045. pointer_default(unique)
  1046. ]
  1047. interface ITfCandUIExtraCandidate : ITfCandUIObject
  1048. {
  1049. };
  1050. //
  1051. // ITfCandUIRawData
  1052. // - CandidateUI UI object : rawdata
  1053. // - Implemented by MSCANDUI.DLL
  1054. //
  1055. [
  1056. object,
  1057. uuid(afd12370-d6c3-4e9e-a625-88bdfbef7b2f),
  1058. pointer_default(unique)
  1059. ]
  1060. interface ITfCandUIRawData : ITfCandUIObject
  1061. {
  1062. };
  1063. //
  1064. // ITfCandUICandTipButton
  1065. // - CandidateUI UI object : candidate tip button
  1066. // - Implemented by MSCANDUI.DLL
  1067. //
  1068. [
  1069. object,
  1070. uuid(b32ec07e-6b08-4ad9-b363-e96e2a060330),
  1071. pointer_default(unique)
  1072. ]
  1073. interface ITfCandUICandTipButton : ITfCandUIObject
  1074. {
  1075. };
  1076. //
  1077. // ITfCandUICandString
  1078. // - CandidateUI UI object : candidate string
  1079. // - Implemented by MSCANDUI.DLL
  1080. //
  1081. [
  1082. object,
  1083. uuid(c9e79120-83c5-438e-9927-43008db6c99a),
  1084. pointer_default(unique)
  1085. ]
  1086. interface ITfCandUICandString : ITfCandUIObject
  1087. {
  1088. };
  1089. //
  1090. // ITfCandUICandIndex
  1091. // - CandidateUI UI object : candidate index
  1092. // - Implemented by MSCANDUI.DLL
  1093. //
  1094. [
  1095. object,
  1096. uuid(fc0c7cc9-b065-4d8c-b37d-ee470835a486),
  1097. pointer_default(unique)
  1098. ]
  1099. interface ITfCandUICandIndex : ITfCandUIObject
  1100. {
  1101. };
  1102. //
  1103. // ITfCandUIInlineComment
  1104. // - CandidateUI UI object : inline comment
  1105. // - Implemented by MSCANDUI.DLL
  1106. //
  1107. [
  1108. object,
  1109. uuid(d4b1e0a2-aaf7-44f4-adf9-818b207bcf39),
  1110. pointer_default(unique)
  1111. ]
  1112. interface ITfCandUIInlineComment : ITfCandUIObject
  1113. {
  1114. };
  1115. //
  1116. // ITfCandUIToolTip
  1117. // - CandidateUI UI object : tooltip
  1118. // - Implemented by MSCANDUI.DLL
  1119. //
  1120. [
  1121. object,
  1122. uuid(8b5ec727-f645-4651-a318-6a4e2ed69666),
  1123. pointer_default(unique)
  1124. ]
  1125. interface ITfCandUIToolTip : ITfCandUIObject
  1126. {
  1127. };
  1128. //
  1129. // ITfCandUIPopupCommentTitle
  1130. // - CandidateUI UI object : popup comment title
  1131. // - Implemented by MSCANDUI.DLL
  1132. //
  1133. [
  1134. object,
  1135. uuid(cb21bc71-1974-4fb6-a9b0-f5bcc8f3c44b),
  1136. pointer_default(unique)
  1137. ]
  1138. interface ITfCandUIPopupCommentTitle : ITfCandUIObject
  1139. {
  1140. };
  1141. //
  1142. // ITfCandUIPopupCommentText
  1143. // - CandidateUI UI object : popup comment text
  1144. // - Implemented by MSCANDUI.DLL
  1145. //
  1146. [
  1147. object,
  1148. uuid(5770e84b-0b59-462d-8836-d70bbc8c8767),
  1149. pointer_default(unique)
  1150. ]
  1151. interface ITfCandUIPopupCommentText : ITfCandUIObject
  1152. {
  1153. };
  1154. //
  1155. // ITfCandUIExtObject
  1156. // - CandidateUI extension object : base interface
  1157. // - implemented by MSCANDUI.DLL
  1158. //
  1159. [
  1160. object,
  1161. uuid(8cf2f281-9add-4021-9a0d-62c0e11bc384),
  1162. pointer_default(unique)
  1163. ]
  1164. interface ITfCandUIExtObject : ITfCandUIObject
  1165. {
  1166. //
  1167. // GetID method
  1168. // - get identifier of the extension object
  1169. //
  1170. HRESULT GetID([out] LONG *pid);
  1171. };
  1172. //
  1173. // ITfCandUIExtSpace
  1174. // - CandidateUI extension object : space
  1175. // - implemented by MSCANDUI.DLL
  1176. //
  1177. [
  1178. object,
  1179. uuid(1fc2fb39-99fb-4cc4-9f6f-7ff31fe9f1a2),
  1180. pointer_default(unique)
  1181. ]
  1182. interface ITfCandUIExtSpace : ITfCandUIExtObject
  1183. {
  1184. };
  1185. //
  1186. // ITfCandUIExtPushButton
  1187. // - CandidateUI extension object : push button
  1188. // - implemented by MSCANDUI.DLL
  1189. //
  1190. [
  1191. object,
  1192. uuid(4466c342-4fd6-43e4-8d23-34f443ef2d01),
  1193. pointer_default(unique)
  1194. ]
  1195. interface ITfCandUIExtPushButton : ITfCandUIExtObject
  1196. {
  1197. //
  1198. // Advise method
  1199. // - advise eventsink for button extension
  1200. //
  1201. HRESULT Advise([in] ITfCandUIExtButtonEventSink *pSink);
  1202. //
  1203. // Unadvise method
  1204. // - unadvise eventsink for button extension
  1205. //
  1206. HRESULT Unadvise();
  1207. //
  1208. // SetIcon method
  1209. // - set the face icon of the button
  1210. // - note: icon and bitmap cannot be exist at same time on a button face.
  1211. // (the last set one will be displayed)
  1212. //
  1213. HRESULT SetIcon([in] HICON hIcon);
  1214. //
  1215. // SetBitmap method
  1216. // - set the face bitmap of the button
  1217. // - note: icon and bitmap cannot be exist at same time on a button face.
  1218. // (the last set one will be displayed)
  1219. //
  1220. HRESULT SetBitmap([in] HBITMAP hBitmap);
  1221. };
  1222. //
  1223. // ITfCandUIExtToggleButton
  1224. // - CandidateUI extension object : toggle button
  1225. // - implemented by MSCANDUI.DLL
  1226. //
  1227. [
  1228. object,
  1229. uuid(c16a174a-5628-4050-8dfe-0d82e7265ba1),
  1230. pointer_default(unique)
  1231. ]
  1232. interface ITfCandUIExtToggleButton : ITfCandUIExtObject
  1233. {
  1234. //
  1235. // Advise method
  1236. // - advise eventsink for button extension
  1237. //
  1238. HRESULT Advise([in] ITfCandUIExtButtonEventSink *pSink);
  1239. //
  1240. // Unadvise method
  1241. // - unadvise eventsink for button extension
  1242. //
  1243. HRESULT Unadvise();
  1244. //
  1245. // SetIcon method
  1246. // - set the face icon of the button
  1247. // - note: icon and bitmap cannot be exist at same time on a button face.
  1248. // (the last set one will be displayed)
  1249. //
  1250. HRESULT SetIcon([in] HICON hIcon);
  1251. //
  1252. // SetBitmap method
  1253. // - set the face bitmap of the button
  1254. // - note: icon and bitmap cannot be exist at same time on a button face.
  1255. // (the last set one will be displayed)
  1256. //
  1257. HRESULT SetBitmap([in] HBITMAP hBitmap);
  1258. //
  1259. // SetToggleState method
  1260. // - set the status of toggle button
  1261. //
  1262. HRESULT SetToggleState([in] BOOL fToggle);
  1263. //
  1264. // GetToggleState method
  1265. // - get the status of toggle button
  1266. // returns TRUE when the toggle button is toggled (i.e. pushed down),
  1267. // otherwise FALSE.
  1268. //
  1269. HRESULT GetToggleState([out] BOOL *pfToggled);
  1270. };
  1271. //
  1272. // ITfCandidateUIContextOwner
  1273. // - CandidateUI context infomation
  1274. // - implemented by MSCANDUI.DLL
  1275. //
  1276. [
  1277. object,
  1278. uuid(9fa4580f-cf50-43f4-af09-5e8cabe372c2),
  1279. pointer_default(unique)
  1280. ]
  1281. interface ITfCandidateUIContextOwner : IUnknown
  1282. {
  1283. //
  1284. // ProcessCommand method
  1285. // - let CandidateUI which own the context process command
  1286. //
  1287. HRESULT ProcessCommand([in] CANDUICOMMAND cmd, [in] INT iParam);
  1288. //
  1289. // TestText method
  1290. // - test if the text can be handled by CandidateUI which own the context.
  1291. //
  1292. HRESULT TestText([in] BSTR bstr, [out] BOOL *pfHandles);
  1293. };
  1294. //
  1295. // ITfCandidateUI
  1296. // - this interface provide the MS shared candidate UI
  1297. // - implemented by MSCANDUI.DLL
  1298. //
  1299. [
  1300. object,
  1301. uuid(e45f7b70-a4c3-48cd-8edd-3e784a8f5eae),
  1302. pointer_default(unique)
  1303. ]
  1304. interface ITfCandidateUI : IUnknown
  1305. {
  1306. //
  1307. // SetClientId method
  1308. // - set a new TfClientId
  1309. //
  1310. HRESULT SetClientId([in] TfClientId tid);
  1311. //
  1312. // OpenCandidateUI method
  1313. // - open the candidate UI based on the given candidate list
  1314. //
  1315. HRESULT OpenCandidateUI([in] HWND hWnd, [in] ITfDocumentMgr *pdim, [in] TfEditCookie ec, [in] ITfRange *pRange);
  1316. //
  1317. // CloseCandidateUI method
  1318. // - close the candidate UI
  1319. //
  1320. HRESULT CloseCandidateUI();
  1321. //
  1322. // SetCandidateList method
  1323. // - set candidate list to be displayed in the list of candidate UI window.
  1324. //
  1325. HRESULT SetCandidateList([in] ITfCandidateList *pCandList);
  1326. //
  1327. // SetSelection method
  1328. // - set selection
  1329. //
  1330. HRESULT SetSelection([in] ULONG nIndex);
  1331. //
  1332. // GetSelection method
  1333. // - get index of current selected candidate item
  1334. //
  1335. HRESULT GetSelection([out] ULONG *pnIndex);
  1336. //
  1337. // SetTargetRange method
  1338. // - set target range
  1339. //
  1340. HRESULT SetTargetRange([in] ITfRange *pRange);
  1341. //
  1342. // GetTargetRange method
  1343. // - get the target range
  1344. //
  1345. HRESULT GetTargetRange([out] ITfRange **ppRange);
  1346. //
  1347. // GetUIObject method
  1348. // - get CandidateUI objects
  1349. //
  1350. HRESULT GetUIObject([in] REFIID riid, [out] IUnknown **ppunk);
  1351. //
  1352. // GetFunction method
  1353. // - get CandidateUI function
  1354. //
  1355. HRESULT GetFunction([in] REFIID riid, [out] IUnknown **ppunk);
  1356. //
  1357. // ProcessCommand method
  1358. // - process candidate UI command
  1359. //
  1360. HRESULT ProcessCommand([in] CANDUICOMMAND cmd, [in] INT iParam);
  1361. };
  1362. // =-------------------------------------------------------------------------=
  1363. //
  1364. // C L S I D / I I D D E F I N I T I O N
  1365. //
  1366. // =-------------------------------------------------------------------------=
  1367. cpp_quote("")
  1368. cpp_quote("DEFINE_GUID( CLSID_TFCandidateUI, 0x93ac9cb8, 0x27d5, 0x4482, 0xbf, 0xdf, 0x68, 0xf2, 0x1c, 0x74, 0x54, 0xa3 );")
  1369. cpp_quote("DEFINE_GUID( IID_ITfCandidateUI, 0xe45f7b70, 0xa4c3, 0x48cd, 0x8e, 0xdd, 0x3e, 0x78, 0x4a, 0x8f, 0x5e, 0xae );")
  1370. cpp_quote("DEFINE_GUID( IID_ITfCandidateStringFlag, 0x91114c09, 0x1fb3, 0x4771, 0x97, 0x01, 0x74, 0xfd, 0x18, 0xe1, 0x30, 0x9a );")
  1371. cpp_quote("DEFINE_GUID( IID_ITfCandidateStringInlineComment, 0xa55119cc, 0xfed4, 0x49de, 0x85, 0xb2, 0xb6, 0xb5, 0x5f, 0x26, 0xb0, 0x0f );")
  1372. cpp_quote("DEFINE_GUID( IID_ITfCandidateStringPopupComment, 0x66d2ab70, 0xd46c, 0x4543, 0xa4, 0xa9, 0xc6, 0x8b, 0x00, 0xb4, 0x3b, 0x4c );")
  1373. cpp_quote("DEFINE_GUID( IID_ITfCandidateStringColor, 0x43fb8eee, 0xff1c, 0x42a1, 0x81, 0x0c, 0x77, 0x20, 0x1d, 0xf6, 0x71, 0x7e );")
  1374. cpp_quote("DEFINE_GUID( IID_ITfCandidateStringFixture, 0xb85c0208, 0x4fec, 0x418c, 0x85, 0xd0, 0xc6, 0x2a, 0xd2, 0x9a, 0x09, 0x2b );")
  1375. cpp_quote("DEFINE_GUID( IID_ITfCandidateStringIcon, 0x46275059, 0xc606, 0x41b0, 0xaa, 0xc8, 0xc8, 0xaa, 0x48, 0xb8, 0x29, 0x98 );")
  1376. cpp_quote("DEFINE_GUID( IID_ITfCandidateListRawData, 0xcdd01281, 0x8228, 0x45a0, 0x9b, 0x55, 0xcc, 0x44, 0xc2, 0xa2, 0xa0, 0x91 );")
  1377. cpp_quote("DEFINE_GUID( IID_ITfCandidateListExtraCandidate, 0x85bbeeb5, 0xba64, 0x411e, 0xab, 0xb3, 0xed, 0x37, 0x92, 0x75, 0xfa, 0xb4 );")
  1378. cpp_quote("DEFINE_GUID( IID_ITfCandidateListTip, 0xc28a9c90, 0x16b1, 0x4064, 0xa1, 0x90, 0x0b, 0x9e, 0x5f, 0x59, 0x25, 0x39 );")
  1379. cpp_quote("DEFINE_GUID( IID_ITfCandUIKeyTable, 0x4f9d0bca, 0xc834, 0x4a46, 0x8d, 0xef, 0xb7, 0x54, 0x46, 0x71, 0xd6, 0x02 );")
  1380. cpp_quote("DEFINE_GUID( IID_ITfCandUIMenuExtension, 0x6875610e, 0x8912, 0x44c6, 0xbc, 0xab, 0x48, 0xc6, 0xcf, 0xf9, 0x15, 0xe3 );")
  1381. cpp_quote("DEFINE_GUID( IID_ITfCandUIAutoFilterEventSink, 0x28ae3d7b, 0xc38f, 0x4efa, 0xae, 0xdb, 0xf8, 0xca, 0xcc, 0x1b, 0x74, 0x22 );")
  1382. cpp_quote("DEFINE_GUID( IID_ITfCandUISortEventSink, 0x212d4632, 0x58aa, 0x433e, 0x9a, 0xea, 0x67, 0xa2, 0xef, 0xe7, 0x0c, 0xb9 );")
  1383. cpp_quote("DEFINE_GUID( IID_ITfCandUIMenuEventSink, 0x944f237e, 0xf03b, 0x4bb9, 0xb8, 0xf3, 0x7a, 0xfa, 0x51, 0x58, 0x2d, 0x1a );")
  1384. cpp_quote("DEFINE_GUID( IID_ITfCandUIExtButtonEventSink, 0x5c0fb534, 0x1c7e, 0x48c2, 0x90, 0x8f, 0x00, 0x85, 0x66, 0xc1, 0xcb, 0xb0 );")
  1385. cpp_quote("DEFINE_GUID( IID_ITfCandUIObject, 0xc45d5b93, 0xf651, 0x41f0, 0xac, 0x45, 0x13, 0x25, 0x2f, 0x35, 0xbf, 0xdc );")
  1386. cpp_quote("DEFINE_GUID( IID_ITfCandUICandWindow, 0x483324b6, 0xc1a8, 0x4a48, 0xa5, 0x43, 0xc4, 0xf2, 0x6f, 0xd3, 0x2a, 0x29 );")
  1387. cpp_quote("DEFINE_GUID( IID_ITfCandUIPopupCommentWindow, 0x6ec789d1, 0x7e81, 0x4ecf, 0xb7, 0x26, 0xf9, 0x44, 0xc6, 0x9e, 0x99, 0x87 );")
  1388. cpp_quote("DEFINE_GUID( IID_ITfCandUICandTipWindow, 0x2650d06e, 0x6ee7, 0x40bb, 0x98, 0x9f, 0x73, 0xee, 0x91, 0x7e, 0x00, 0xce );")
  1389. cpp_quote("DEFINE_GUID( IID_ITfCandUICandListBox, 0x81defe18, 0x4363, 0x4e9f, 0xa0, 0xe4, 0x20, 0x5b, 0xf3, 0xd2, 0x15, 0x9e );")
  1390. cpp_quote("DEFINE_GUID( IID_ITfCandUIMenuButton, 0x77d031f3, 0x87e5, 0x458d, 0x99, 0x9c, 0x23, 0x7d, 0x9a, 0xe4, 0xd8, 0x97 );")
  1391. cpp_quote("DEFINE_GUID( IID_ITfCandUICaption, 0x7243c0cd, 0x474a, 0x4b71, 0x99, 0xa7, 0xf8, 0x84, 0x28, 0xe0, 0x4a, 0x57 );")
  1392. cpp_quote("DEFINE_GUID( IID_ITfCandUIExtraCandidate, 0xf6510bb9, 0xf697, 0x43d1, 0xa5, 0xe2, 0xef, 0xf2, 0x90, 0xd0, 0x0d, 0xfc );")
  1393. cpp_quote("DEFINE_GUID( IID_ITfCandUIRawData, 0xafd12370, 0xd6c3, 0x4e9e, 0xa6, 0x25, 0x88, 0xbd, 0xfb, 0xef, 0x7b, 0x2f );")
  1394. cpp_quote("DEFINE_GUID( IID_ITfCandUICandTipButton, 0xb32ec07e, 0x6b08, 0x4ad9, 0xb3, 0x63, 0xe9, 0x6e, 0x2a, 0x06, 0x03, 0x30 );")
  1395. cpp_quote("DEFINE_GUID( IID_ITfCandUICandString, 0xc9e79120, 0x83c5, 0x438e, 0x99, 0x27, 0x43, 0x00, 0x8d, 0xb6, 0xc9, 0x9a );")
  1396. cpp_quote("DEFINE_GUID( IID_ITfCandUICandIndex, 0xfc0c7cc9, 0xb065, 0x4d8c, 0xb3, 0x7d, 0xee, 0x47, 0x08, 0x35, 0xa4, 0x86 );")
  1397. cpp_quote("DEFINE_GUID( IID_ITfCandUIInlineComment, 0xd4b1e0a2, 0xaaf7, 0x44f4, 0xad, 0xf9, 0x81, 0x8b, 0x20, 0x7b, 0xcf, 0x39 );")
  1398. cpp_quote("DEFINE_GUID( IID_ITfCandUIToolTip, 0x8b5ec727, 0xf645, 0x4651, 0xa3, 0x18, 0x6a, 0x4e, 0x2e, 0xd6, 0x96, 0x66 );")
  1399. cpp_quote("DEFINE_GUID( IID_ITfCandUIPopupCommentTitle, 0xcb21bc71, 0x1974, 0x4fb6, 0xa9, 0xb0, 0xf5, 0xbc, 0xc8, 0xf3, 0xc4, 0x4b );")
  1400. cpp_quote("DEFINE_GUID( IID_ITfCandUIPopupCommentText, 0x5770e84b, 0x0b59, 0x462d, 0x88, 0x36, 0xd7, 0x0b, 0xbc, 0x8c, 0x87, 0x67 );")
  1401. cpp_quote("DEFINE_GUID( IID_ITfCandUIFnAutoFilter, 0x499394ab, 0x67c3, 0x48a5, 0xa4, 0x5c, 0x50, 0x80, 0x50, 0x9e, 0x0f, 0xfb );")
  1402. cpp_quote("DEFINE_GUID( IID_ITfCandUIFnSort, 0xdb7495f7, 0xbc6c, 0x420c, 0xa4, 0x9d, 0x74, 0x70, 0xe4, 0x1b, 0x1a, 0x41 );")
  1403. cpp_quote("DEFINE_GUID( IID_ITfCandUIFnKeyConfig, 0x2ccde6d6, 0x6e0a, 0x4231, 0x94, 0x96, 0xce, 0x0d, 0xa8, 0xaa, 0xa2, 0x2b );")
  1404. cpp_quote("DEFINE_GUID( IID_ITfCandUIFnUIConfig, 0x1037334c, 0x8422, 0x4c73, 0xb8, 0x54, 0xf1, 0xa4, 0x61, 0x61, 0x69, 0xd7 );")
  1405. cpp_quote("DEFINE_GUID( IID_ITfCandUIFnExtension, 0xc441b720, 0xc7a0, 0x4823, 0xa2, 0x57, 0x8c, 0x3c, 0xd7, 0xbf, 0x14, 0xba );")
  1406. cpp_quote("DEFINE_GUID( IID_ITfCandUIExtObject, 0x8cf2f281, 0x9add, 0x4021, 0x9a, 0x0d, 0x62, 0xc0, 0xe1, 0x1b, 0xc3, 0x84 );")
  1407. cpp_quote("DEFINE_GUID( IID_ITfCandUIExtSpace, 0x1fc2fb39, 0x99fb, 0x4cc4, 0x9f, 0x6f, 0x7f, 0xf3, 0x1f, 0xe9, 0xf1, 0xa2 );")
  1408. cpp_quote("DEFINE_GUID( IID_ITfCandUIExtPushButton, 0x4466c342, 0x4fd6, 0x43e4, 0x8d, 0x23, 0x34, 0xf4, 0x43, 0xef, 0x2d, 0x01 );")
  1409. cpp_quote("DEFINE_GUID( IID_ITfCandUIExtToggleButton, 0xc16a174a, 0x5628, 0x4050, 0x8d, 0xfe, 0x0d, 0x82, 0xe7, 0x26, 0x5b, 0xa1 );")
  1410. cpp_quote("DEFINE_GUID( IID_ITfOptionsCandidateList, 0x605133F7, 0x758D, 0x42fc, 0xA3, 0xFE, 0x10, 0x14, 0x6A, 0x7D, 0x52, 0xF9 );")
  1411. cpp_quote("DEFINE_GUID( IID_ITfCandidateUIContextOwner, 0x9fa4580f, 0xcf50, 0x43f4, 0xaf, 0x09, 0x5e, 0x8c, 0xab, 0xe3, 0x72, 0xc2 );")
  1412. cpp_quote("DEFINE_GUID( GUID_COMPARTMENT_MSCANDIDATEUI_CONTEXT, 0x7a489854, 0x7118, 0x4194, 0xbd, 0x3f, 0xcb, 0x3e, 0xfa, 0x2f, 0x30, 0x79 );")
  1413. cpp_quote("DEFINE_GUID( GUID_COMPARTMENT_MSCANDIDATEUI_CONTEXTOWNER, 0xab2bdcff, 0x42c9, 0x497b, 0xb6, 0xcb, 0x49, 0xa8, 0x33, 0x3d, 0xa5, 0x9d);")
  1414. cpp_quote("")
  1415. cpp_quote("#endif // MSCANDUI_DEFINED")