2 * Copyright (C) 2007 CodeWeavers, Aric Stewart
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 __WINE_IMMDEV_H
20 #define __WINE_IMMDEV_H
26 typedef struct tagINPUTCONTEXT
38 COMPOSITIONFORM cfCompForm
;
39 CANDIDATEFORM cfCandForm
[4];
48 } INPUTCONTEXT
, *LPINPUTCONTEXT
;
50 typedef struct tagIMEINFO
52 DWORD dwPrivateDataSize
;
54 DWORD fdwConversionCaps
;
55 DWORD fdwSentenceCaps
;
59 } IMEINFO
, *LPIMEINFO
;
61 typedef struct tagCOMPOSITIONSTRING
64 DWORD dwCompReadAttrLen
;
65 DWORD dwCompReadAttrOffset
;
66 DWORD dwCompReadClauseLen
;
67 DWORD dwCompReadClauseOffset
;
68 DWORD dwCompReadStrLen
;
69 DWORD dwCompReadStrOffset
;
71 DWORD dwCompAttrOffset
;
72 DWORD dwCompClauseLen
;
73 DWORD dwCompClauseOffset
;
75 DWORD dwCompStrOffset
;
78 DWORD dwResultReadClauseLen
;
79 DWORD dwResultReadClauseOffset
;
80 DWORD dwResultReadStrLen
;
81 DWORD dwResultReadStrOffset
;
82 DWORD dwResultClauseLen
;
83 DWORD dwResultClauseOffset
;
85 DWORD dwResultStrOffset
;
87 DWORD dwPrivateOffset
;
88 } COMPOSITIONSTRING
, *LPCOMPOSITIONSTRING
;
90 typedef struct tagGUIDELINE
98 DWORD dwPrivateOffset
;
99 } GUIDELINE
, *LPGUIDELINE
;
101 typedef struct tagCANDIDATEINFO
107 DWORD dwPrivateOffset
;
108 } CANDIDATEINFO
, *LPCANDIDATEINFO
;
110 typedef struct tagTRANSMSG
115 } TRANSMSG
, *LPTRANSMSG
;
117 typedef struct tagTRANSMSGLIST
120 TRANSMSG TransMsg
[1];
121 } TRANSMSGLIST
, *LPTRANSMSGLIST
;
123 LPINPUTCONTEXT WINAPI
ImmLockIMC(HIMC
);
124 BOOL WINAPI
ImmUnlockIMC(HIMC
);
125 DWORD WINAPI
ImmGetIMCLockCount(HIMC
);
126 HIMCC WINAPI
ImmCreateIMCC(DWORD
);
127 HIMCC WINAPI
ImmDestroyIMCC(HIMCC
);
128 LPVOID WINAPI
ImmLockIMCC(HIMCC
);
129 BOOL WINAPI
ImmUnlockIMCC(HIMCC
);
130 DWORD WINAPI
ImmGetIMCCLockCount(HIMCC
);
131 HIMCC WINAPI
ImmReSizeIMCC(HIMCC
, DWORD
);
132 DWORD WINAPI
ImmGetIMCCSize(HIMCC
);
135 #define IMMGWL_PRIVATE (sizeof(LONG_PTR))
137 #define INIT_STATUSWNDPOS 0x00000001
138 #define INIT_CONVERSION 0x00000002
139 #define INIT_SENTENCE 0x00000004
140 #define INIT_LOGFONT 0x00000008
141 #define INIT_COMPFORM 0x00000010
142 #define INIT_SOFTKBDPOS 0x00000020
144 /* IME Property bits */
145 #define IME_PROP_END_UNLOAD 0x0001
146 #define IME_PROP_KBD_CHAR_FIRST 0x0002
147 #define IME_PROP_IGNORE_UPKEYS 0x0004
148 #define IME_PROP_NEED_ALTKEY 0x0008
149 #define IME_PROP_NO_KEYS_ON_CLOSE 0x0010
151 /* for NI_CONTEXTUPDATED */
152 #define IMC_SETCONVERSIONMODE 0x0002
153 #define IMC_SETSENTENCEMODE 0x0004
154 #define IMC_SETOPENSTATUS 0x0006
156 /* dwAction for ImmNotifyIME */
157 #define NI_CONTEXTUPDATED 0x0003
158 #define NI_OPENCANDIDATE 0x0010
159 #define NI_CLOSECANDIDATE 0x0011
160 #define NI_SELECTCANDIDATESTR 0x0012
161 #define NI_CHANGECANDIDATELIST 0x0013
162 #define NI_FINALIZECONVERSIONRESULT 0x0014
163 #define NI_COMPOSITIONSTR 0x0015
164 #define NI_SETCANDIDATE_PAGESTART 0x0016
165 #define NI_SETCANDIDATE_PAGESIZE 0x0017
166 #define NI_IMEMENUSELECTED 0x0018
168 BOOL WINAPI
ImmGetHotKey(DWORD
,UINT
*,UINT
*,HKL
*);
169 BOOL WINAPI
ImmSetHotKey(DWORD
,UINT
,UINT
,HKL
);
170 BOOL WINAPI
ImmGenerateMessage(HIMC
);
171 LRESULT WINAPI
ImmRequestMessageA(HIMC
, WPARAM
, LPARAM
);
172 LRESULT WINAPI
ImmRequestMessageW(HIMC
, WPARAM
, LPARAM
);
173 #define ImmRequestMessage WINELIB_NAME_AW(ImmRequestMessage)
174 BOOL WINAPI
ImmTranslateMessage(HWND
, UINT
, WPARAM
, LPARAM
);
175 HWND WINAPI
ImmCreateSoftKeyboard(UINT
, UINT
, int, int);
176 BOOL WINAPI
ImmDestroySoftKeyboard(HWND
);
177 BOOL WINAPI
ImmShowSoftKeyboard(HWND
, int);
179 BOOL WINAPI
ImeInquire(LPIMEINFO
, LPWSTR
, DWORD
);
180 BOOL WINAPI
ImeConfigure (HKL
, HWND
, DWORD
, LPVOID
);
181 DWORD WINAPI
ImeConversionList(HIMC
, LPCWSTR
, LPCANDIDATELIST
,DWORD
,UINT
);
182 BOOL WINAPI
ImeDestroy(UINT
);
183 LRESULT WINAPI
ImeEscape(HIMC
, UINT
, LPVOID
);
184 BOOL WINAPI
ImeProcessKey(HIMC
, UINT
, LPARAM
, const LPBYTE
);
185 BOOL WINAPI
ImeSelect(HIMC
, BOOL
);
186 BOOL WINAPI
ImeSetActiveContext(HIMC
, BOOL
);
187 UINT WINAPI
ImeToAsciiEx(UINT
, UINT
, const LPBYTE
, LPTRANSMSGLIST
, UINT
, HIMC
);
188 BOOL WINAPI
NotifyIME(HIMC
, DWORD
, DWORD
, DWORD
);
189 BOOL WINAPI
ImeRegisterWord(LPCWSTR
, DWORD
, LPCWSTR
);
190 BOOL WINAPI
ImeUnregisterWord(LPCWSTR
, DWORD
, LPCWSTR
);
191 UINT WINAPI
ImeGetRegisterWordStyle(UINT
, LPSTYLEBUFW
);
192 UINT WINAPI
ImeEnumRegisterWord(REGISTERWORDENUMPROCW
, LPCWSTR
, DWORD
, LPCWSTR
, LPVOID
);
193 BOOL WINAPI
ImeSetCompositionString(HIMC
, DWORD
, LPCVOID
, DWORD
, LPCVOID
, DWORD
);
194 DWORD WINAPI
ImeGetImeMenuItems(HIMC
, DWORD
, DWORD
, LPIMEMENUITEMINFOW
, LPIMEMENUITEMINFOW
, DWORD
);
200 #endif /* __WINE_IMMDEV_H */