3 * @brief Defines scim::HelperAgent and it's related types.
5 * scim::HelperAgent is a class used to write Client Helper modules.
9 /* ISF is based on SCIM 1.4.7 and extended for supporting more mobile fitable. */
12 * Smart Common Input Method
14 * Copyright (c) 2004-2005 James Su <suzhe@tsinghua.org.cn>
15 * Copyright (c) 2012-2015 Samsung Electronics Co., Ltd.
18 * This library is free software; you can redistribute it and/or
19 * modify it under the terms of the GNU Lesser General Public
20 * License as published by the Free Software Foundation; either
21 * version 2 of the License, or (at your option) any later version.
23 * This library is distributed in the hope that it will be useful,
24 * but WITHOUT ANY WARRANTY; without even the implied warranty of
25 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
26 * GNU Lesser General Public License for more details.
28 * You should have received a copy of the GNU Lesser General Public
29 * License along with this program; if not, write to the
30 * Free Software Foundation, Inc., 59 Temple Place, Suite 330,
31 * Boston, MA 02111-1307 USA
33 * Modifications by Samsung Electronics Co., Ltd.
34 * 1. Add new interface APIs for keyboard ISE
35 * a. expand_candidate (), contract_candidate () and set_candidate_style ()
36 * b. set_keyboard_ise_by_uuid () and reset_keyboard_ise ()
37 * c. get_surrounding_text () and delete_surrounding_text ()
38 * d. show_preedit_string (), hide_preedit_string (), update_preedit_string () and update_preedit_caret ()
39 * e. show_candidate_string (), hide_candidate_string () and update_candidate_string ()
41 * $Id: scim_helper.h,v 1.16 2005/05/24 12:22:51 suzhe Exp $
44 #ifndef __SCIM_HELPER_H
45 #define __SCIM_HELPER_H
47 #include "scim_utility.h"
49 #ifndef SCIM_HELPER_LAUNCHER_PROGRAM
50 #define SCIM_HELPER_LAUNCHER_PROGRAM (SCIM_LIBEXECDIR "/scim-helper-launcher")
57 * @ingroup InputServiceFramework
58 * The accessory classes to help develop and manage Client Helper objects.
61 class EXAPI HelperError: public Exception
64 HelperError (const String& what_arg)
65 : Exception (String("scim::Helper: ") + what_arg) { }
69 * @brief Helper option indicates that it's a stand alone Helper.
71 * Stand alone Helper has no corresponding IMEngine Factory,
72 * Such Helper can not be started by IMEngine Factory.
73 * So Panel must provide a menu, or something else, which contains
74 * all stand alone Helper items, so that user can start them by
77 const uint32 SCIM_HELPER_STAND_ALONE = 1;
80 * @brief Helper option indicates that it must be started
81 * automatically when Panel starts.
83 * If Helper objects want to start itself as soon as
84 * the Panel starts, set this option.
86 const uint32 SCIM_HELPER_AUTO_START = (1<<1);
89 * @brief Helper option indicates that it should be restarted
90 * when it exits abnormally.
92 * This option should not be used with #SCIM_HELPER_STAND_ALONE.
94 const uint32 SCIM_HELPER_AUTO_RESTART = (1<<2);
97 * @brief Helper option indicates that it needs the screen update
100 * Helper object with this option will receive the UPDATE_SCREEN event
101 * when the screen of focused ic is changed.
103 const uint32 SCIM_HELPER_NEED_SCREEN_INFO = (1<<3);
106 * @brief Helper option indicates that it needs the spot location
109 * Helper object with this option will receive the SPOT_LOCATION_INFO event
110 * when the spot location of focused ic is changed.
112 const uint32 SCIM_HELPER_NEED_SPOT_LOCATION_INFO = (1<<4);
115 * @brief ISE option indicates whether helper ISE handles the keyboard keyevent
117 const uint32 ISM_HELPER_PROCESS_KEYBOARD_KEYEVENT = (1<<16);
120 * @brief ISE option indicates whether it should be hidden in control panel.
122 const uint32 ISM_ISE_HIDE_IN_CONTROL_PANEL = (1<<17);
125 * @brief ISE option for 3rd party; IMEngine is not available.
127 const uint32 ISM_HELPER_WITHOUT_IMENGINE = (1<<18);
130 * @brief Structure to hold the information of a Helper object.
134 String uuid; /**< The UUID of this Helper object, replaced with Application ID since tizen 2.4 */
135 String name; /**< The Name of this Helper object, UTF-8 encoding. Deprecated since tizen 2.4 */
136 String icon; /**< The Icon file path of this Helper object. Deprecated since tizen 2.4 */
137 String description; /**< The short description of this Helper object. Deprecated since tizen 2.4 */
138 uint32 option; /**< The options of this Helper object. @sa #SCIM_HELPER_STAND_ALONE etc. Deprecated since tizen 2.4 */
140 HelperInfo (const String &puuid = String (),
141 const String &pname = String (),
142 const String &picon = String (),
143 const String &pdesc = String (),
162 typedef Slot3<void, const HelperAgent *, int, const String &>
165 typedef Slot4<void, const HelperAgent *, int, const String &, const String &>
166 HelperAgentSlotString;
168 typedef Slot4<void, const HelperAgent *, int, const String &, const std::vector<String> &>
169 HelperAgentSlotStringVector;
171 typedef Slot5<void, const HelperAgent *, int, const String &, const String &, const String &>
172 HelperAgentSlotString2;
174 typedef Slot4<void, const HelperAgent *, int, const String &, int>
177 typedef Slot5<void, const HelperAgent *, int, const String &, int, int>
178 HelperAgentSlotIntInt;
180 typedef Slot4<void, const HelperAgent *, int, const String &, const Transaction &>
181 HelperAgentSlotTransaction;
183 typedef Slot4<void, const HelperAgent *, int, const String &, const rectinfo &>
186 typedef Slot2<void, const HelperAgent *, struct rectinfo &>
189 typedef Slot2<void, const HelperAgent *, uint32 &>
190 HelperAgentSlotUintVoid;
192 typedef Slot3<void, const HelperAgent *, int, uint32 &>
193 HelperAgentSlotIntUint;
195 typedef Slot3<void, const HelperAgent *, char *, size_t &>
196 HelperAgentSlotRawVoid;
198 typedef Slot3<void, const HelperAgent *, char **, size_t &>
199 HelperAgentSlotGetRawVoid;
201 typedef Slot4<void, const HelperAgent *, int, char *, size_t &>
202 HelperAgentSlotIntRawVoid;
204 typedef Slot3<void, const HelperAgent *, int, char **>
205 HelperAgentSlotIntGetStringVoid;
207 typedef Slot2<void, const HelperAgent *, const std::vector<uint32> &>
208 HelperAgentSlotUintVector;
210 typedef Slot2<void, const HelperAgent *, LookupTable &>
211 HelperAgentSlotLookupTable;
212 typedef Slot3<void, const HelperAgent *, KeyEvent &, uint32 &>
213 HelperAgentSlotKeyEventUint;
216 * @brief The accessory class to write a Helper object.
218 * This class implements all Socket Transaction protocol between
219 * Helper object and Panel.
221 class EXAPI HelperAgent
223 class HelperAgentImpl;
224 HelperAgentImpl *m_impl;
226 HelperAgent (const HelperAgent &);
227 const HelperAgent & operator = (const HelperAgent &);
234 * @brief Open socket connection to the Panel.
236 * Helper objects and Panel communicate with each other via the Socket
237 * created by Panel, just same as the Socket between FrontEnds and Panel.
239 * Helper object can select/poll on the connection id returned by this function
240 * to see if there are any data available to be read. If any data are available,
241 * Helper object should call HelperAgent::filter_event() to process the data.
243 * This method should be called after the necessary signal-slots are connected.
244 * If this Helper is started by an IMEngine Instance, then signal attach_input_context
245 * will be emitted during this call.
247 * Signal update_screen will be emitted during this call as well to set the startup
248 * screen of this Helper. The ic and ic_uuid parameters are invalid here.
250 * @param info The information of this Helper object.
251 * @param display The display which this Helper object should run on.
253 * @return The connection socket id. -1 means failed to create
256 int open_connection (const HelperInfo &info,
257 const String &display);
260 * @brief Close the socket connection to Panel.
262 void close_connection ();
265 * @brief Get the connection id previously returned by open_connection().
267 * @return the connection id
269 int get_connection_number () const;
272 * @brief Check whether this HelperAgent has been connected to a Panel.
274 * Return true when it is connected to panel, otherwise return false.
276 bool is_connected () const;
279 * @brief Check if there are any events available to be processed.
281 * If it returns true then Helper object should call
282 * HelperAgent::filter_event() to process them.
284 * @return true if there are any events available.
286 bool has_pending_event () const;
289 * @brief Process the pending events.
291 * This function will emit the corresponding signals according
294 * @return false if the connection is broken, otherwise return true.
296 bool filter_event ();
299 * @brief Request SCIM to reload all configuration.
301 * This function should only by used by Setup Helper to request
302 * scim's reloading the configuration.
304 void reload_config () const;
307 * @brief Register some properties into Panel.
309 * This function send the request to Panel to register a list
312 * @param properties The list of Properties to be registered into Panel.
314 * @sa scim::Property.
316 void register_properties (const PropertyList &properties) const;
319 * @brief Update a registered property.
321 * @param property The property to be updated.
323 void update_property (const Property &property) const;
326 * @brief Send a set of events to an IMEngineInstance.
328 * All events should be put into a Transaction.
329 * And the events can only be received by one IMEngineInstance object.
331 * @param ic The handle of the Input Context to receive the events.
332 * @param ic_uuid The UUID of the Input Context.
333 * @param trans The Transaction object holds the events.
335 void send_imengine_event (int ic,
336 const String &ic_uuid,
337 const Transaction &trans) const;
340 * @brief Send a KeyEvent to an IMEngineInstance.
342 * @param ic The handle of the IMEngineInstance to receive the event.
343 * -1 means the currently focused IMEngineInstance.
344 * @param ic_uuid The UUID of the IMEngineInstance. Empty means don't match.
345 * @param key The KeyEvent to be sent.
347 void send_key_event (int ic,
348 const String &ic_uuid,
349 const KeyEvent &key) const;
352 * @brief Forward a KeyEvent to client application directly.
354 * @param ic The handle of the client Input Context to receive the event.
355 * -1 means the currently focused Input Context.
356 * @param ic_uuid The UUID of the IMEngine used by the Input Context.
357 * Empty means don't match.
358 * @param key The KeyEvent to be forwarded.
360 void forward_key_event (int ic,
361 const String &ic_uuid,
362 const KeyEvent &key) const;
365 * @brief Commit a WideString to client application directly.
367 * @param ic The handle of the client Input Context to receive the WideString.
368 * -1 means the currently focused Input Context.
369 * @param ic_uuid The UUID of the IMEngine used by the Input Context.
370 * Empty means don't match.
371 * @param wstr The WideString to be committed.
373 void commit_string (int ic,
374 const String &ic_uuid,
375 const WideString &wstr) const;
378 * @brief Commit a UTF-8 String to client application directly.
380 * @param ic The handle of the client Input Context to receive the commit string.
381 * -1 means the currently focused Input Context.
382 * @param ic_uuid The UUID of the IMEngine used by the Input Context.
383 * Empty means don't match.
384 * @param buf The byte array of UTF-8 string to be committed.
385 * @param buflen The buf size in bytes.
387 void commit_string (int ic,
388 const String &ic_uuid,
393 * @brief Request to show preedit string.
395 * @param ic The handle of the client Input Context to receive the request.
396 * -1 means the currently focused Input Context.
397 * @param ic_uuid The UUID of the IMEngine used by the Input Context.
398 * Empty means don't match.
400 void show_preedit_string (int ic,
401 const String &ic_uuid) const;
404 * @brief Request to show aux string.
406 void show_aux_string (void) const;
409 * @brief Request to show candidate string.
411 void show_candidate_string (void) const;
414 * @brief Request to show associate string.
416 void show_associate_string (void) const;
419 * @brief Request to hide preedit string.
421 * @param ic The handle of the client Input Context to receive the request.
422 * -1 means the currently focused Input Context.
423 * @param ic_uuid The UUID of the IMEngine used by the Input Context.
424 * Empty means don't match.
426 void hide_preedit_string (int ic,
427 const String &ic_uuid) const;
430 * @brief Request to hide aux string.
432 void hide_aux_string (void) const;
435 * @brief Request to hide candidate string.
437 void hide_candidate_string (void) const;
440 * @brief Request to hide associate string.
442 void hide_associate_string (void) const;
445 * @brief Update a new WideString for preedit.
447 * @param ic The handle of the client Input Context to receive the WideString.
448 * -1 means the currently focused Input Context.
449 * @param ic_uuid The UUID of the IMEngine used by the Input Context.
450 * Empty means don't match.
451 * @param wstr The WideString to be updated.
452 * @param attrs The attribute list for preedit string.
454 void update_preedit_string (int ic,
455 const String &ic_uuid,
456 const WideString &wstr,
457 const AttributeList &attrs) const;
460 * @brief Update a new UTF-8 string for preedit.
462 * @param ic The handle of the client Input Context to receive the UTF-8 String.
463 * -1 means the currently focused Input Context.
464 * @param ic_uuid The UUID of the IMEngine used by the Input Context.
465 * Empty means don't match.
466 * @param buf The byte array of UTF-8 string to be updated.
467 * @param buflen The buf size in bytes.
468 * @param attrs The attribute list for preedit string.
470 void update_preedit_string (int ic,
471 const String &ic_uuid,
474 const AttributeList &attrs) const;
477 * @brief Update a new WideString and caret for preedit.
479 * @param ic The handle of the client Input Context to receive the WideString.
480 * -1 means the currently focused Input Context.
481 * @param ic_uuid The UUID of the IMEngine used by the Input Context.
482 * Empty means don't match.
483 * @param wstr The WideString to be updated.
484 * @param attrs The attribute list for preedit string.
485 * @param caret The caret position in preedit string.
487 void update_preedit_string (int ic,
488 const String &ic_uuid,
489 const WideString &wstr,
490 const AttributeList &attrs,
494 * @brief Update a new UTF-8 string and caret for preedit.
496 * @param ic The handle of the client Input Context to receive the UTF-8 String.
497 * -1 means the currently focused Input Context.
498 * @param ic_uuid The UUID of the IMEngine used by the Input Context.
499 * Empty means don't match.
500 * @param buf The byte array of UTF-8 string to be updated.
501 * @param buflen The buf size in bytes.
502 * @param attrs The attribute list for preedit string.
503 * @param caret The caret position in preedit string.
505 void update_preedit_string (int ic,
506 const String &ic_uuid,
509 const AttributeList &attrs,
513 * @brief Update a new string for aux.
515 * @param str The string to be updated.
516 * @param attrs The attribute list for aux string.
518 void update_aux_string (const String &str,
519 const AttributeList &attrs) const;
522 * @brief Request to update candidate.
524 * @param table The lookup table for candidate.
526 void update_candidate_string (const LookupTable &table) const;
529 * @brief Request to update associate.
531 * @param table The lookup table for associate.
533 void update_associate_string (const LookupTable &table) const;
536 * @brief When the input context of ISE is changed,
537 * ISE can call this function to notify application
539 * @param type type of event.
540 * @param value value of event.
542 void update_input_context (uint32 type,
546 * @brief Request to get surrounding text asynchronously.
548 * @param uuid The helper ISE UUID.
549 * @param maxlen_before The max length of before.
550 * @param maxlen_after The max length of after.
552 void get_surrounding_text (const String &uuid,
554 int maxlen_after) const;
557 * @brief Request to get surrounding text synchronously.
559 * @param maxlen_before The max length of before.
560 * @param maxlen_after The max length of after.
561 * @param text The surounding text.
562 * @param cursor The cursor position.
564 void get_surrounding_text (int maxlen_before, int maxlen_after, String &text, int &cursor);
567 * @brief Request to delete surrounding text.
569 * @param offset The offset for cursor position.
570 * @param len The length for delete text.
572 void delete_surrounding_text (int offset,
576 * @brief Request to get selection.
578 * @param uuid The helper ISE UUID.
580 void get_selection (const String &uuid) const;
583 * @brief Request to get selection text synchronously.
585 * @param text The selection text.
587 void get_selection_text (String &text);
590 * @brief Request to selected text.
592 * @param start The start position in text.
593 * @param end The end position in text.
595 void set_selection (int start,
599 * @brief Set candidate position in screen.
601 * @param left The x position in screen.
602 * @param top The y position in screen.
604 void set_candidate_position (int left,
608 * @brief Request to hide candidate window.
610 void candidate_hide (void) const;
613 * @brief Request to get candidate window size and position.
615 * @param uuid The helper ISE UUID.
617 void get_candidate_window_geometry (const String &uuid) const;
620 * @brief Set current keyboard ISE.
622 * @param uuid The keyboard ISE UUID.
624 void set_keyboard_ise_by_uuid (const String &uuid) const;
627 * @brief Request to get current keyboard ISE information.
629 * @param uuid The helper ISE UUID.
631 void get_keyboard_ise (const String &uuid) const;
634 * @brief Request to get uuid list of all keyboard ISEs.
636 * @param uuid The helper ISE UUID.
638 void get_keyboard_ise_list (const String &uuid) const;
641 * @brief Update ISE window geometry.
643 * @param x The x position in screen.
644 * @param y The y position in screen.
645 * @param width The ISE window width.
646 * @param height The ISE window height.
648 void update_geometry (int x,
654 * @brief Request to expand candidate window.
656 void expand_candidate (void) const;
659 * @brief Request to contract candidate window.
661 void contract_candidate (void) const;
664 * @brief Send selected candidate string index number.
666 void select_candidate (int index) const;
669 * @brief Update ise exit status
671 void update_ise_exit (void) const;
674 * @brief Update the preedit caret position in the preedit string.
676 * @param caret - the new position of the preedit caret.
678 void update_preedit_caret (int caret) const;
681 * @brief Set candidate style.
683 * @param portrait_line - the displayed line number for portrait.
684 * @param mode - candidate window mode.
686 void set_candidate_style (ISF_CANDIDATE_PORTRAIT_LINE_T portrait_line = ONE_LINE_CANDIDATE,
687 ISF_CANDIDATE_MODE_T mode = SOFT_CANDIDATE_WINDOW) const;
690 * @brief Request to reset keyboard ISE.
692 void reset_keyboard_ise (void) const;
695 * @brief Send a private command to an application
697 * @param command The private command sent from IME.
699 void send_private_command (const String &command) const;
703 * @brief Connect a slot to Helper exit signal.
705 * This signal is used to let the Helper exit.
707 * The prototype of the slot is:
709 * void exit (const HelperAgent *agent, int ic, const String &ic_uuid);
712 * - agent The pointer to the HelperAgent object which emits this signal.
713 * - ic An opaque handle of the currently focused input context.
714 * - ic_uuid The UUID of the IMEngineInstance associated with the focused input context.
716 Connection signal_connect_exit (HelperAgentSlotVoid *slot);
719 * @brief Connect a slot to Helper attach input context signal.
721 * This signal is used to attach an input context to this helper.
723 * When an input context requst to start this helper, then this
724 * signal will be emitted as soon as the helper is started.
726 * When an input context want to start an already started helper,
727 * this signal will also be emitted.
729 * Helper can send some events back to the IMEngineInstance in this
730 * signal-slot, to inform that it has been started sccessfully.
732 * The prototype of the slot is:
734 * void attach_input_context (const HelperAgent *agent, int ic, const String &ic_uuid);
736 Connection signal_connect_attach_input_context (HelperAgentSlotVoid *slot);
739 * @brief Connect a slot to Helper detach input context signal.
741 * This signal is used to detach an input context from this helper.
743 * When an input context requst to stop this helper, then this
744 * signal will be emitted.
746 * Helper shouldn't send any event back to the IMEngineInstance, because
747 * the IMEngineInstance attached to the ic should have been destroyed.
749 * The prototype of the slot is:
751 * void detach_input_context (const HelperAgent *agent, int ic, const String &ic_uuid);
753 Connection signal_connect_detach_input_context (HelperAgentSlotVoid *slot);
756 * @brief Connect a slot to Helper reload config signal.
758 * This signal is used to let the Helper reload configuration.
760 * The prototype of the slot is:
762 * void reload_config (const HelperAgent *agent, int ic, const String &ic_uuid);
764 Connection signal_connect_reload_config (HelperAgentSlotVoid *slot);
767 * @brief Connect a slot to Helper update screen signal.
769 * This signal is used to let the Helper move its GUI to another screen.
770 * It can only be emitted when SCIM_HELPER_NEED_SCREEN_INFO is set in HelperInfo.option.
772 * The prototype of the slot is:
774 * void update_screen (const HelperAgent *agent, int ic, const String &ic_uuid, int screen_number);
776 Connection signal_connect_update_screen (HelperAgentSlotInt *slot);
779 * @brief Connect a slot to Helper update spot location signal.
781 * This signal is used to let the Helper move its GUI according to the current spot location.
782 * It can only be emitted when SCIM_HELPER_NEED_SPOT_LOCATION_INFO is set in HelperInfo.option.
784 * The prototype of the slot is:
785 * void update_spot_location (const HelperAgent *agent, int ic, const String &ic_uuid, int x, int y);
787 Connection signal_connect_update_spot_location (HelperAgentSlotIntInt *slot);
790 * @brief Connect a slot to Helper update cursor position signal.
792 * This signal is used to let the Helper get the cursor position information.
794 * The prototype of the slot is:
795 * void update_cursor_position (const HelperAgent *agent, int ic, const String &ic_uuid, int cursor_pos);
797 Connection signal_connect_update_cursor_position (HelperAgentSlotInt *slot);
800 * @brief Connect a slot to Helper update surrounding text signal.
802 * This signal is used to let the Helper get the surrounding text.
804 * The prototype of the slot is:
805 * void update_surrounding_text (const HelperAgent *agent, int ic, const String &text, int cursor);
807 Connection signal_connect_update_surrounding_text (HelperAgentSlotInt *slot);
810 * @brief Connect a slot to Helper update selection signal.
812 * This signal is used to let the Helper get the selection.
814 * The prototype of the slot is:
815 * void update_selection (const HelperAgent *agent, int ic, const String &text);
817 Connection signal_connect_update_selection (HelperAgentSlotVoid *slot);
820 * @brief Connect a slot to Helper trigger property signal.
822 * This signal is used to trigger a property registered by this Helper.
823 * A property will be triggered when user clicks on it.
825 * The prototype of the slot is:
826 * void trigger_property (const HelperAgent *agent, int ic, const String &ic_uuid, const String &property);
828 Connection signal_connect_trigger_property (HelperAgentSlotString *slot);
831 * @brief Connect a slot to Helper process imengine event signal.
833 * This signal is used to deliver the events sent from IMEngine to Helper.
835 * The prototype of the slot is:
836 * void process_imengine_event (const HelperAgent *agent, int ic, const String &ic_uuid, const Transaction &transaction);
838 Connection signal_connect_process_imengine_event (HelperAgentSlotTransaction *slot);
841 * @brief Connect a slot to Helper focus out signal.
843 * This signal is used to do something when input context is focus out.
845 * The prototype of the slot is:
846 * void focus_out (const HelperAgent *agent, int ic, const String &ic_uuid);
848 Connection signal_connect_focus_out (HelperAgentSlotVoid *slot);
851 * @brief Connect a slot to Helper focus in signal.
853 * This signal is used to do something when input context is focus in.
855 * The prototype of the slot is:
856 * void focus_in (const HelperAgent *agent, int ic, const String &ic_uuid);
858 Connection signal_connect_focus_in (HelperAgentSlotVoid *slot);
861 * @brief Connect a slot to Helper show signal.
863 * This signal is used to show Helper ISE window.
865 * The prototype of the slot is:
866 * void ise_show (const HelperAgent *agent, int ic, char *buf, size_t &len);
868 Connection signal_connect_ise_show (HelperAgentSlotIntRawVoid *slot);
871 * @brief Connect a slot to Helper hide signal.
873 * This signal is used to hide Helper ISE window.
875 * The prototype of the slot is:
876 * void ise_hide (const HelperAgent *agent, int ic, const String &ic_uuid);
878 Connection signal_connect_ise_hide (HelperAgentSlotVoid *slot);
881 * @brief Connect a slot to Helper get ISE window geometry signal.
883 * This signal is used to get Helper ISE window size and position.
885 * The prototype of the slot is:
886 * void get_geometry (const HelperAgent *agent, struct rectinfo &info);
888 Connection signal_connect_get_geometry (HelperAgentSlotSize *slot);
891 * @brief Connect a slot to Helper set mode signal.
893 * This signal is used to set Helper ISE mode.
895 * The prototype of the slot is:
896 * void set_mode (const HelperAgent *agent, uint32 &mode);
898 Connection signal_connect_set_mode (HelperAgentSlotUintVoid *slot);
901 * @brief Connect a slot to Helper set language signal.
903 * This signal is used to set Helper ISE language.
905 * The prototype of the slot is:
906 * void set_language (const HelperAgent *agent, uint32 &language);
908 Connection signal_connect_set_language (HelperAgentSlotUintVoid *slot);
911 * @brief Connect a slot to Helper set im data signal.
913 * This signal is used to send im data to Helper ISE.
915 * The prototype of the slot is:
916 * void set_imdata (const HelperAgent *agent, char *buf, size_t &len);
918 Connection signal_connect_set_imdata (HelperAgentSlotRawVoid *slot);
921 * @brief Connect a slot to Helper get im data signal.
923 * This signal is used to get im data from Helper ISE.
925 * The prototype of the slot is:
926 * void get_imdata (const HelperAgent *, char **buf, size_t &len);
928 Connection signal_connect_get_imdata (HelperAgentSlotGetRawVoid *slot);
931 * @brief Connect a slot to Helper get language locale.
933 * This signal is used to get language locale from Helper ISE.
935 * The prototype of the slot is:
936 * void get_language_locale (const HelperAgent *, int ic, char **locale);
938 Connection signal_connect_get_language_locale (HelperAgentSlotIntGetStringVoid *slot);
941 * @brief Connect a slot to Helper set return key type signal.
943 * This signal is used to set return key type to Helper ISE.
945 * The prototype of the slot is:
946 * void set_return_key_type (const HelperAgent *agent, uint32 &type);
948 Connection signal_connect_set_return_key_type (HelperAgentSlotUintVoid *slot);
951 * @brief Connect a slot to Helper get return key type signal.
953 * This signal is used to get return key type from Helper ISE.
955 * The prototype of the slot is:
956 * void get_return_key_type (const HelperAgent *agent, uint32 &type);
958 Connection signal_connect_get_return_key_type (HelperAgentSlotUintVoid *slot);
961 * @brief Connect a slot to Helper set return key disable signal.
963 * This signal is used to set return key disable to Helper ISE.
965 * The prototype of the slot is:
966 * void set_return_key_disable (const HelperAgent *agent, uint32 &disabled);
968 Connection signal_connect_set_return_key_disable (HelperAgentSlotUintVoid *slot);
971 * @brief Connect a slot to Helper get return key disable signal.
973 * This signal is used to get return key disable from Helper ISE.
975 * The prototype of the slot is:
976 * void get_return_key_disable (const HelperAgent *agent, uint32 &disabled);
978 Connection signal_connect_get_return_key_disable (HelperAgentSlotUintVoid *slot);
981 * @brief Connect a slot to Helper get layout signal.
983 * This signal is used to get Helper ISE layout.
985 * The prototype of the slot is:
986 * void get_layout (const HelperAgent *agent, uint32 &layout);
988 Connection signal_connect_get_layout (HelperAgentSlotUintVoid *slot);
991 * @brief Connect a slot to Helper set layout signal.
993 * This signal is used to set Helper ISE layout.
995 * The prototype of the slot is:
996 * void set_layout (const HelperAgent *agent, uint32 &layout);
998 Connection signal_connect_set_layout (HelperAgentSlotUintVoid *slot);
1001 * @brief Connect a slot to Helper set shift mode signal.
1003 * This signal is used to set Helper shift mode.
1005 * The prototype of the slot is:
1006 * void set_caps_mode (const HelperAgent *agent, uint32 &mode);
1008 Connection signal_connect_set_caps_mode (HelperAgentSlotUintVoid *slot);
1011 * @brief Connect a slot to Helper reset input context signal.
1013 * This signal is used to reset Helper ISE input context.
1015 * The prototype of the slot is:
1016 * void reset_input_context (const HelperAgent *agent, int ic, const String &uuid);
1018 Connection signal_connect_reset_input_context (HelperAgentSlotVoid *slot);
1021 * @brief Connect a slot to Helper update candidate window geometry signal.
1023 * This signal is used to get candidate window size and position.
1025 * The prototype of the slot is:
1026 * void update_candidate_geometry (const HelperAgent *agent, int ic, const String &uuid, const rectinfo &info);
1028 Connection signal_connect_update_candidate_geometry (HelperAgentSlotRect *slot);
1031 * @brief Connect a slot to Helper update keyboard ISE signal.
1033 * This signal is used to get current keyboard ISE name and uuid.
1035 * The prototype of the slot is:
1036 * void update_keyboard_ise (const HelperAgent *agent, int ic, const String &uuid,
1037 * const String &ise_name, const String &ise_uuid);
1039 Connection signal_connect_update_keyboard_ise (HelperAgentSlotString2 *slot);
1042 * @brief Connect a slot to Helper update keyboard ISE list signal.
1044 * This signal is used to get uuid list of all keyboard ISEs.
1046 * The prototype of the slot is:
1047 * void update_keyboard_ise_list (const HelperAgent *agent, int ic, const String &uuid,
1048 * const std::vector<String> &ise_list);
1050 Connection signal_connect_update_keyboard_ise_list (HelperAgentSlotStringVector *slot);
1053 * @brief Connect a slot to Helper candidate more window show signal.
1055 * This signal is used to do someting when candidate more window is showed.
1057 * The prototype of the slot is:
1058 * void candidate_more_window_show (const HelperAgent *agent, int ic, const String &uuid);
1060 Connection signal_connect_candidate_more_window_show (HelperAgentSlotVoid *slot);
1063 * @brief Connect a slot to Helper candidate more window hide signal.
1065 * This signal is used to do someting when candidate more window is hidden.
1067 * The prototype of the slot is:
1068 * void candidate_more_window_hide (const HelperAgent *agent, int ic, const String &uuid);
1070 Connection signal_connect_candidate_more_window_hide (HelperAgentSlotVoid *slot);
1073 * @brief Connect a slot to Helper candidate show signal.
1075 * This signal is used to do candidate show.
1077 * The prototype of the slot is:
1078 * void candidate_show (const HelperAgent *agent, int ic, const String &uuid);
1080 Connection signal_connect_candidate_show (HelperAgentSlotVoid *slot);
1083 * @brief Connect a slot to Helper candidate hide signal.
1085 * This signal is used to do candidate hide.
1087 * The prototype of the slot is:
1088 * void candidate_hide (const HelperAgent *agent,int ic, const String &uuid);
1090 Connection signal_connect_candidate_hide (HelperAgentSlotVoid *slot);
1093 * @brief Connect a slot to Helper update lookup table signal.
1095 * This signal is used to do someting when update lookup table.
1097 * The prototype of the slot is:
1098 * void update_lookup_table (const HelperAgent *agent, int ic, const String &uuid, LookupTable &Table);
1100 Connection signal_connect_update_lookup_table (HelperAgentSlotLookupTable *slot);
1103 * @brief Connect a slot to Helper select aux signal.
1105 * This signal is used to do something when aux is selected.
1107 * The prototype of the slot is:
1108 * void select_aux (const HelperAgent *agent, int ic, const String &uuid, int index);
1110 Connection signal_connect_select_aux (HelperAgentSlotInt *slot);
1113 * @brief Connect a slot to Helper select candidate signal.
1115 * This signal is used to do something when candidate is selected.
1117 * The prototype of the slot is:
1118 * void select_candidate (const HelperAgent *agent, int ic, const String &uuid, int index);
1120 Connection signal_connect_select_candidate (HelperAgentSlotInt *slot);
1123 * @brief Connect a slot to Helper candidate table page up signal.
1125 * This signal is used to do something when candidate table is paged up.
1127 * The prototype of the slot is:
1128 * void candidate_table_page_up (const HelperAgent *agent, int ic, const String &uuid);
1130 Connection signal_connect_candidate_table_page_up (HelperAgentSlotVoid *slot);
1133 * @brief Connect a slot to Helper candidate table page down signal.
1135 * This signal is used to do something when candidate table is paged down.
1137 * The prototype of the slot is:
1138 * void candidate_table_page_down (const HelperAgent *agent, int ic, const String &uuid);
1140 Connection signal_connect_candidate_table_page_down (HelperAgentSlotVoid *slot);
1143 * @brief Connect a slot to Helper update candidate table page size signal.
1145 * This signal is used to do something when candidate table page size is changed.
1147 * The prototype of the slot is:
1148 * void update_candidate_table_page_size (const HelperAgent *, int ic, const String &uuid, int page_size);
1150 Connection signal_connect_update_candidate_table_page_size (HelperAgentSlotInt *slot);
1153 * @brief Connect a slot to Helper select associate signal.
1155 * This signal is used to do something when associate is selected.
1157 * The prototype of the slot is:
1158 * void select_associate (const HelperAgent *agent, int ic, const String &uuid, int index);
1160 Connection signal_connect_select_associate (HelperAgentSlotInt *slot);
1163 * @brief Connect a slot to Helper associate table page up signal.
1165 * This signal is used to do something when associate table is paged up.
1167 * The prototype of the slot is:
1168 * void associate_table_page_up (const HelperAgent *agent, int ic, const String &uuid);
1170 Connection signal_connect_associate_table_page_up (HelperAgentSlotVoid *slot);
1173 * @brief Connect a slot to Helper associate table page down signal.
1175 * This signal is used to do something when associate table is paged down.
1177 * The prototype of the slot is:
1178 * void associate_table_page_down (const HelperAgent *agent, int ic, const String &uuid);
1180 Connection signal_connect_associate_table_page_down (HelperAgentSlotVoid *slot);
1183 * @brief Connect a slot to Helper update associate table page size signal.
1185 * This signal is used to do something when associate table page size is changed.
1187 * The prototype of the slot is:
1188 * void update_associate_table_page_size (const HelperAgent *, int ic, const String &uuid, int page_size);
1190 Connection signal_connect_update_associate_table_page_size (HelperAgentSlotInt *slot);
1193 * @brief Connect a slot to Helper turn on log signal.
1195 * This signal is used to turn on Helper ISE debug information.
1197 * The prototype of the slot is:
1198 * void turn_on_log (const HelperAgent *agent, uint32 &on);
1200 Connection signal_connect_turn_on_log (HelperAgentSlotUintVoid *slot);
1203 * @brief Connect a slot to Helper update displayed candidate number signal.
1205 * This signal is used to inform helper ISE displayed candidate number.
1207 * The prototype of the slot is:
1208 * void update_displayed_candidate_number (const HelperAgent *, int ic, const String &uuid, int number);
1210 Connection signal_connect_update_displayed_candidate_number (HelperAgentSlotInt *slot);
1213 * @brief Connect a slot to Helper longpress candidate signal.
1215 * This signal is used to do something when candidate is longpress.
1217 * The prototype of the slot is:
1218 * void longpress_candidate (const HelperAgent *agent, int ic, const String &uuid, int index);
1220 Connection signal_connect_longpress_candidate (HelperAgentSlotInt *slot);
1223 * @brief Connect a slot to Helper update candidate item layout signal.
1225 * The prototype of the slot is:
1226 * void update_candidate_item_layout (const HelperAgent *, const std::vector<uint32> &row_items);
1228 Connection signal_connect_update_candidate_item_layout (HelperAgentSlotUintVector *slot);
1231 * @brief Connect a slot to Helper process key event signal.
1233 * The prototype of the slot is:
1234 * void process_key_event (const HelperAgent *, KeyEvent &key, uint32 &ret);
1236 Connection signal_connect_process_key_event (HelperAgentSlotKeyEventUint *slot);
1239 * @brief Connect a slot to Helper set input mode signal.
1241 * This signal is used to set Helper ISE input mode.
1243 * The prototype of the slot is:
1244 * void set_input_mode (const HelperAgent *agent, uint32 &input_mode);
1246 Connection signal_connect_set_input_mode (HelperAgentSlotUintVoid *slot);
1249 * @brief Connect a slot to Helper set input hint signal.
1251 * This signal is used to set Helper ISE input hint.
1253 * The prototype of the slot is:
1254 * void set_input_hint (const HelperAgent *agent, uint32 &input_hint);
1256 Connection signal_connect_set_input_hint (HelperAgentSlotUintVoid *slot);
1259 * @brief Connect a slot to Helper update bidi direction signal.
1261 * This signal is used to update Helper ISE bidi direction.
1263 * The prototype of the slot is:
1264 * void update_bidi_direction (const HelperAgent *agent, uint32 &bidi_direction);
1266 Connection signal_connect_update_bidi_direction (HelperAgentSlotUintVoid *slot);
1269 * @brief Connect a slot to Helper show option window.
1271 * This signal is used to do request the ISE to show option window.
1273 * The prototype of the slot is:
1274 * void show_option_window (const HelperAgent *agent, int ic, const String &uuid);
1276 Connection signal_connect_show_option_window (HelperAgentSlotVoid *slot);
1279 * @brief Connect a slot to Helper check if the option is available.
1281 * This signal is used to request ISE to reply if the option (setting) is available.
1283 * The prototype of the slot is:
1284 * void check_option_window (const HelperAgent *agent, uint32 &avail);
1286 Connection signal_connect_check_option_window (HelperAgentSlotUintVoid *slot);
1291 } /* namespace scim */
1299 #endif /* __SCIM_HELPER_H */
1302 vi:ts=4:nowrap:ai:expandtab