2 * @file scim_trans_commands.h
3 * @brief Transaction commands.
6 /* ISF is based on SCIM 1.4.7 and extended for supporting more mobile fitable. */
9 * Smart Common Input Method
11 * Copyright (c) 2002-2005 James Su <suzhe@tsinghua.org.cn>
14 * This library is free software; you can redistribute it and/or
15 * modify it under the terms of the GNU Lesser General Public
16 * License as published by the Free Software Foundation; either
17 * version 2 of the License, or (at your option) any later version.
19 * This library is distributed in the hope that it will be useful,
20 * but WITHOUT ANY WARRANTY; without even the implied warranty of
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22 * GNU Lesser General Public License for more details.
24 * You should have received a copy of the GNU Lesser General Public
25 * License along with this program; if not, write to the
26 * Free Software Foundation, Inc., 59 Temple Place, Suite 330,
27 * Boston, MA 02111-1307 USA
29 * $Id: scim_trans_commands.h,v 1.9 2005/06/26 16:35:33 suzhe Exp $
32 #ifndef __SCIM_TRANS_COMMANDS_H
33 #define __SCIM_TRANS_COMMANDS_H
38 * @brief Transaction command types used by Socket Frontend/IMEngine/Config, Helper and Panel.
40 * This commands are used in communication protocols of SocketFrontEnd, SocketIMEngine, SocketConfig, Helper and Panel.
42 * There are mainly four major protocols used in the communications among each part of SCIM:
43 * - between SocketFrontEnd and SocketIMEngine (SocketFrontEnd is server)
44 * - between SocketFrontEnd and SocketConfig (SocketFrontEnd is server)
45 * - between Panel and FrontEnds (eg. X11 FrontEnd, Gtk IMModule and QT IMModule. Panel is server)
46 * - between Panel and Helper (Panel is server).
48 * As soon as the socket to the server is established, the client must call function
49 * scim_socket_open_connection() to create the connection and get the magic key for later communication.
51 * At the same time, the server must call function scim_socket_accept_connection() to
52 * accept the connection and get the same magic key for later client verification.
54 * The valid types of servers are:
55 * - "SocketFrontEnd"\n
56 * The socket FrontEnd server provides remote IMEngine and Config services.
57 * It accepts "SocketIMEngine" and "SocketConfig" clients.
59 * The Panel server provides GUI and Helper management services.
60 * It accepts "FrontEnd" and "Helper" clients.
62 * The valid types of clients are:
63 * - "SocketIMEngine"\n
64 * The socket IMEngine client acts as a proxy IMEngine forwarding all requests to SocketFrontEnd.
65 * It can only connect to "SocketFrontEnd" server.
67 * The socket Config client acts as a proxy Config forwarding all request to SocketFrontEnd.
68 * It can only connect to "SocketFrontEnd" server.
70 * If a FrontEnd needs a Panel GUI services, it'll be a "FrontEnd" client of the Panel.
71 * It can only connect to "Panel" server.
73 * All Helper objects should be "Helper" clients of a Panel.
74 * It can only connect to "Panel" server.
76 * Then the client and the server can communicate with each other via the socket by sending transactions.
78 * Multiple commands and their data may be put into one transaction with a restricted order.
79 * The data of a command must be put into the transaction just follow the command itself.
81 * A transaction sent from a socket client to a socket server (eg. SocketIMEngine to SocketFrontEnd)
82 * must be started with a SCIM_TRANS_CMD_REQUEST command followed by an uint32 magic key of the client
83 * (returned by scim_socket_open_connection() function.
85 * A transaction sent back to a socket client from a socket server must be started with a
86 * SCIM_TRANS_CMD_REPLY command.
88 * So for example, the layout of a transaction sent from SocketIMEngine to SocketFrontEnd may look like:
89 * - #SCIM_TRANS_CMD_REQUEST
90 * - an uint32 data (the magic key of a client)
91 * - #SCIM_TRANS_CMD_PROCESS_KEY_EVENT
92 * - an uint32 data (the id of the IMEngineInstance object used to process the KeyEvent)
93 * - a scim::KeyEvent data (the KeyEvent to be processed)
95 * Some commands may be used in more than one protocols for similar purpose, but they may have different
96 * data in different protocol.
98 * <b>Brief introduction of communication protocols used in SCIM:</b>
100 * Please refer to the descriptions of each Transaction commands for details.
102 * -# <b>Protocol used between SocketIMEngine and SocketFrontEnd</b>\n
103 * In this protocol, SocketFrontEnd is socket server, SocketIMEngine is client.
104 * - <b>from SocketIMEngine to SocketFrontEnd:</b>\n
105 * The Transaction sent from SocketIMEngine to SocketFrontEnd must
106 * start with #SCIM_TRANS_CMD_REQUEST and followed by an uint32 magic
107 * key which was returned by scim_socket_open_connection() and
108 * scim_socket_accept_connection().\n
109 * Before parsing the Transaction,
110 * SocketFrontEnd must verify if the magic key is matched.
111 * If the magic key is not matched, then SocketFrontEnd should just
112 * discard this transaction.\n
113 * There can be one or more commands and corresponding data right after the
115 * The valid commands which can be used here are:
116 * - #SCIM_TRANS_CMD_NEW_INSTANCE
117 * - #SCIM_TRANS_CMD_DELETE_INSTANCE
118 * - #SCIM_TRANS_CMD_DELETE_ALL_INSTANCES
119 * - #SCIM_TRANS_CMD_GET_FACTORY_LIST
120 * - #SCIM_TRANS_CMD_GET_FACTORY_NAME
121 * - #SCIM_TRANS_CMD_GET_FACTORY_AUTHORS
122 * - #SCIM_TRANS_CMD_GET_FACTORY_CREDITS
123 * - #SCIM_TRANS_CMD_GET_FACTORY_HELP
124 * - #SCIM_TRANS_CMD_GET_FACTORY_LOCALES
125 * - #SCIM_TRANS_CMD_GET_FACTORY_ICON_FILE
126 * - #SCIM_TRANS_CMD_GET_FACTORY_LANGUAGE
127 * - #SCIM_TRANS_CMD_PROCESS_KEY_EVENT
128 * - #SCIM_TRANS_CMD_MOVE_PREEDIT_CARET
129 * - #SCIM_TRANS_CMD_SELECT_CANDIDATE
130 * - #SCIM_TRANS_CMD_UPDATE_LOOKUP_TABLE_PAGE_SIZE
131 * - #SCIM_TRANS_CMD_LOOKUP_TABLE_PAGE_UP
132 * - #SCIM_TRANS_CMD_LOOKUP_TABLE_PAGE_DOWN
133 * - #SCIM_TRANS_CMD_RESET
134 * - #SCIM_TRANS_CMD_FOCUS_IN
135 * - #SCIM_TRANS_CMD_FOCUS_OUT
136 * - #SCIM_TRANS_CMD_TRIGGER_PROPERTY
137 * - #SCIM_TRANS_CMD_PROCESS_HELPER_EVENT
138 * - #SCIM_TRANS_CMD_UPDATE_CLIENT_CAPABILITIES
139 * - #SCIM_TRANS_CMD_LOAD_FILE
140 * - #SCIM_TRANS_CMD_CLOSE_CONNECTION
141 * - <b>from SocketFrontEnd to SocketIMEngine:</b>\n
142 * The Transaction sent back from SocketFrontEnd to SocketIMEngine must
143 * start with #SCIM_TRANS_CMD_REPLY and end with #SCIM_TRANS_CMD_OK or
144 * #SCIM_TRANS_CMD_FAIL to indicate if the request previously sent by
145 * SocketIMEngine was executed successfully.\n
146 * For some requests, like SCIM_TRANS_CMD_GET_FACTORY_LIST, etc.
147 * only some result data will be returned between #SCIM_TRANS_CMD_REPLY and #SCIM_TRANS_CMD_OK.\n
148 * For some requests, like SCIM_TRANS_CMD_PROCESS_KEY_EVENT, etc.
149 * one or more following commands and corresponding data may be returned between
150 * #SCIM_TRANS_CMD_REPLY and #SCIM_TRANS_CMD_OK commands.\n
151 * The valid commands can be used here are:
152 * - #SCIM_TRANS_CMD_SHOW_PREEDIT_STRING
153 * - #SCIM_TRANS_CMD_SHOW_AUX_STRING
154 * - #SCIM_TRANS_CMD_SHOW_LOOKUP_TABLE
155 * - #SCIM_TRANS_CMD_HIDE_PREEDIT_STRING
156 * - #SCIM_TRANS_CMD_HIDE_AUX_STRING
157 * - #SCIM_TRANS_CMD_HIDE_LOOKUP_TABLE
158 * - #SCIM_TRANS_CMD_UPDATE_PREEDIT_CARET
159 * - #SCIM_TRANS_CMD_UPDATE_PREEDIT_STRING
160 * - #SCIM_TRANS_CMD_UPDATE_AUX_STRING
161 * - #SCIM_TRANS_CMD_UPDATE_LOOKUP_TABLE
162 * - #SCIM_TRANS_CMD_COMMIT_STRING
163 * - #SCIM_TRANS_CMD_FORWARD_KEY_EVENT
164 * - #SCIM_TRANS_CMD_REGISTER_PROPERTIES
165 * - #SCIM_TRANS_CMD_UPDATE_PROPERTY
166 * - #SCIM_TRANS_CMD_BEEP
167 * - #SCIM_TRANS_CMD_START_HELPER
168 * - #SCIM_TRANS_CMD_STOP_HELPER
169 * - #SCIM_TRANS_CMD_SEND_HELPER_EVENT
170 * -# <b>Protocol used between SocketConfig and SocketFrontEnd</b>\n
171 * In this protocol, SocketFrontEnd is socket server, SocketConfig is client.
172 * - <b>from SocketConfig to SocketFrontEnd:</b>\n
173 * The Transaction sent from SocketConfig to SocketFrontEnd must
174 * start with #SCIM_TRANS_CMD_REQUEST and followed by an uint32 magic
175 * key which was returned by scim_socket_open_connection() and
176 * scim_socket_accept_connection().\n
177 * Before parsing the Transaction,
178 * SocketFrontEnd must verify if the magic key is matched.
179 * If the magic key is not matched, then SocketFrontEnd should just
180 * discard this transaction.\n
181 * There can be one or more commands and corresponding data right after the
183 * The valid commands which can be used here are:
184 * - #SCIM_TRANS_CMD_FLUSH_CONFIG
185 * - #SCIM_TRANS_CMD_ERASE_CONFIG
186 * - #SCIM_TRANS_CMD_GET_CONFIG_STRING
187 * - #SCIM_TRANS_CMD_SET_CONFIG_STRING
188 * - #SCIM_TRANS_CMD_GET_CONFIG_INT
189 * - #SCIM_TRANS_CMD_SET_CONFIG_INT
190 * - #SCIM_TRANS_CMD_GET_CONFIG_BOOL
191 * - #SCIM_TRANS_CMD_SET_CONFIG_BOOL
192 * - #SCIM_TRANS_CMD_GET_CONFIG_DOUBLE
193 * - #SCIM_TRANS_CMD_SET_CONFIG_DOUBLE
194 * - #SCIM_TRANS_CMD_GET_CONFIG_VECTOR_STRING
195 * - #SCIM_TRANS_CMD_SET_CONFIG_VECTOR_STRING
196 * - #SCIM_TRANS_CMD_GET_CONFIG_VECTOR_INT
197 * - #SCIM_TRANS_CMD_SET_CONFIG_VECTOR_INT
198 * - #SCIM_TRANS_CMD_RELOAD_CONFIG
199 * - #SCIM_TRANS_CMD_LOAD_FILE
200 * - #SCIM_TRANS_CMD_CLOSE_CONNECTION
201 * - <b>from SocketFrontEnd to SocketConfig:</b>\n
202 * The Transaction sent back from SocketFrontEnd to SocketConfig must
203 * start with #SCIM_TRANS_CMD_REPLY and end with #SCIM_TRANS_CMD_OK or
204 * #SCIM_TRANS_CMD_FAIL to indicate if the request previously sent by
205 * SocketConfig was executed successfully.\n
206 * For some requests, like SCIM_TRANS_CMD_FLUSH_CONFIG, etc.
207 * no result data will be returned.\n
208 * For some requests, like SCIM_TRANS_CMD_GET_CONFIG_STRING, etc.
209 * the corresponding data will be returned between
210 * #SCIM_TRANS_CMD_REPLY and #SCIM_TRANS_CMD_OK commands.\n
211 * -# <b>Protocol used between FrontEnds and Panel</b>\n
212 * In this protocol, Panel (eg. scim-panel-gtk or scim-panel-kde) is socket server, FrontEnds are clients.
213 * - <b>from FrontEnds to Panel:</b>\n
214 * The Transaction sent from FrontEnds to Panel must
215 * start with #SCIM_TRANS_CMD_REQUEST and followed by an uint32 magic
216 * key which was returned by scim_socket_open_connection() and
217 * scim_socket_accept_connection(). Then there must be an uint32 id
218 * for current focused input context right after the magic key.\n
219 * Before parsing the Transaction,
220 * Panel must verify if the magic key is matched.
221 * If the magic key is not matched, then Panel should just
222 * discard this transaction.\n
223 * There can be one or more commands and corresponding data right after the
225 * The valid commands which can be used here are:
226 * - #SCIM_TRANS_CMD_UPDATE_SCREEN
227 * - #SCIM_TRANS_CMD_UPDATE_SPOT_LOCATION
228 * - #SCIM_TRANS_CMD_PANEL_TURN_ON
229 * - #SCIM_TRANS_CMD_PANEL_TURN_OFF
230 * - #SCIM_TRANS_CMD_PANEL_UPDATE_FACTORY_INFO
231 * - #SCIM_TRANS_CMD_PANEL_SHOW_HELP
232 * - #SCIM_TRANS_CMD_PANEL_SHOW_FACTORY_MENU
233 * - #SCIM_TRANS_CMD_SHOW_PREEDIT_STRING
234 * - #SCIM_TRANS_CMD_SHOW_AUX_STRING
235 * - #SCIM_TRANS_CMD_SHOW_LOOKUP_TABLE
236 * - #SCIM_TRANS_CMD_HIDE_PREEDIT_STRING
237 * - #SCIM_TRANS_CMD_HIDE_AUX_STRING
238 * - #SCIM_TRANS_CMD_HIDE_LOOKUP_TABLE
239 * - #SCIM_TRANS_CMD_UPDATE_PREEDIT_CARET
240 * - #SCIM_TRANS_CMD_UPDATE_PREEDIT_STRING
241 * - #SCIM_TRANS_CMD_UPDATE_AUX_STRING
242 * - #SCIM_TRANS_CMD_UPDATE_LOOKUP_TABLE
243 * - #SCIM_TRANS_CMD_REGISTER_PROPERTIES
244 * - #SCIM_TRANS_CMD_UPDATE_PROPERTY
245 * - #SCIM_TRANS_CMD_START_HELPER
246 * - #SCIM_TRANS_CMD_STOP_HELPER
247 * - #SCIM_TRANS_CMD_SEND_HELPER_EVENT
248 * - <b>from Panel to FrontEnds:</b>\n
249 * The Transaction sent from Panel to FrontEnds must
250 * start with #SCIM_TRANS_CMD_REPLY.
251 * For the following commands except
252 * #SCIM_TRANS_CMD_RELOAD_CONFIG and #SCIM_TRANS_CMD_EXIT,
253 * there must be an uint32 id of the currently focused input context
254 * right after the #SCIM_TRANS_CMD_REPLY command.
255 * Then there can be one or more commands and corresponding data following.\n
256 * The valid commands which can be used here are:
257 * - #SCIM_TRANS_CMD_RELOAD_CONFIG
258 * - #SCIM_TRANS_CMD_EXIT
259 * - #SCIM_TRANS_CMD_UPDATE_LOOKUP_TABLE_PAGE_SIZE
260 * - #SCIM_TRANS_CMD_LOOKUP_TABLE_PAGE_UP
261 * - #SCIM_TRANS_CMD_LOOKUP_TABLE_PAGE_DOWN
262 * - #SCIM_TRANS_CMD_PROCESS_KEY_EVENT
263 * - #SCIM_TRANS_CMD_MOVE_PREEDIT_CARET
264 * - #SCIM_TRANS_CMD_SELECT_CANDIDATE
265 * - #SCIM_TRANS_CMD_TRIGGER_PROPERTY
266 * - #SCIM_TRANS_CMD_PROCESS_HELPER_EVENT
267 * - #SCIM_TRANS_CMD_COMMIT_STRING
268 * - #SCIM_TRANS_CMD_FORWARD_KEY_EVENT
269 * - #SCIM_TRANS_CMD_PANEL_REQUEST_HELP
270 * - #SCIM_TRANS_CMD_PANEL_REQUEST_FACTORY_MENU
271 * - #SCIM_TRANS_CMD_PANEL_CHANGE_FACTORY
272 * -# <b>Protocol used between Helper and Panel</b>\n
273 * In this protocol, Panel (eg. scim-panel-gtk or scim-panel-kde) is socket server, Helper is client.
274 * - <b>from Helper to Panel:</b>\n
275 * The Transaction sent from Helper to Panel must
276 * start with #SCIM_TRANS_CMD_REQUEST and followed by an uint32 magic
277 * key which was returned by scim_socket_open_connection() and
278 * scim_socket_accept_connection().
279 * Before parsing the Transaction,
280 * Panel must verify if the magic key is matched.
281 * If the magic key is not matched, then Panel should just
282 * discard this transaction.\n
283 * There can be one or more commands and corresponding data right after the
285 * The valid commands which can be used here are:
286 * - #SCIM_TRANS_CMD_PANEL_REGISTER_HELPER
287 * - #SCIM_TRANS_CMD_PANEL_SEND_IMENGINE_EVENT
288 * - #SCIM_TRANS_CMD_PANEL_SEND_KEY_EVENT
289 * - #SCIM_TRANS_CMD_REGISTER_PROPERTIES
290 * - #SCIM_TRANS_CMD_UPDATE_PROPERTY
291 * - #SCIM_TRANS_CMD_FORWARD_KEY_EVENT
292 * - #SCIM_TRANS_CMD_COMMIT_STRING
293 * - <b>from Panel to Helper:</b>\n
294 * The Transaction sent from Panel to Helper must
295 * start with #SCIM_TRANS_CMD_REPLY and followed by an
296 * uint32 input context id and a scim::String input context UUID.
297 * Then there can be one or more commands and corresponding data just after the UUID.\n
298 * The valid commands which can be used here are:
299 * - #SCIM_TRANS_CMD_EXIT
300 * - #SCIM_TRANS_CMD_UPDATE_SCREEN
301 * - #SCIM_TRANS_CMD_UPDATE_SPOT_LOCATION
302 * - #SCIM_TRANS_CMD_TRIGGER_PROPERTY
303 * - #SCIM_TRANS_CMD_HELPER_PROCESS_IMENGINE_EVENT
305 * @addtogroup TransactionCommands
306 * @ingroup InputServiceFramework
310 /// Unknown command. No use.
311 #ifndef SCIM_TRANS_CMD_UNKNOWN
312 #define SCIM_TRANS_CMD_UNKNOWN 0
318 * @brief It's the first command which should be put into the Transaction
319 * sending from a socket client to a socket server.
321 * The corresponding data for this command is an uint32 magic key
322 * which is returned by scim_socket_open_connection() function.
325 #ifndef SCIM_TRANS_CMD_REQUEST
326 #define SCIM_TRANS_CMD_REQUEST 1
330 * @brief It's the first command which should be put into the Transaction
331 * sending from a socket server to a socket client.
333 * The corresponding data for this command is different in
334 * each protocol. Please refer to the previous protocol notes for details.
337 #ifndef SCIM_TRANS_CMD_REPLY
338 #define SCIM_TRANS_CMD_REPLY 2
342 * @brief This command is usually used in the Transaction sending from
343 * a socket server to a socket client to indicate that the request
344 * previously sent from the client was executed successfully.
346 * There is no data for this command.
349 #ifndef SCIM_TRANS_CMD_OK
350 #define SCIM_TRANS_CMD_OK 3
354 * @brief This command is usually used in the Transaction sending from
355 * a socket server to a socket client to indicate that the request
356 * previously sent from the client was failed to be executed.
358 * There is no data for this command.
361 #ifndef SCIM_TRANS_CMD_FAIL
362 #define SCIM_TRANS_CMD_FAIL 4
366 * @brief This command is used internally by scim_socket_open_connection() and
367 * scim_socket_accept_connection().
369 * It's sent from a socket client to a socket server to
370 * request the server to create the connection.
372 * The corresponding data are:
373 * - (scim::String) a version string (the binary version of SCIM).
374 * - (scim::String) type of the client, eg. "SocketIMEngine", "FrontEnd", "Helper" etc.
376 * If the socket server accept the connection request, it must send back a Transaction with
378 * - #SCIM_TRANS_CMD_REPLY
379 * - (scim::String) a comma separated server types which are supported by the server, eg. "SocketFrontEnd" etc.
380 * - (uint32) a magic key used to validate the communication later.
382 * Then if the client accept the result too, it must send the following content back to the
384 * - #SCIM_TRANS_CMD_REPLY
385 * - #SCIM_TRANS_CMD_OK
387 * Otherwise, the client must return:
388 * - #SCIM_TRANS_CMD_REPLY
389 * - #SCIM_TRANS_CMD_FAIL
391 * If the socket server do not accept the connection in the first stage, it should discard the request and send
395 #ifndef SCIM_TRANS_CMD_OPEN_CONNECTION
396 #define SCIM_TRANS_CMD_OPEN_CONNECTION 5
400 * @brief It's used to request the socket server to close the connection forcedly.
402 * It's currently not used at all.
405 #ifndef SCIM_TRANS_CMD_CLOSE_CONNECTION
406 #define SCIM_TRANS_CMD_CLOSE_CONNECTION 6
410 * @brief Request the socket server to load and send a file to the client.
412 * The corresponding data is:
413 * - (scim::String) the full file path to be loaded.
415 * If the file is loaded successfully, then the server should send back:
416 * - #SCIM_TRANS_CMD_REPLY
417 * - (raw buffer) the buffer which holds the file content.
418 * - #SCIM_TRANS_CMD_OK
420 * Otherwise it should send back:
421 * - #SCIM_TRANS_CMD_REPLY
422 * - #SCIM_TRANS_CMD_FAIL
424 * This command is only supported by SocketFrontEnd.
427 #ifndef SCIM_TRANS_CMD_LOAD_FILE
428 #define SCIM_TRANS_CMD_LOAD_FILE 7
432 * @brief Request the socket server to save a buffer into a file.
434 * The corresponding data is:
435 * - (scim::String) the full file path to be used to save the buffer.
436 * - (raw buffer) the buffer to be saved.
438 * If the file is saved successfully, then the server should return:
439 * - #SCIM_TRANS_CMD_REPLY
440 * - #SCIM_TRANS_CMD_OK
442 * Otherwise it should return:
443 * - #SCIM_TRANS_CMD_REPLY
444 * - #SCIM_TRANS_CMD_FAIL
446 * This command is currently not supported by any servers.
449 #ifndef SCIM_TRANS_CMD_SAVE_FILE
450 #define SCIM_TRANS_CMD_SAVE_FILE 8
454 * @brief This command should be sent from a socket server to its clients to let them exit.
456 * No data is associated to this command.
458 * This command is currently only used by Panel server.
461 #ifndef SCIM_TRANS_CMD_EXIT
462 #define SCIM_TRANS_CMD_EXIT 99
465 // Socket IMEngine to Socket FrontEnd
468 * @brief This command is used in SocketIMEngine to SocketFrontEnd and
469 * Panel to FrontEnd protocols to send a KeyEvent to an IMEngineInstance.
471 * When used in SocketIMEngine to SocketFrontEnd protocol,
472 * the corresponding data is:
473 * - (uint32) the id of the IMEngineInstance to process the KeyEvent.
474 * - (KeyEvent) the KeyEvent object to be processed.
476 * The Transaction returned from SocketFrontEnd should contain:
477 * - #SCIM_TRANS_CMD_REPLY
478 * - (any valid commands and their corresponding data)
479 * - #SCIM_TRANS_CMD_OK or #SCIM_TRANS_CMD_FAIL to indicate
480 * that if the KeyEvent was processed successfully.
482 * When used in Panel to FrontEnds protocol, the corresponding data is:
483 * - (KeyEvent) the KeyEvent object to be processed.
485 const int SCIM_TRANS_CMD_PROCESS_KEY_EVENT = 100;
486 const int SCIM_TRANS_CMD_MOVE_PREEDIT_CARET = 101;
487 const int SCIM_TRANS_CMD_SELECT_CANDIDATE = 102;
488 const int SCIM_TRANS_CMD_UPDATE_LOOKUP_TABLE_PAGE_SIZE = 103;
489 const int SCIM_TRANS_CMD_LOOKUP_TABLE_PAGE_UP = 104;
490 const int SCIM_TRANS_CMD_LOOKUP_TABLE_PAGE_DOWN = 105;
491 const int SCIM_TRANS_CMD_RESET = 106;
492 const int SCIM_TRANS_CMD_FOCUS_IN = 107;
493 const int SCIM_TRANS_CMD_FOCUS_OUT = 108;
494 const int SCIM_TRANS_CMD_TRIGGER_PROPERTY = 109;
495 const int SCIM_TRANS_CMD_PROCESS_HELPER_EVENT = 110;
496 const int SCIM_TRANS_CMD_UPDATE_CLIENT_CAPABILITIES = 111;
497 const int ISM_TRANS_CMD_SELECT_ASSOCIATE = 112;
498 const int ISM_TRANS_CMD_UPDATE_ASSOCIATE_TABLE_PAGE_SIZE = 113;
499 const int ISM_TRANS_CMD_ASSOCIATE_TABLE_PAGE_UP = 114;
500 const int ISM_TRANS_CMD_ASSOCIATE_TABLE_PAGE_DOWN = 115;
501 const int ISM_TRANS_CMD_SELECT_AUX = 116;
502 const int ISM_TRANS_CMD_SET_PREDICTION_ALLOW = 117;
503 const int ISM_TRANS_CMD_UPDATE_CANDIDATE_ITEM_LAYOUT = 118;
504 const int SCIM_TRANS_CMD_SET_AUTOCAPITAL_TYPE = 119;
506 // Socket FrontEnd to Socket IMEngine
507 // FrontEnds to Panel
508 const int SCIM_TRANS_CMD_SHOW_PREEDIT_STRING = 150;
509 const int SCIM_TRANS_CMD_SHOW_AUX_STRING = 151;
510 const int SCIM_TRANS_CMD_SHOW_LOOKUP_TABLE = 152;
511 const int SCIM_TRANS_CMD_HIDE_PREEDIT_STRING = 153;
512 const int SCIM_TRANS_CMD_HIDE_AUX_STRING = 154;
513 const int SCIM_TRANS_CMD_HIDE_LOOKUP_TABLE = 155;
514 const int SCIM_TRANS_CMD_UPDATE_PREEDIT_CARET = 156;
515 const int SCIM_TRANS_CMD_UPDATE_PREEDIT_STRING = 157;
516 const int SCIM_TRANS_CMD_UPDATE_AUX_STRING = 158;
517 const int SCIM_TRANS_CMD_UPDATE_LOOKUP_TABLE = 159;
518 const int SCIM_TRANS_CMD_COMMIT_STRING = 160;
519 const int SCIM_TRANS_CMD_FORWARD_KEY_EVENT = 161;
520 const int SCIM_TRANS_CMD_REGISTER_PROPERTIES = 162;
521 const int SCIM_TRANS_CMD_UPDATE_PROPERTY = 163;
522 const int SCIM_TRANS_CMD_BEEP = 164;
523 const int SCIM_TRANS_CMD_START_HELPER = 165;
524 const int SCIM_TRANS_CMD_STOP_HELPER = 166;
525 const int SCIM_TRANS_CMD_SEND_HELPER_EVENT = 167;
526 const int SCIM_TRANS_CMD_GET_SURROUNDING_TEXT = 168;
527 const int SCIM_TRANS_CMD_DELETE_SURROUNDING_TEXT = 169;
528 const int ISM_TRANS_CMD_SHOW_ASSOCIATE_TABLE = 170;
529 const int ISM_TRANS_CMD_HIDE_ASSOCIATE_TABLE = 171;
530 const int ISM_TRANS_CMD_UPDATE_ASSOCIATE_TABLE = 172;
531 const int ISM_TRANS_CMD_TRANSACTION_CONTINUE = 173;
532 const int SCIM_TRANS_CMD_GET_SELECTION = 174;
533 const int SCIM_TRANS_CMD_SET_SELECTION = 175;
534 const int SCIM_TRANS_CMD_SEND_PRIVATE_COMMAND = 176;
535 const int SCIM_TRANS_CMD_COMMIT_CONTENT = 177;
536 const int SCIM_TRANS_CMD_PING = 178;
539 // Socket IMEngine to Socket FrontEnd
540 const int SCIM_TRANS_CMD_NEW_INSTANCE = 200;
541 const int SCIM_TRANS_CMD_DELETE_INSTANCE = 201;
542 const int SCIM_TRANS_CMD_DELETE_ALL_INSTANCES = 202;
544 const int SCIM_TRANS_CMD_GET_FACTORY_LIST = 203;
545 const int SCIM_TRANS_CMD_GET_FACTORY_NAME = 204;
546 const int SCIM_TRANS_CMD_GET_FACTORY_AUTHORS = 205;
547 const int SCIM_TRANS_CMD_GET_FACTORY_CREDITS = 206;
548 const int SCIM_TRANS_CMD_GET_FACTORY_HELP = 207;
549 const int SCIM_TRANS_CMD_GET_FACTORY_LOCALES = 208;
550 const int SCIM_TRANS_CMD_GET_FACTORY_ICON_FILE = 209;
551 const int SCIM_TRANS_CMD_GET_FACTORY_LANGUAGE = 210;
553 // Socket Config to Socket FrontEnd
554 const int SCIM_TRANS_CMD_FLUSH_CONFIG = 300;
555 const int SCIM_TRANS_CMD_ERASE_CONFIG = 301;
556 const int SCIM_TRANS_CMD_GET_CONFIG_STRING = 302;
557 const int SCIM_TRANS_CMD_SET_CONFIG_STRING = 303;
558 const int SCIM_TRANS_CMD_GET_CONFIG_INT = 304;
559 const int SCIM_TRANS_CMD_SET_CONFIG_INT = 305;
560 const int SCIM_TRANS_CMD_GET_CONFIG_BOOL = 306;
561 const int SCIM_TRANS_CMD_SET_CONFIG_BOOL = 307;
562 const int SCIM_TRANS_CMD_GET_CONFIG_DOUBLE = 308;
563 const int SCIM_TRANS_CMD_SET_CONFIG_DOUBLE = 309;
564 const int SCIM_TRANS_CMD_GET_CONFIG_VECTOR_STRING = 310;
565 const int SCIM_TRANS_CMD_SET_CONFIG_VECTOR_STRING = 311;
566 const int SCIM_TRANS_CMD_GET_CONFIG_VECTOR_INT = 312;
567 const int SCIM_TRANS_CMD_SET_CONFIG_VECTOR_INT = 313;
568 const int SCIM_TRANS_CMD_RELOAD_CONFIG = 314;
570 // Used by Panel and Helper
571 const int SCIM_TRANS_CMD_UPDATE_SCREEN = 400;
572 const int SCIM_TRANS_CMD_UPDATE_SPOT_LOCATION = 401;
573 const int ISM_TRANS_CMD_UPDATE_CURSOR_POSITION = 402;
574 const int ISM_TRANS_CMD_UPDATE_SURROUNDING_TEXT = 403;
575 const int ISM_TRANS_CMD_UPDATE_SELECTION = 404;
577 // Privately used by panel.
578 const int SCIM_TRANS_CMD_PANEL_EXIT = 500;
580 // FrontEnd Client to Panel
581 const int SCIM_TRANS_CMD_PANEL_TURN_ON = 501;
582 const int SCIM_TRANS_CMD_PANEL_TURN_OFF = 502;
583 const int SCIM_TRANS_CMD_PANEL_UPDATE_FACTORY_INFO = 503;
584 const int SCIM_TRANS_CMD_PANEL_SHOW_HELP = 504;
585 const int SCIM_TRANS_CMD_PANEL_SHOW_FACTORY_MENU = 505;
586 const int SCIM_TRANS_CMD_PANEL_REGISTER_INPUT_CONTEXT = 506;
587 const int SCIM_TRANS_CMD_PANEL_REMOVE_INPUT_CONTEXT = 507;
588 const int SCIM_TRANS_CMD_PANEL_RESET_INPUT_CONTEXT = 508;
590 // Panel to FrontEnd Client
591 const int SCIM_TRANS_CMD_PANEL_REQUEST_HELP = 520;
592 const int SCIM_TRANS_CMD_PANEL_REQUEST_FACTORY_MENU = 521;
593 const int SCIM_TRANS_CMD_PANEL_CHANGE_FACTORY = 522;
594 const int ISM_TRANS_CMD_PANEL_RESET_KEYBOARD_ISE = 523;
595 const int ISM_TRANS_CMD_PANEL_UPDATE_KEYBOARD_ISE = 524;
597 // Helper Client To Panel
598 const int SCIM_TRANS_CMD_PANEL_REGISTER_HELPER = 540;
599 const int SCIM_TRANS_CMD_PANEL_SEND_IMENGINE_EVENT = 541;
600 const int SCIM_TRANS_CMD_PANEL_SEND_KEY_EVENT = 542;
601 const int SCIM_TRANS_CMD_PANEL_REGISTER_ACTIVE_HELPER = 543;
603 // Panel to Helper Client
604 const int SCIM_TRANS_CMD_HELPER_PROCESS_IMENGINE_EVENT = 602;
605 const int SCIM_TRANS_CMD_HELPER_ATTACH_INPUT_CONTEXT = 603;
606 const int SCIM_TRANS_CMD_HELPER_DETACH_INPUT_CONTEXT = 604;
608 // HelperManager Commands
609 const int SCIM_TRANS_CMD_HELPER_MANAGER_GET_HELPER_LIST = 700;
610 const int SCIM_TRANS_CMD_HELPER_MANAGER_RUN_HELPER = 701;
611 const int SCIM_TRANS_CMD_HELPER_MANAGER_STOP_HELPER = 702;
612 const int SCIM_TRANS_CMD_HELPER_MANAGER_SEND_DISPLAY = 703;
613 const int SCIM_TRANS_CMD_HELPER_MANAGER_SEND_ISE_LIST = 704;
614 const int ISM_TRANS_CMD_GET_ACTIVE_ISE_LIST = 705;
615 const int ISM_TRANS_CMD_PRELOAD_KEYBOARD_ISE = 706;
617 /* IMControl to Panel */
618 const int ISM_TRANS_CMD_SHOW_ISE_PANEL = 1000;
619 const int ISM_TRANS_CMD_HIDE_ISE_PANEL = 1001;
620 const int ISM_TRANS_CMD_SHOW_ISF_CONTROL = 1002;
621 const int ISM_TRANS_CMD_HIDE_ISF_CONTROL = 1003;
622 const int ISM_TRANS_CMD_RESET_ISE_OPTION = 1004;
623 const int ISM_TRANS_CMD_SET_ACTIVE_ISE_BY_UUID = 1005;
624 const int ISM_TRANS_CMD_GET_ACTIVE_ISE = 1006;
625 const int ISM_TRANS_CMD_GET_ISE_LIST = 1007;
626 const int ISM_TRANS_CMD_GET_ISE_INFORMATION = 1008;
627 const int ISM_TRANS_CMD_SEND_WILL_SHOW_ACK = 1009;
628 const int ISM_TRANS_CMD_SEND_WILL_HIDE_ACK = 1010;
629 const int ISM_TRANS_CMD_RESET_DEFAULT_ISE = 1011;
630 const int ISM_TRANS_CMD_SET_HARDWARE_KEYBOARD_MODE = 1012;
631 const int ISM_TRANS_CMD_SEND_CANDIDATE_WILL_HIDE_ACK = 1013;
632 const int ISM_TRANS_CMD_GET_PANEL_CLIENT_ID = 1014;
633 const int ISM_TRANS_CMD_REGISTER_PANEL_CLIENT = 1015;
634 const int ISM_TRANS_CMD_GET_ISE_STATE = 1016;
635 const int ISM_TRANS_CMD_GET_ACTIVE_HELPER_OPTION = 1017;
636 const int ISM_TRANS_CMD_SET_INITIAL_ISE_BY_UUID = 1018;
637 const int ISM_TRANS_CMD_GET_ALL_HELPER_ISE_INFO = 1019;
638 const int ISM_TRANS_CMD_SET_ENABLE_HELPER_ISE_INFO = 1020;
639 const int ISM_TRANS_CMD_SHOW_HELPER_ISE_LIST = 1021;
640 const int ISM_TRANS_CMD_SHOW_HELPER_ISE_SELECTOR = 1022;
641 const int ISM_TRANS_CMD_IS_HELPER_ISE_ENABLED = 1023;
642 const int ISM_TRANS_CMD_GET_RECENT_ISE_GEOMETRY = 1024;
643 const int ISM_REMOTE_TRANS_CMD_SEND_INPUT_MESSAGE = 1025;
644 const int ISM_REMOTE_TRANS_CMD_RECV_FOCUS_IN = 1026;
645 const int ISM_REMOTE_TRANS_CMD_RECV_FOCUS_OUT = 1027;
646 const int ISM_REMOTE_TRANS_CMD_RECV_ENTRY_METADATA = 1028;
647 const int ISM_REMOTE_TRANS_CMD_RECV_SURROUNDING_TEXT = 1029;
648 const int ISM_REMOTE_TRANS_CMD_RECV_INPUT_RESOURCE = 1030;
649 const int ISM_REMOTE_TRANS_CMD_CHECK_PRIVILEGE = 1031;
650 const int ISM_REMOTE_TRANS_CMD_DELETE_SURROUNDING_TEXT = 1032;
651 const int ISM_TRANS_CMD_PRELAUNCH_ISE = 1033;
652 const int ISM_REMOTE_TRANS_CMD_RECV_KEY_SYMBOL = 1034;
653 const int ISM_REMOTE_TRANS_CMD_SET_CURSOR_POSITION = 1035;
654 const int ISM_REMOTE_TRANS_CMD_RECV_CURSOR_POSITION = 1036;
656 /* IMControl to ISE */
657 const int ISM_TRANS_CMD_SET_ISE_MODE = 1108;
658 const int ISM_TRANS_CMD_SET_ISE_LANGUAGE = 1109;
659 const int ISM_TRANS_CMD_SET_ISE_IMDATA = 1110;
660 const int ISM_TRANS_CMD_GET_ISE_IMDATA = 1111;
661 const int ISM_TRANS_CMD_GET_ACTIVE_ISE_GEOMETRY = 1112;
662 const int ISM_TRANS_CMD_SET_LAYOUT = 1113;
663 const int ISM_TRANS_CMD_GET_LAYOUT = 1114;
664 const int ISM_TRANS_CMD_SET_CAPS_MODE = 1115;
665 const int ISM_TRANS_CMD_GET_ISE_LANGUAGE_LOCALE = 1116;
666 const int ISM_TRANS_CMD_RESET_ISE_CONTEXT = 1117;
667 const int ISM_TRANS_CMD_SET_RETURN_KEY_TYPE = 1118;
668 const int ISM_TRANS_CMD_GET_RETURN_KEY_TYPE = 1119;
669 const int ISM_TRANS_CMD_SET_RETURN_KEY_DISABLE = 1120;
670 const int ISM_TRANS_CMD_GET_RETURN_KEY_DISABLE = 1121;
671 const int ISM_TRANS_CMD_SET_INPUT_MODE = 1122;
672 const int ISM_TRANS_CMD_SET_INPUT_HINT = 1123;
673 const int ISM_TRANS_CMD_UPDATE_BIDI_DIRECTION = 1124;
674 const int ISM_TRANS_CMD_SHOW_ISE_OPTION_WINDOW = 1125;
675 const int ISM_TRANS_CMD_PROCESS_INPUT_DEVICE_EVENT = 1126;
676 const int ISM_TRANS_CMD_RESUME_ISE_OPTION_WINDOW = 1127;
677 const int ISM_TRANS_CMD_SET_KEYBOARD_MODE = 1128;
678 const int ISM_TRANS_CMD_SET_PREDICTION_HINT = 1129;
679 const int ISM_TRANS_CMD_SET_MIME_TYPE = 1130;
680 const int ISM_TRANS_CMD_FINALIZE_CONTENT = 1131;
681 const int ISM_TRANS_CMD_SET_PREDICTION_HINT_DATA = 1132;
682 const int ISM_TRANS_CMD_SET_OPTIMIZATION_HINT = 1133;
683 const int ISM_TRANS_CMD_GET_ISE_SETTING_APPID = 1134;
684 const int ISM_TRANS_CMD_SET_ISE_ENABLE = 1135;
685 const int ISM_TRANS_CMD_SET_POSITION_ALIGN = 1136;
687 /* ISE/Panel to IMControl */
688 const int ISM_TRANS_CMD_UPDATE_ISE_INPUT_CONTEXT = 1151;
689 const int ISM_TRANS_CMD_UPDATE_ISF_CANDIDATE_PANEL = 1152;
690 const int ISM_TRANS_CMD_UPDATE_ISE_LANGUAGE_LOCALE = 1153;
694 const int ISM_TRANS_CMD_SET_CANDIDATE_UI = 1201;
695 const int ISM_TRANS_CMD_GET_CANDIDATE_UI = 1202;
696 const int ISM_TRANS_CMD_UPDATE_CANDIDATE_UI = 1203;
697 const int ISM_TRANS_CMD_GET_KEYBOARD_ISE_LIST = 1204;
698 const int ISM_TRANS_CMD_UPDATE_KEYBOARD_ISE_LIST = 1205;
699 const int ISM_TRANS_CMD_SET_KEYBOARD_ISE_BY_UUID = 1206;
700 const int ISM_TRANS_CMD_GET_KEYBOARD_ISE = 1207;
701 const int ISM_TRANS_CMD_UPDATE_KEYBOARD_ISE = 1208;
702 const int ISM_TRANS_CMD_SET_CANDIDATE_POSITION = 1209;
703 const int ISM_TRANS_CMD_HIDE_CANDIDATE = 1210;
704 const int ISM_TRANS_CMD_GET_CANDIDATE_GEOMETRY = 1211;
705 const int ISM_TRANS_CMD_UPDATE_CANDIDATE_GEOMETRY = 1212;
706 const int ISM_TRANS_CMD_UPDATE_ISE_GEOMETRY = 1213;
707 const int ISM_TRANS_CMD_EXPAND_CANDIDATE = 1214;
708 const int ISM_TRANS_CMD_CONTRACT_CANDIDATE = 1215;
709 const int ISM_TRANS_CMD_UPDATE_ISE_EXIT = 1216;
710 const int ISM_TRANS_CMD_SELECT_CANDIDATE = 1217;
711 const int ISM_TRANS_CMD_PROCESS_KEY_EVENT_DONE = 1218;
712 const int ISM_TRANS_CMD_REQUEST_ISE_HIDE = 1219;
713 const int ISM_TRANS_CMD_RECAPTURE_STRING = 1220;
714 const int ISM_TRANS_CMD_SET_FLOATING_MODE = 1221;
715 const int ISM_TRANS_CMD_SET_FLOATING_DRAG_ENABLED = 1222;
716 const int ISM_TRANS_CMD_MOVE_RESIZE_FLOATING_WINDOW = 1223;
719 const int ISM_TRANS_CMD_CANDIDATE_MORE_WINDOW_SHOW = 1251;
720 const int ISM_TRANS_CMD_CANDIDATE_MORE_WINDOW_HIDE = 1252;
721 const int ISM_TRANS_CMD_UPDATE_DISPLAYED_CANDIDATE = 1253;
722 const int ISM_TRANS_CMD_LONGPRESS_CANDIDATE = 1254;
723 const int ISM_TRANS_CMD_UPDATE_LOOKUP_TABLE = 1255;
724 const int ISM_TRANS_CMD_CANDIDATE_SHOW = 1256;
725 const int ISM_TRANS_CMD_CANDIDATE_HIDE = 1257;
726 const int ISM_TRANS_CMD_CHECK_OPTION_WINDOW = 1258;
728 const int ISM_TRANS_CMD_TURN_ON_LOG = 1301;
729 const int ISM_TRANS_CMD_FLUSH_BUFFER = 1302;
731 const int SCIM_TRANS_CMD_USER_DEFINED = 10000;
738 #endif //__SCIM_TRANS_COMMANDS_H
741 vi:ts=4:nowrap:ai:expandtab