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.

345 lines
13 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1992-1997.
  5. //
  6. // File: aimm12.idl
  7. //
  8. // Contents: ActiveIMM 1.2 interface definitions
  9. //
  10. //
  11. //--------------------------------------------------------------------------
  12. cpp_quote("//=--------------------------------------------------------------------------=")
  13. cpp_quote("// aimm12.h")
  14. cpp_quote("//=--------------------------------------------------------------------------=")
  15. cpp_quote("// (C) Copyright 1995-1999 Microsoft Corporation. All Rights Reserved.")
  16. cpp_quote("//")
  17. cpp_quote("// THIS CODE AND INFORMATION IS PROVIDED \"AS IS\" WITHOUT WARRANTY OF")
  18. cpp_quote("// ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO")
  19. cpp_quote("// THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A")
  20. cpp_quote("// PARTICULAR PURPOSE.")
  21. cpp_quote("//=--------------------------------------------------------------------------=")
  22. cpp_quote("")
  23. cpp_quote("#pragma comment(lib,\"uuid.lib\")")
  24. cpp_quote("")
  25. cpp_quote("//--------------------------------------------------------------------------")
  26. cpp_quote("// IActiveIMM 1.2 Interfaces.")
  27. cpp_quote("")
  28. #ifndef DO_NO_IMPORTS
  29. import "unknwn.idl";
  30. import "oaidl.idl";
  31. #endif
  32. cpp_quote("EXTERN_C const CLSID CLSID_CActiveIMM12;")
  33. cpp_quote("EXTERN_C const CLSID CLSID_CActiveIMM12_Trident;")
  34. cpp_quote("#define AIMM12_PROCESS_ATOM TEXT(\"_AIMM12_PROCESS_ATOM_\")")
  35. cpp_quote("#if 0")
  36. typedef WORD LANGID;
  37. typedef struct
  38. {
  39. LPSTR lpReading;
  40. LPSTR lpWord;
  41. } REGISTERWORDA;
  42. typedef struct
  43. {
  44. LPWSTR lpReading;
  45. LPWSTR lpWord;
  46. } REGISTERWORDW;
  47. #define LF_FACESIZE 32
  48. typedef struct
  49. {
  50. LONG lfHeight;
  51. LONG lfWidth;
  52. LONG lfEscapement;
  53. LONG lfOrientation;
  54. LONG lfWeight;
  55. BYTE lfItalic;
  56. BYTE lfUnderline;
  57. BYTE lfStrikeOut;
  58. BYTE lfCharSet;
  59. BYTE lfOutPrecision;
  60. BYTE lfClipPrecision;
  61. BYTE lfQuality;
  62. BYTE lfPitchAndFamily;
  63. CHAR lfFaceName[LF_FACESIZE];
  64. } LOGFONTA;
  65. typedef struct
  66. {
  67. LONG lfHeight;
  68. LONG lfWidth;
  69. LONG lfEscapement;
  70. LONG lfOrientation;
  71. LONG lfWeight;
  72. BYTE lfItalic;
  73. BYTE lfUnderline;
  74. BYTE lfStrikeOut;
  75. BYTE lfCharSet;
  76. BYTE lfOutPrecision;
  77. BYTE lfClipPrecision;
  78. BYTE lfQuality;
  79. BYTE lfPitchAndFamily;
  80. WCHAR lfFaceName[LF_FACESIZE];
  81. } LOGFONTW;
  82. typedef DWORD HIMC;
  83. typedef DWORD HIMCC;
  84. typedef struct
  85. {
  86. DWORD dwIndex;
  87. DWORD dwStyle;
  88. POINT ptCurrentPos;
  89. RECT rcArea;
  90. } CANDIDATEFORM;
  91. typedef struct
  92. {
  93. DWORD dwStyle;
  94. POINT ptCurrentPos;
  95. RECT rcArea;
  96. } COMPOSITIONFORM;
  97. typedef struct
  98. {
  99. DWORD dwSize;
  100. DWORD dwStyle;
  101. DWORD dwCount;
  102. DWORD dwSelection;
  103. DWORD dwPageStart;
  104. DWORD dwPageSize;
  105. DWORD dwOffset[1];
  106. } CANDIDATELIST;
  107. #define STYLE_DESCRIPTION_SIZE 32
  108. typedef struct
  109. {
  110. DWORD dwStyle;
  111. CHAR szDescription[STYLE_DESCRIPTION_SIZE];
  112. } STYLEBUFA;
  113. typedef struct
  114. {
  115. DWORD dwStyle;
  116. WCHAR szDescription[STYLE_DESCRIPTION_SIZE];
  117. } STYLEBUFW;
  118. typedef WORD ATOM;
  119. #define IMEMENUITEM_STRING_SIZE 80
  120. typedef struct
  121. {
  122. UINT cbSize;
  123. UINT fType;
  124. UINT fState;
  125. UINT wID;
  126. HBITMAP hbmpChecked;
  127. HBITMAP hbmpUnchecked;
  128. DWORD dwItemData;
  129. CHAR szString[IMEMENUITEM_STRING_SIZE];
  130. HBITMAP hbmpItem;
  131. } IMEMENUITEMINFOA;
  132. typedef struct
  133. {
  134. UINT cbSize;
  135. UINT fType;
  136. UINT fState;
  137. UINT wID;
  138. HBITMAP hbmpChecked;
  139. HBITMAP hbmpUnchecked;
  140. DWORD dwItemData;
  141. WCHAR szString[IMEMENUITEM_STRING_SIZE];
  142. HBITMAP hbmpItem;
  143. } IMEMENUITEMINFOW;
  144. cpp_quote("#endif")
  145. cpp_quote("#if !defined(_DDKIMM_H_) && !defined(_IMM_DDK_DEFINED_)")
  146. typedef struct
  147. {
  148. HWND hWnd;
  149. BOOL fOpen;
  150. POINT ptStatusWndPos;
  151. POINT ptSoftKbdPos;
  152. DWORD fdwConversion;
  153. DWORD fdwSentence;
  154. union
  155. {
  156. LOGFONTA A;
  157. LOGFONTW W;
  158. } lfFont;
  159. COMPOSITIONFORM cfCompForm;
  160. CANDIDATEFORM cfCandForm[4];
  161. HIMCC hCompStr;
  162. HIMCC hCandInfo;
  163. HIMCC hGuideLine;
  164. HIMCC hPrivate;
  165. DWORD dwNumMsgBuf;
  166. HIMCC hMsgBuf;
  167. DWORD fdwInit;
  168. DWORD dwReserve[3];
  169. } INPUTCONTEXT;
  170. typedef struct
  171. {
  172. DWORD dwPrivateDataSize;
  173. DWORD fdwProperty;
  174. DWORD fdwConversionCaps;
  175. DWORD fdwSentenceCaps;
  176. DWORD fdwUICaps;
  177. DWORD fdwSCSCaps;
  178. DWORD fdwSelectCaps;
  179. } IMEINFO;
  180. cpp_quote("#endif")
  181. [
  182. object,
  183. uuid(08C03412-F96B-11d0-A475-00AA006BCC59),
  184. pointer_default(unique)
  185. ]
  186. interface IEnumRegisterWordA : IUnknown
  187. {
  188. HRESULT Clone([out] IEnumRegisterWordA **ppEnum);
  189. HRESULT Next([in] ULONG ulCount, [out] REGISTERWORDA *rgRegisterWord, [out] ULONG *pcFetched);
  190. HRESULT Reset();
  191. HRESULT Skip([in] ULONG ulCount);
  192. };
  193. [
  194. object,
  195. uuid(4955DD31-B159-11d0-8FCF-00AA006BCC59),
  196. pointer_default(unique)
  197. ]
  198. interface IEnumRegisterWordW : IUnknown
  199. {
  200. HRESULT Clone([out] IEnumRegisterWordW **ppEnum);
  201. HRESULT Next([in] ULONG ulCount, [out] REGISTERWORDW *rgRegisterWord, [out] ULONG *pcFetched);
  202. HRESULT Reset();
  203. HRESULT Skip([in] ULONG ulCount);
  204. };
  205. [
  206. object,
  207. uuid(09b5eab0-f997-11d1-93d4-0060b067b86e),
  208. pointer_default(unique)
  209. ]
  210. interface IEnumInputContext : IUnknown
  211. {
  212. HRESULT Clone([out] IEnumInputContext **ppEnum);
  213. HRESULT Next([in] ULONG ulCount, [out] HIMC *rgInputContext, [out] ULONG *pcFetched);
  214. HRESULT Reset();
  215. HRESULT Skip([in] ULONG ulCount);
  216. };
  217. [
  218. object,
  219. uuid(b5cf2cfa-8aeb-11d1-9364-0060b067b86e),
  220. pointer_default(unique)
  221. ]
  222. interface IActiveIMMMessagePumpOwner : IUnknown
  223. {
  224. HRESULT Start();
  225. HRESULT End();
  226. HRESULT OnTranslateMessage([in] const MSG *pMsg);
  227. HRESULT Pause([out] DWORD *pdwCookie);
  228. HRESULT Resume([in] DWORD dwCookie);
  229. }
  230. [
  231. local,
  232. object,
  233. uuid(08c0e040-62d1-11d1-9326-0060b067b86e),
  234. pointer_default(unique)
  235. ]
  236. interface IActiveIMMApp : IUnknown
  237. {
  238. HRESULT AssociateContext([in] HWND hWnd, [in] HIMC hIME, [out] HIMC *phPrev);
  239. HRESULT ConfigureIMEA([in] HKL hKL, [in] HWND hWnd, [in] DWORD dwMode, [in] REGISTERWORDA *pData);
  240. HRESULT ConfigureIMEW([in] HKL hKL, [in] HWND hWnd, [in] DWORD dwMode, [in] REGISTERWORDW *pData);
  241. HRESULT CreateContext([out] HIMC *phIMC);
  242. HRESULT DestroyContext([in] HIMC hIME);
  243. HRESULT EnumRegisterWordA([in] HKL hKL, [in] LPSTR szReading, [in] DWORD dwStyle, [in] LPSTR szRegister, [in] LPVOID pData, [out] IEnumRegisterWordA **pEnum);
  244. HRESULT EnumRegisterWordW([in] HKL hKL, [in] LPWSTR szReading, [in] DWORD dwStyle, [in] LPWSTR szRegister, [in] LPVOID pData, [out] IEnumRegisterWordW **pEnum);
  245. HRESULT EscapeA([in] HKL hKL, [in] HIMC hIMC, [in] UINT uEscape, [in, out] LPVOID pData, [out] LRESULT *plResult);
  246. HRESULT EscapeW([in] HKL hKL, [in] HIMC hIMC, [in] UINT uEscape, [in, out] LPVOID pData, [out] LRESULT *plResult);
  247. HRESULT GetCandidateListA([in] HIMC hIMC, [in] DWORD dwIndex, [in] UINT uBufLen, [out] CANDIDATELIST *pCandList, [out] UINT *puCopied);
  248. HRESULT GetCandidateListW([in] HIMC hIMC, [in] DWORD dwIndex, [in] UINT uBufLen, [out] CANDIDATELIST *pCandList, [out] UINT *puCopied);
  249. HRESULT GetCandidateListCountA([in] HIMC hIMC, [out] DWORD *pdwListSize, [out] DWORD *pdwBufLen);
  250. HRESULT GetCandidateListCountW([in] HIMC hIMC, [out] DWORD *pdwListSize, [out] DWORD *pdwBufLen);
  251. HRESULT GetCandidateWindow([in] HIMC hIMC, [in] DWORD dwIndex, [out] CANDIDATEFORM *pCandidate);
  252. HRESULT GetCompositionFontA([in] HIMC hIMC, [out] LOGFONTA *plf);
  253. HRESULT GetCompositionFontW([in] HIMC hIMC, [out] LOGFONTW *plf);
  254. HRESULT GetCompositionStringA([in] HIMC hIMC, [in] DWORD dwIndex, [in] DWORD dwBufLen, [out] LONG *plCopied, [out] LPVOID pBuf);
  255. HRESULT GetCompositionStringW([in] HIMC hIMC, [in] DWORD dwIndex, [in] DWORD dwBufLen, [out] LONG *plCopied, [out] LPVOID pBuf);
  256. HRESULT GetCompositionWindow([in] HIMC hIMC, [out] COMPOSITIONFORM *pCompForm);
  257. HRESULT GetContext([in] HWND hWnd, [out] HIMC *phIMC);
  258. HRESULT GetConversionListA([in] HKL hKL, [in] HIMC hIMC, [in] LPSTR pSrc, [in] UINT uBufLen, [in] UINT uFlag, [out] CANDIDATELIST *pDst, [out] UINT *puCopied);
  259. HRESULT GetConversionListW([in] HKL hKL, [in] HIMC hIMC, [in] LPWSTR pSrc, [in] UINT uBufLen, [in] UINT uFlag, [out] CANDIDATELIST *pDst, [out] UINT *puCopied);
  260. HRESULT GetConversionStatus([in] HIMC hIMC, [out] DWORD *pfdwConversion, [out] DWORD *pfdwSentence);
  261. HRESULT GetDefaultIMEWnd([in] HWND hWnd, [out] HWND *phDefWnd);
  262. HRESULT GetDescriptionA([in] HKL hKL, [in] UINT uBufLen, [out] LPSTR szDescription, [out] UINT *puCopied);
  263. HRESULT GetDescriptionW([in] HKL hKL, [in] UINT uBufLen, [out] LPWSTR szDescription, [out] UINT *puCopied);
  264. HRESULT GetGuideLineA([in] HIMC hIMC, [in] DWORD dwIndex, [in] DWORD dwBufLen, [out] LPSTR pBuf, [out] DWORD *pdwResult);
  265. HRESULT GetGuideLineW([in] HIMC hIMC, [in] DWORD dwIndex, [in] DWORD dwBufLen, [out] LPWSTR pBuf, [out] DWORD *pdwResult);
  266. HRESULT GetIMEFileNameA([in] HKL hKL, [in] UINT uBufLen, [out] LPSTR szFileName, [out] UINT *puCopied);
  267. HRESULT GetIMEFileNameW([in] HKL hKL, [in] UINT uBufLen, [out] LPWSTR szFileName, [out] UINT *puCopied);
  268. HRESULT GetOpenStatus([in] HIMC hIMC);
  269. HRESULT GetProperty([in] HKL hKL, [in] DWORD fdwIndex, [out] DWORD *pdwProperty);
  270. HRESULT GetRegisterWordStyleA([in] HKL hKL, [in] UINT nItem, [out] STYLEBUFA *pStyleBuf, [out] UINT *puCopied);
  271. HRESULT GetRegisterWordStyleW([in] HKL hKL, [in] UINT nItem, [out] STYLEBUFW *pStyleBuf, [out] UINT *puCopied);
  272. HRESULT GetStatusWindowPos([in] HIMC hIMC, [out] POINT *pptPos);
  273. HRESULT GetVirtualKey([in] HWND hWnd, [out] UINT *puVirtualKey);
  274. HRESULT InstallIMEA([in] LPSTR szIMEFileName, [in] LPSTR szLayoutText, [out] HKL *phKL);
  275. HRESULT InstallIMEW([in] LPWSTR szIMEFileName, [in] LPWSTR szLayoutText, [out] HKL *phKL);
  276. HRESULT IsIME([in] HKL hKL);
  277. HRESULT IsUIMessageA([in] HWND hWndIME, [in] UINT msg, [in] WPARAM wParam, [in] LPARAM lParam);
  278. HRESULT IsUIMessageW([in] HWND hWndIME, [in] UINT msg, [in] WPARAM wParam, [in] LPARAM lParam);
  279. HRESULT NotifyIME([in] HIMC hIMC, [in] DWORD dwAction, [in] DWORD dwIndex, [in] DWORD dwValue);
  280. HRESULT RegisterWordA([in] HKL hKL, [in] LPSTR szReading, [in] DWORD dwStyle, [in] LPSTR szRegister);
  281. HRESULT RegisterWordW([in] HKL hKL, [in] LPWSTR szReading, [in] DWORD dwStyle, [in] LPWSTR szRegister);
  282. HRESULT ReleaseContext([in] HWND hWnd, [in] HIMC hIMC);
  283. HRESULT SetCandidateWindow([in] HIMC hIMC, [in] CANDIDATEFORM *pCandidate);
  284. HRESULT SetCompositionFontA([in] HIMC hIMC, [in] LOGFONTA *plf);
  285. HRESULT SetCompositionFontW([in] HIMC hIMC, [in] LOGFONTW *plf);
  286. HRESULT SetCompositionStringA([in] HIMC hIMC, [in] DWORD dwIndex, [in] LPVOID pComp, [in] DWORD dwCompLen, [in] LPVOID pRead, [in] DWORD dwReadLen);
  287. HRESULT SetCompositionStringW([in] HIMC hIMC, [in] DWORD dwIndex, [in] LPVOID pComp, [in] DWORD dwCompLen, [in] LPVOID pRead, [in] DWORD dwReadLen);
  288. HRESULT SetCompositionWindow([in] HIMC hIMC, [in] COMPOSITIONFORM *pCompForm);
  289. HRESULT SetConversionStatus([in] HIMC hIMC, [in] DWORD fdwConversion, [in] DWORD fdwSentence);
  290. HRESULT SetOpenStatus([in] HIMC hIMC, [in] BOOL fOpen);
  291. HRESULT SetStatusWindowPos([in] HIMC hIMC, [in] POINT *pptPos);
  292. HRESULT SimulateHotKey([in] HWND hWnd, [in] DWORD dwHotKeyID);
  293. HRESULT UnregisterWordA([in] HKL hKL, [in] LPSTR szReading, [in] DWORD dwStyle, [in] LPSTR szUnregister);
  294. HRESULT UnregisterWordW([in] HKL hKL, [in] LPWSTR szReading, [in] DWORD dwStyle, [in] LPWSTR szUnregister);
  295. // aimm specific
  296. HRESULT Activate([in] BOOL fRestoreLayout);
  297. HRESULT Deactivate();
  298. HRESULT OnDefWindowProc([in] HWND hWnd, [in] UINT Msg, [in] WPARAM wParam, [in] LPARAM lParam, [out] LRESULT *plResult);
  299. HRESULT FilterClientWindows([in] ATOM *aaClassList, [in] UINT uSize);
  300. HRESULT GetCodePageA([in] HKL hKL, [out] UINT *uCodePage);
  301. HRESULT GetLangId([in] HKL hKL, [out] LANGID *plid);
  302. // win98/nt5 apis
  303. HRESULT AssociateContextEx([in] HWND hWnd, [in] HIMC hIMC, [in] DWORD dwFlags);
  304. HRESULT DisableIME([in] DWORD idThread);
  305. HRESULT GetImeMenuItemsA([in] HIMC hIMC, [in] DWORD dwFlags, [in] DWORD dwType, [in] IMEMENUITEMINFOA *pImeParentMenu, [out] IMEMENUITEMINFOA *pImeMenu, [in] DWORD dwSize, [out] DWORD *pdwResult);
  306. HRESULT GetImeMenuItemsW([in] HIMC hIMC, [in] DWORD dwFlags, [in] DWORD dwType, [in] IMEMENUITEMINFOW *pImeParentMenu, [out] IMEMENUITEMINFOW *pImeMenu, [in] DWORD dwSize, [out] DWORD *pdwResult);
  307. HRESULT EnumInputContext([in] DWORD idThread, [out] IEnumInputContext **ppEnum);
  308. };