diff options
author | Jihoon Kim <imfine98@gmail.com> | 2013-01-08 01:57:22 +0000 |
---|---|---|
committer | Jihoon Kim <imfine98@gmail.com> | 2013-01-08 01:57:22 +0000 |
commit | f35fd9762eac5bb23ecb3db7d78a8d9e45ea0015 (patch) | |
tree | 5176fdd3f1e8bfbc76e3a2489f2ed568d5aa291d /src/lib/ecore_imf/ecore_imf_context.c | |
parent | acf4ca6139c473e2802bc13d313b70191ec29956 (diff) |
ecore_imf: move the docs to header
SVN revision: 82373
Diffstat (limited to 'src/lib/ecore_imf/ecore_imf_context.c')
-rw-r--r-- | src/lib/ecore_imf/ecore_imf_context.c | 815 |
1 files changed, 0 insertions, 815 deletions
diff --git a/src/lib/ecore_imf/ecore_imf_context.c b/src/lib/ecore_imf/ecore_imf_context.c index 4e4fadced3..8f6efa623a 100644 --- a/src/lib/ecore_imf/ecore_imf_context.c +++ b/src/lib/ecore_imf/ecore_imf_context.c | |||
@@ -12,40 +12,6 @@ | |||
12 | #include "Ecore_IMF.h" | 12 | #include "Ecore_IMF.h" |
13 | #include "ecore_imf_private.h" | 13 | #include "ecore_imf_private.h" |
14 | 14 | ||
15 | /** | ||
16 | * @defgroup Ecore_IMF_Context_Group Ecore Input Method Context Functions | ||
17 | * @ingroup Ecore_IMF_Lib_Group | ||
18 | * | ||
19 | * Functions that operate on Ecore Input Method Context objects. | ||
20 | |||
21 | * Ecore Input Method Context Function defines the interface for EFL input methods. | ||
22 | * An input method is used by EFL text input widgets like elm_entry | ||
23 | * (based on edje_entry) to map from key events to Unicode character strings. | ||
24 | * | ||
25 | * The default input method can be set through setting the ECORE_IMF_MODULE environment variable. | ||
26 | * | ||
27 | * An input method may consume multiple key events in sequence and finally output the composed result. | ||
28 | * This is called preediting, and an input method may provide feedback about | ||
29 | * this process by displaying the intermediate composition states as preedit text. | ||
30 | * | ||
31 | * Immodule is plugin to connect your application and input method framework such as SCIM, ibus, and so on.@n | ||
32 | * ecore_imf_init() should be called to initialize and load immodule.@n | ||
33 | * ecore_imf_shutdown() is used for shutdowning and unloading immodule. | ||
34 | * | ||
35 | * An example of usage of these functions can be found at: | ||
36 | * @li @ref ecore_imf_example_c | ||
37 | */ | ||
38 | |||
39 | /** | ||
40 | * Get the list of the available Input Method Context ids. | ||
41 | * | ||
42 | * Note that the caller is responsible for freeing the Eina_List | ||
43 | * when finished with it. There is no need to finish the list strings. | ||
44 | * | ||
45 | * @return Return an Eina_List of strings; | ||
46 | * on failure it returns NULL. | ||
47 | * @ingroup Ecore_IMF_Context_Group | ||
48 | */ | ||
49 | EAPI Eina_List * | 15 | EAPI Eina_List * |
50 | ecore_imf_context_available_ids_get(void) | 16 | ecore_imf_context_available_ids_get(void) |
51 | { | 17 | { |
@@ -81,15 +47,6 @@ _ecore_imf_context_match_locale(const char *locale, const char *against, int aga | |||
81 | return 0; | 47 | return 0; |
82 | } | 48 | } |
83 | 49 | ||
84 | /** | ||
85 | * Get the id of the default Input Method Context. | ||
86 | * The id may to used to create a new instance of an Input Method | ||
87 | * Context object. | ||
88 | * | ||
89 | * @return Return a string containing the id of the default Input | ||
90 | * Method Context; on failure it returns NULL. | ||
91 | * @ingroup Ecore_IMF_Context_Group | ||
92 | */ | ||
93 | EAPI const char * | 50 | EAPI const char * |
94 | ecore_imf_context_default_id_get(void) | 51 | ecore_imf_context_default_id_get(void) |
95 | { | 52 | { |
@@ -154,40 +111,6 @@ ecore_imf_context_default_id_by_canvas_type_get(const char *canvas_type) | |||
154 | return id; | 111 | return id; |
155 | } | 112 | } |
156 | 113 | ||
157 | /** | ||
158 | * Retrieve the info for the Input Method Context with @p id. | ||
159 | * | ||
160 | * @param id The Input Method Context id to query for. | ||
161 | * @return Return a #Ecore_IMF_Context_Info for the Input Method Context with @p id; | ||
162 | * on failure it returns NULL. | ||
163 | * @ingroup Ecore_IMF_Context_Group | ||
164 | * | ||
165 | * Example | ||
166 | * @code | ||
167 | * | ||
168 | * const char *ctx_id; | ||
169 | * const Ecore_IMF_Context_Info *ctx_info; | ||
170 | * Ecore_IMF_Context *imf_context; | ||
171 | * ctx_id = ecore_imf_context_default_id_get(); | ||
172 | * if (ctx_id) | ||
173 | * { | ||
174 | * ctx_info = ecore_imf_context_info_by_id_get(ctx_id); | ||
175 | * if (!ctx_info->canvas_type || | ||
176 | * strcmp(ctx_info->canvas_type, "evas") == 0) | ||
177 | * { | ||
178 | * imf_context = ecore_imf_context_add(ctx_id); | ||
179 | * } | ||
180 | * else | ||
181 | * { | ||
182 | * ctx_id = ecore_imf_context_default_id_by_canvas_type_get("evas"); | ||
183 | * if (ctx_id) | ||
184 | * { | ||
185 | * imf_context = ecore_imf_context_add(ctx_id); | ||
186 | * } | ||
187 | * } | ||
188 | * } | ||
189 | * @endcode | ||
190 | */ | ||
191 | EAPI const Ecore_IMF_Context_Info * | 114 | EAPI const Ecore_IMF_Context_Info * |
192 | ecore_imf_context_info_by_id_get(const char *id) | 115 | ecore_imf_context_info_by_id_get(const char *id) |
193 | { | 116 | { |
@@ -199,14 +122,6 @@ ecore_imf_context_info_by_id_get(const char *id) | |||
199 | return module->info; | 122 | return module->info; |
200 | } | 123 | } |
201 | 124 | ||
202 | /** | ||
203 | * Create a new Input Method Context defined by the given id. | ||
204 | * | ||
205 | * @param id The Input Method Context id. | ||
206 | * @return A newly allocated Input Method Context; | ||
207 | * on failure it returns NULL. | ||
208 | * @ingroup Ecore_IMF_Context_Group | ||
209 | */ | ||
210 | EAPI Ecore_IMF_Context * | 125 | EAPI Ecore_IMF_Context * |
211 | ecore_imf_context_add(const char *id) | 126 | ecore_imf_context_add(const char *id) |
212 | { | 127 | { |
@@ -242,14 +157,6 @@ ecore_imf_context_add(const char *id) | |||
242 | return ctx; | 157 | return ctx; |
243 | } | 158 | } |
244 | 159 | ||
245 | /** | ||
246 | * Retrieve the info for the given Input Method Context. | ||
247 | * | ||
248 | * @param ctx An #Ecore_IMF_Context. | ||
249 | * @return Return a #Ecore_IMF_Context_Info for the given Input Method Context; | ||
250 | * on failure it returns NULL. | ||
251 | * @ingroup Ecore_IMF_Context_Group | ||
252 | */ | ||
253 | EAPI const Ecore_IMF_Context_Info * | 160 | EAPI const Ecore_IMF_Context_Info * |
254 | ecore_imf_context_info_get(Ecore_IMF_Context *ctx) | 161 | ecore_imf_context_info_get(Ecore_IMF_Context *ctx) |
255 | { | 162 | { |
@@ -262,12 +169,6 @@ ecore_imf_context_info_get(Ecore_IMF_Context *ctx) | |||
262 | return ctx->module->info; | 169 | return ctx->module->info; |
263 | } | 170 | } |
264 | 171 | ||
265 | /** | ||
266 | * Delete the given Input Method Context and free its memory. | ||
267 | * | ||
268 | * @param ctx An #Ecore_IMF_Context. | ||
269 | * @ingroup Ecore_IMF_Context_Group | ||
270 | */ | ||
271 | EAPI void | 172 | EAPI void |
272 | ecore_imf_context_del(Ecore_IMF_Context *ctx) | 173 | ecore_imf_context_del(Ecore_IMF_Context *ctx) |
273 | { | 174 | { |
@@ -291,17 +192,6 @@ ecore_imf_context_del(Ecore_IMF_Context *ctx) | |||
291 | free(ctx); | 192 | free(ctx); |
292 | } | 193 | } |
293 | 194 | ||
294 | /** | ||
295 | * Set the client window for the Input Method Context; this is the | ||
296 | * Ecore_X_Window when using X11, Ecore_Win32_Window when using Win32, etc. | ||
297 | * This window is used in order to correctly position status windows, and may | ||
298 | * also be used for purposes internal to the Input Method Context. | ||
299 | * | ||
300 | * @param ctx An #Ecore_IMF_Context. | ||
301 | * @param window The client window. This may be @c NULL to indicate | ||
302 | * that the previous client window no longer exists. | ||
303 | * @ingroup Ecore_IMF_Context_Group | ||
304 | */ | ||
305 | EAPI void | 195 | EAPI void |
306 | ecore_imf_context_client_window_set(Ecore_IMF_Context *ctx, void *window) | 196 | ecore_imf_context_client_window_set(Ecore_IMF_Context *ctx, void *window) |
307 | { | 197 | { |
@@ -315,16 +205,6 @@ ecore_imf_context_client_window_set(Ecore_IMF_Context *ctx, void *window) | |||
315 | ctx->window = window; | 205 | ctx->window = window; |
316 | } | 206 | } |
317 | 207 | ||
318 | /** | ||
319 | * Get the client window of the Input Method Context | ||
320 | * | ||
321 | * See @ref ecore_imf_context_client_window_set for more details. | ||
322 | * | ||
323 | * @param ctx An #Ecore_IMF_Context. | ||
324 | * @return Return the client window. | ||
325 | * @ingroup Ecore_IMF_Context_Group | ||
326 | * @since 1.1.0 | ||
327 | */ | ||
328 | EAPI void * | 208 | EAPI void * |
329 | ecore_imf_context_client_window_get(Ecore_IMF_Context *ctx) | 209 | ecore_imf_context_client_window_get(Ecore_IMF_Context *ctx) |
330 | { | 210 | { |
@@ -337,19 +217,6 @@ ecore_imf_context_client_window_get(Ecore_IMF_Context *ctx) | |||
337 | return ctx->window; | 217 | return ctx->window; |
338 | } | 218 | } |
339 | 219 | ||
340 | /** | ||
341 | * Set the client canvas for the Input Method Context; this is the | ||
342 | * canvas in which the input appears. | ||
343 | * The canvas type can be determined by using the context canvas type. | ||
344 | * Actually only canvas with type "evas" (Evas *) is supported. | ||
345 | * This canvas may be used in order to correctly position status windows, and may | ||
346 | * also be used for purposes internal to the Input Method Context. | ||
347 | * | ||
348 | * @param ctx An #Ecore_IMF_Context. | ||
349 | * @param canvas The client canvas. This may be @c NULL to indicate | ||
350 | * that the previous client canvas no longer exists. | ||
351 | * @ingroup Ecore_IMF_Context_Group | ||
352 | */ | ||
353 | EAPI void | 220 | EAPI void |
354 | ecore_imf_context_client_canvas_set(Ecore_IMF_Context *ctx, void *canvas) | 221 | ecore_imf_context_client_canvas_set(Ecore_IMF_Context *ctx, void *canvas) |
355 | { | 222 | { |
@@ -363,16 +230,6 @@ ecore_imf_context_client_canvas_set(Ecore_IMF_Context *ctx, void *canvas) | |||
363 | ctx->client_canvas = canvas; | 230 | ctx->client_canvas = canvas; |
364 | } | 231 | } |
365 | 232 | ||
366 | /** | ||
367 | * Get the client canvas of the Input Method Context. | ||
368 | * | ||
369 | * See @ref ecore_imf_context_client_canvas_set for more details. | ||
370 | * | ||
371 | * @param ctx An #Ecore_IMF_Context. | ||
372 | * @return Return the client canvas. | ||
373 | * @ingroup Ecore_IMF_Context_Group | ||
374 | * @since 1.1.0 | ||
375 | */ | ||
376 | EAPI void * | 233 | EAPI void * |
377 | ecore_imf_context_client_canvas_get(Ecore_IMF_Context *ctx) | 234 | ecore_imf_context_client_canvas_get(Ecore_IMF_Context *ctx) |
378 | { | 235 | { |
@@ -385,12 +242,6 @@ ecore_imf_context_client_canvas_get(Ecore_IMF_Context *ctx) | |||
385 | return ctx->client_canvas; | 242 | return ctx->client_canvas; |
386 | } | 243 | } |
387 | 244 | ||
388 | /** | ||
389 | * Ask the Input Method Context to show itself. | ||
390 | * | ||
391 | * @param ctx An #Ecore_IMF_Context. | ||
392 | * @ingroup Ecore_IMF_Context_Group | ||
393 | */ | ||
394 | EAPI void | 245 | EAPI void |
395 | ecore_imf_context_show(Ecore_IMF_Context *ctx) | 246 | ecore_imf_context_show(Ecore_IMF_Context *ctx) |
396 | { | 247 | { |
@@ -403,12 +254,6 @@ ecore_imf_context_show(Ecore_IMF_Context *ctx) | |||
403 | if (ctx->klass->show) ctx->klass->show(ctx); | 254 | if (ctx->klass->show) ctx->klass->show(ctx); |
404 | } | 255 | } |
405 | 256 | ||
406 | /** | ||
407 | * Ask the Input Method Context to hide itself. | ||
408 | * | ||
409 | * @param ctx An #Ecore_IMF_Context. | ||
410 | * @ingroup Ecore_IMF_Context_Group | ||
411 | */ | ||
412 | EAPI void | 257 | EAPI void |
413 | ecore_imf_context_hide(Ecore_IMF_Context *ctx) | 258 | ecore_imf_context_hide(Ecore_IMF_Context *ctx) |
414 | { | 259 | { |
@@ -421,17 +266,6 @@ ecore_imf_context_hide(Ecore_IMF_Context *ctx) | |||
421 | if (ctx->klass->hide) ctx->klass->hide(ctx); | 266 | if (ctx->klass->hide) ctx->klass->hide(ctx); |
422 | } | 267 | } |
423 | 268 | ||
424 | /** | ||
425 | * Retrieve the current preedit string and cursor position | ||
426 | * for the Input Method Context. | ||
427 | * | ||
428 | * @param ctx An #Ecore_IMF_Context. | ||
429 | * @param str Location to store the retrieved string. The | ||
430 | * string retrieved must be freed with free(). | ||
431 | * @param cursor_pos Location to store position of cursor (in characters) | ||
432 | * within the preedit string. | ||
433 | * @ingroup Ecore_IMF_Context_Group | ||
434 | */ | ||
435 | EAPI void | 269 | EAPI void |
436 | ecore_imf_context_preedit_string_get(Ecore_IMF_Context *ctx, char **str, int *cursor_pos) | 270 | ecore_imf_context_preedit_string_get(Ecore_IMF_Context *ctx, char **str, int *cursor_pos) |
437 | { | 271 | { |
@@ -450,59 +284,6 @@ ecore_imf_context_preedit_string_get(Ecore_IMF_Context *ctx, char **str, int *cu | |||
450 | } | 284 | } |
451 | } | 285 | } |
452 | 286 | ||
453 | /** | ||
454 | * Retrieve the current preedit string, attributes and | ||
455 | * cursor position for the Input Method Context. | ||
456 | * | ||
457 | * @param ctx An #Ecore_IMF_Context. | ||
458 | * @param str Location to store the retrieved string. The | ||
459 | * string retrieved must be freed with free(). | ||
460 | * @param attrs an Eina_List of attributes | ||
461 | * @param cursor_pos Location to store position of cursor (in characters) | ||
462 | * within the preedit string. | ||
463 | * @ingroup Ecore_IMF_Context_Group | ||
464 | * | ||
465 | * Example | ||
466 | * @code | ||
467 | * char *preedit_string; | ||
468 | * int cursor_pos; | ||
469 | * Eina_List *attrs = NULL, *l = NULL; | ||
470 | * Ecore_IMF_Preedit_Attr *attr; | ||
471 | * | ||
472 | * ecore_imf_context_preedit_string_with_attributes_get(imf_context, | ||
473 | * &preedit_string, | ||
474 | * &attrs, &cursor_pos); | ||
475 | * if (!preedit_string) return; | ||
476 | * | ||
477 | * if (strlen(preedit_string) > 0) | ||
478 | * { | ||
479 | * if (attrs) | ||
480 | * { | ||
481 | * EINA_LIST_FOREACH(attrs, l, attr) | ||
482 | * { | ||
483 | * if (attr->preedit_type == ECORE_IMF_PREEDIT_TYPE_SUB1) | ||
484 | * { | ||
485 | * // Something to do | ||
486 | * } | ||
487 | * else if (attr->preedit_type == ECORE_IMF_PREEDIT_TYPE_SUB2) | ||
488 | * { | ||
489 | * // Something to do | ||
490 | * } | ||
491 | * else if (attr->preedit_type == ECORE_IMF_PREEDIT_TYPE_SUB3) | ||
492 | * { | ||
493 | * // Something to do | ||
494 | * } | ||
495 | * } | ||
496 | * } | ||
497 | * } | ||
498 | * | ||
499 | * // delete attribute list | ||
500 | * EINA_LIST_FREE(attrs, attr) free(attr); | ||
501 | * | ||
502 | * free(preedit_string); | ||
503 | * @endcode | ||
504 | * @since 1.1.0 | ||
505 | */ | ||
506 | EAPI void | 287 | EAPI void |
507 | ecore_imf_context_preedit_string_with_attributes_get(Ecore_IMF_Context *ctx, char **str, Eina_List **attrs, int *cursor_pos) | 288 | ecore_imf_context_preedit_string_with_attributes_get(Ecore_IMF_Context *ctx, char **str, Eina_List **attrs, int *cursor_pos) |
508 | { | 289 | { |
@@ -522,25 +303,6 @@ ecore_imf_context_preedit_string_with_attributes_get(Ecore_IMF_Context *ctx, cha | |||
522 | } | 303 | } |
523 | } | 304 | } |
524 | 305 | ||
525 | /** | ||
526 | * Notify the Input Method Context that the widget to which its | ||
527 | * correspond has gained focus. | ||
528 | * | ||
529 | * @param ctx An #Ecore_IMF_Context. | ||
530 | * @ingroup Ecore_IMF_Context_Group | ||
531 | * | ||
532 | * Example | ||
533 | * @code | ||
534 | * static void | ||
535 | * _focus_in_cb(void *data, Evas_Object *o, const char *emission, const char *source) | ||
536 | * { | ||
537 | * ecore_imf_context_reset(imf_context); | ||
538 | * ecore_imf_context_focus_in(imf_context); | ||
539 | * } | ||
540 | * | ||
541 | * evas_object_event_callback_add(obj, EVAS_CALLBACK_FOCUS_IN, _focus_in_cb, ed); | ||
542 | * @endcode | ||
543 | */ | ||
544 | EAPI void | 306 | EAPI void |
545 | ecore_imf_context_focus_in(Ecore_IMF_Context *ctx) | 307 | ecore_imf_context_focus_in(Ecore_IMF_Context *ctx) |
546 | { | 308 | { |
@@ -553,25 +315,6 @@ ecore_imf_context_focus_in(Ecore_IMF_Context *ctx) | |||
553 | if (ctx->klass->focus_in) ctx->klass->focus_in(ctx); | 315 | if (ctx->klass->focus_in) ctx->klass->focus_in(ctx); |
554 | } | 316 | } |
555 | 317 | ||
556 | /** | ||
557 | * Notify the Input Method Context that the widget to which its | ||
558 | * correspond has lost focus. | ||
559 | * | ||
560 | * @param ctx An #Ecore_IMF_Context. | ||
561 | * @ingroup Ecore_IMF_Context_Group | ||
562 | * | ||
563 | * Example | ||
564 | * @code | ||
565 | * static void | ||
566 | * _focus_out_cb(void *data, Evas_Object *o, const char *emission, const char *source) | ||
567 | * { | ||
568 | * ecore_imf_context_reset(imf_context); | ||
569 | * ecore_imf_context_focus_out(imf_context); | ||
570 | * } | ||
571 | * | ||
572 | * evas_object_event_callback_add(obj, EVAS_CALLBACK_FOCUS_OUT, _focus_out_cb, ed); | ||
573 | * @endcode | ||
574 | */ | ||
575 | EAPI void | 318 | EAPI void |
576 | ecore_imf_context_focus_out(Ecore_IMF_Context *ctx) | 319 | ecore_imf_context_focus_out(Ecore_IMF_Context *ctx) |
577 | { | 320 | { |
@@ -584,26 +327,6 @@ ecore_imf_context_focus_out(Ecore_IMF_Context *ctx) | |||
584 | if (ctx->klass->focus_out) ctx->klass->focus_out(ctx); | 327 | if (ctx->klass->focus_out) ctx->klass->focus_out(ctx); |
585 | } | 328 | } |
586 | 329 | ||
587 | /** | ||
588 | * Notify the Input Method Context that a change such as a | ||
589 | * change in cursor position has been made. This will typically | ||
590 | * cause the Input Method Context to clear the preedit state. | ||
591 | * | ||
592 | * @param ctx An #Ecore_IMF_Context. | ||
593 | * @ingroup Ecore_IMF_Context_Group | ||
594 | * | ||
595 | * Example | ||
596 | * @code | ||
597 | * static void | ||
598 | * _focus_out_cb(void *data, Evas_Object *o, const char *emission, const char *source) | ||
599 | * { | ||
600 | * ecore_imf_context_reset(imf_context); | ||
601 | * ecore_imf_context_focus_out(imf_context); | ||
602 | * } | ||
603 | * | ||
604 | * evas_object_event_callback_add(obj, EVAS_CALLBACK_FOCUS_OUT, _focus_out_cb, ed); | ||
605 | * @endcode | ||
606 | */ | ||
607 | EAPI void | 330 | EAPI void |
608 | ecore_imf_context_reset(Ecore_IMF_Context *ctx) | 331 | ecore_imf_context_reset(Ecore_IMF_Context *ctx) |
609 | { | 332 | { |
@@ -616,14 +339,6 @@ ecore_imf_context_reset(Ecore_IMF_Context *ctx) | |||
616 | if (ctx->klass->reset) ctx->klass->reset(ctx); | 339 | if (ctx->klass->reset) ctx->klass->reset(ctx); |
617 | } | 340 | } |
618 | 341 | ||
619 | /** | ||
620 | * Notify the Input Method Context that a change in the cursor | ||
621 | * position has been made. | ||
622 | * | ||
623 | * @param ctx An #Ecore_IMF_Context. | ||
624 | * @param cursor_pos New cursor position in characters. | ||
625 | * @ingroup Ecore_IMF_Context_Group | ||
626 | */ | ||
627 | EAPI void | 342 | EAPI void |
628 | ecore_imf_context_cursor_position_set(Ecore_IMF_Context *ctx, int cursor_pos) | 343 | ecore_imf_context_cursor_position_set(Ecore_IMF_Context *ctx, int cursor_pos) |
629 | { | 344 | { |
@@ -636,20 +351,6 @@ ecore_imf_context_cursor_position_set(Ecore_IMF_Context *ctx, int cursor_pos) | |||
636 | if (ctx->klass->cursor_position_set) ctx->klass->cursor_position_set(ctx, cursor_pos); | 351 | if (ctx->klass->cursor_position_set) ctx->klass->cursor_position_set(ctx, cursor_pos); |
637 | } | 352 | } |
638 | 353 | ||
639 | /** | ||
640 | * Notify the Input Method Context that a change in the cursor | ||
641 | * location has been made. The location is relative to the canvas. | ||
642 | * The cursor location can be used to determine the position of | ||
643 | * candidate word window in the immodule. | ||
644 | * | ||
645 | * @param ctx An #Ecore_IMF_Context. | ||
646 | * @param x cursor x position. | ||
647 | * @param y cursor y position. | ||
648 | * @param w cursor width. | ||
649 | * @param h cursor height. | ||
650 | * @ingroup Ecore_IMF_Context_Group | ||
651 | * @since 1.1.0 | ||
652 | */ | ||
653 | EAPI void | 354 | EAPI void |
654 | ecore_imf_context_cursor_location_set(Ecore_IMF_Context *ctx, int x, int y, int w, int h) | 355 | ecore_imf_context_cursor_location_set(Ecore_IMF_Context *ctx, int x, int y, int w, int h) |
655 | { | 356 | { |
@@ -662,16 +363,6 @@ ecore_imf_context_cursor_location_set(Ecore_IMF_Context *ctx, int x, int y, int | |||
662 | if (ctx->klass->cursor_location_set) ctx->klass->cursor_location_set(ctx, x, y, w, h); | 363 | if (ctx->klass->cursor_location_set) ctx->klass->cursor_location_set(ctx, x, y, w, h); |
663 | } | 364 | } |
664 | 365 | ||
665 | /** | ||
666 | * Set whether the IM context should use the preedit string | ||
667 | * to display feedback. If @c use_preedit is @c EINA_FALSE (default | ||
668 | * is @c EINA_TRUE), then the IM context may use some other method to display | ||
669 | * feedback, such as displaying it in a child of the root window. | ||
670 | * | ||
671 | * @param ctx An #Ecore_IMF_Context. | ||
672 | * @param use_preedit Whether the IM context should use the preedit string. | ||
673 | * @ingroup Ecore_IMF_Context_Group | ||
674 | */ | ||
675 | EAPI void | 366 | EAPI void |
676 | ecore_imf_context_use_preedit_set(Ecore_IMF_Context *ctx, Eina_Bool use_preedit) | 367 | ecore_imf_context_use_preedit_set(Ecore_IMF_Context *ctx, Eina_Bool use_preedit) |
677 | { | 368 | { |
@@ -684,17 +375,6 @@ ecore_imf_context_use_preedit_set(Ecore_IMF_Context *ctx, Eina_Bool use_preedit) | |||
684 | if (ctx->klass->use_preedit_set) ctx->klass->use_preedit_set(ctx, use_preedit); | 375 | if (ctx->klass->use_preedit_set) ctx->klass->use_preedit_set(ctx, use_preedit); |
685 | } | 376 | } |
686 | 377 | ||
687 | /** | ||
688 | * Set whether the IM context should allow to use the text prediction. | ||
689 | * If @p prediction is @c EINA_FALSE (default is @c EINA_TRUE), then the IM | ||
690 | * context will not display the text prediction window. | ||
691 | * | ||
692 | * @param ctx An #Ecore_IMF_Context. | ||
693 | * @param prediction Whether the IM context should allow to use the text prediction. | ||
694 | * @note Default value is EINA_TRUE. | ||
695 | * @ingroup Ecore_IMF_Context_Group | ||
696 | * @since 1.1.0 | ||
697 | */ | ||
698 | EAPI void | 378 | EAPI void |
699 | ecore_imf_context_prediction_allow_set(Ecore_IMF_Context *ctx, Eina_Bool prediction) | 379 | ecore_imf_context_prediction_allow_set(Ecore_IMF_Context *ctx, Eina_Bool prediction) |
700 | { | 380 | { |
@@ -711,15 +391,6 @@ ecore_imf_context_prediction_allow_set(Ecore_IMF_Context *ctx, Eina_Bool predict | |||
711 | ctx->klass->prediction_allow_set(ctx, prediction); | 391 | ctx->klass->prediction_allow_set(ctx, prediction); |
712 | } | 392 | } |
713 | 393 | ||
714 | /** | ||
715 | * Get whether the IM context should allow to use the text prediction. | ||
716 | * | ||
717 | * @param ctx An #Ecore_IMF_Context. | ||
718 | * @return @c EINA_TRUE if it allows to use the text prediction, otherwise | ||
719 | * @c EINA_FALSE. | ||
720 | * @ingroup Ecore_IMF_Context_Group | ||
721 | * @since 1.1.0 | ||
722 | */ | ||
723 | EAPI Eina_Bool | 394 | EAPI Eina_Bool |
724 | ecore_imf_context_prediction_allow_get(Ecore_IMF_Context *ctx) | 395 | ecore_imf_context_prediction_allow_get(Ecore_IMF_Context *ctx) |
725 | { | 396 | { |
@@ -733,15 +404,6 @@ ecore_imf_context_prediction_allow_get(Ecore_IMF_Context *ctx) | |||
733 | return ctx->allow_prediction; | 404 | return ctx->allow_prediction; |
734 | } | 405 | } |
735 | 406 | ||
736 | /** | ||
737 | * Set the autocapitalization type on the immodule. | ||
738 | * | ||
739 | * @param ctx An #Ecore_IMF_Context. | ||
740 | * @param autocapital_type the autocapitalization type. | ||
741 | * @note Default type is ECORE_IMF_AUTOCAPITAL_TYPE_SENTENCE. | ||
742 | * @ingroup Ecore_IMF_Context_Group | ||
743 | * @since 1.1.0 | ||
744 | */ | ||
745 | EAPI void | 407 | EAPI void |
746 | ecore_imf_context_autocapital_type_set(Ecore_IMF_Context *ctx, Ecore_IMF_Autocapital_Type autocapital_type) | 408 | ecore_imf_context_autocapital_type_set(Ecore_IMF_Context *ctx, Ecore_IMF_Autocapital_Type autocapital_type) |
747 | { | 409 | { |
@@ -757,14 +419,6 @@ ecore_imf_context_autocapital_type_set(Ecore_IMF_Context *ctx, Ecore_IMF_Autocap | |||
757 | if (ctx->klass->autocapital_type_set) ctx->klass->autocapital_type_set(ctx, autocapital_type); | 419 | if (ctx->klass->autocapital_type_set) ctx->klass->autocapital_type_set(ctx, autocapital_type); |
758 | } | 420 | } |
759 | 421 | ||
760 | /** | ||
761 | * Get the autocapitalization type. | ||
762 | * | ||
763 | * @param ctx An #Ecore_IMF_Context. | ||
764 | * @return The autocapital type being used by @p ctx. | ||
765 | * @ingroup Ecore_IMF_Context_Group | ||
766 | * @since 1.1.0 | ||
767 | */ | ||
768 | EAPI Ecore_IMF_Autocapital_Type | 422 | EAPI Ecore_IMF_Autocapital_Type |
769 | ecore_imf_context_autocapital_type_get(Ecore_IMF_Context *ctx) | 423 | ecore_imf_context_autocapital_type_get(Ecore_IMF_Context *ctx) |
770 | { | 424 | { |
@@ -778,17 +432,6 @@ ecore_imf_context_autocapital_type_get(Ecore_IMF_Context *ctx) | |||
778 | return ctx->autocapital_type; | 432 | return ctx->autocapital_type; |
779 | } | 433 | } |
780 | 434 | ||
781 | /** | ||
782 | * Set the callback to be used on surrounding_get request. | ||
783 | * | ||
784 | * This callback will be called when the Input Method Context | ||
785 | * module requests the surrounding context. | ||
786 | * | ||
787 | * @param ctx An #Ecore_IMF_Context. | ||
788 | * @param func The callback to be called. | ||
789 | * @param data The data pointer to be passed to @p func | ||
790 | * @ingroup Ecore_IMF_Context_Group | ||
791 | */ | ||
792 | EAPI void | 435 | EAPI void |
793 | ecore_imf_context_retrieve_surrounding_callback_set(Ecore_IMF_Context *ctx, Eina_Bool (*func)(void *data, Ecore_IMF_Context *ctx, char **text, int *cursor_pos), const void *data) | 436 | ecore_imf_context_retrieve_surrounding_callback_set(Ecore_IMF_Context *ctx, Eina_Bool (*func)(void *data, Ecore_IMF_Context *ctx, char **text, int *cursor_pos), const void *data) |
794 | { | 437 | { |
@@ -803,17 +446,6 @@ ecore_imf_context_retrieve_surrounding_callback_set(Ecore_IMF_Context *ctx, Eina | |||
803 | ctx->retrieve_surrounding_data = (void *) data; | 446 | ctx->retrieve_surrounding_data = (void *) data; |
804 | } | 447 | } |
805 | 448 | ||
806 | /** | ||
807 | * Set the input mode used by the Ecore Input Context. | ||
808 | * | ||
809 | * The input mode can be one of the input modes defined in | ||
810 | * Ecore_IMF_Input_Mode. The default input mode is | ||
811 | * ECORE_IMF_INPUT_MODE_FULL. | ||
812 | * | ||
813 | * @param ctx An #Ecore_IMF_Context. | ||
814 | * @param input_mode The input mode to be used by @p ctx. | ||
815 | * @ingroup Ecore_IMF_Context_Group | ||
816 | */ | ||
817 | EAPI void | 449 | EAPI void |
818 | ecore_imf_context_input_mode_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Mode input_mode) | 450 | ecore_imf_context_input_mode_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Mode input_mode) |
819 | { | 451 | { |
@@ -827,15 +459,6 @@ ecore_imf_context_input_mode_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Mode in | |||
827 | ctx->input_mode = input_mode; | 459 | ctx->input_mode = input_mode; |
828 | } | 460 | } |
829 | 461 | ||
830 | /** | ||
831 | * Get the input mode being used by the Ecore Input Context. | ||
832 | * | ||
833 | * See @ref ecore_imf_context_input_mode_set for more details. | ||
834 | * | ||
835 | * @param ctx An #Ecore_IMF_Context. | ||
836 | * @return The input mode being used by @p ctx. | ||
837 | * @ingroup Ecore_IMF_Context_Group | ||
838 | */ | ||
839 | EAPI Ecore_IMF_Input_Mode | 462 | EAPI Ecore_IMF_Input_Mode |
840 | ecore_imf_context_input_mode_get(Ecore_IMF_Context *ctx) | 463 | ecore_imf_context_input_mode_get(Ecore_IMF_Context *ctx) |
841 | { | 464 | { |
@@ -848,43 +471,6 @@ ecore_imf_context_input_mode_get(Ecore_IMF_Context *ctx) | |||
848 | return ctx->input_mode; | 471 | return ctx->input_mode; |
849 | } | 472 | } |
850 | 473 | ||
851 | /** | ||
852 | * Allow an Ecore Input Context to internally handle an event. | ||
853 | * If this function returns @c EINA_TRUE, then no further processing | ||
854 | * should be done for this event. | ||
855 | * | ||
856 | * Input methods must be able to accept all types of events (simply | ||
857 | * returning @c EINA_FALSE if the event was not handled), but there is no | ||
858 | * obligation of any events to be submitted to this function. | ||
859 | * | ||
860 | * @param ctx An #Ecore_IMF_Context. | ||
861 | * @param type The type of event defined by #Ecore_IMF_Event_Type. | ||
862 | * @param event The event itself. | ||
863 | * @return @c EINA_TRUE if the event was handled; otherwise @c EINA_FALSE. | ||
864 | * @ingroup Ecore_IMF_Context_Group | ||
865 | * | ||
866 | * Example | ||
867 | * @code | ||
868 | * static void | ||
869 | * _key_down_cb(void *data, Evas *e, Evas_Object *obj, void *event_info) | ||
870 | * { | ||
871 | * Evas_Event_Key_Down *ev = event_info; | ||
872 | * if (!ev->keyname) return; | ||
873 | * | ||
874 | * if (imf_context) | ||
875 | * { | ||
876 | * Ecore_IMF_Event_Key_Down ecore_ev; | ||
877 | * ecore_imf_evas_event_key_down_wrap(ev, &ecore_ev); | ||
878 | * if (ecore_imf_context_filter_event(imf_context, | ||
879 | * ECORE_IMF_EVENT_KEY_DOWN, | ||
880 | * (Ecore_IMF_Event *)&ecore_ev)) | ||
881 | * return; | ||
882 | * } | ||
883 | * } | ||
884 | * | ||
885 | * evas_object_event_callback_add(obj, EVAS_CALLBACK_KEY_DOWN, _key_down_cb, data); | ||
886 | * @endcode | ||
887 | */ | ||
888 | EAPI Eina_Bool | 474 | EAPI Eina_Bool |
889 | ecore_imf_context_filter_event(Ecore_IMF_Context *ctx, Ecore_IMF_Event_Type type, Ecore_IMF_Event *event) | 475 | ecore_imf_context_filter_event(Ecore_IMF_Context *ctx, Ecore_IMF_Event_Type type, Ecore_IMF_Event *event) |
890 | { | 476 | { |
@@ -898,23 +484,6 @@ ecore_imf_context_filter_event(Ecore_IMF_Context *ctx, Ecore_IMF_Event_Type type | |||
898 | return EINA_FALSE; | 484 | return EINA_FALSE; |
899 | } | 485 | } |
900 | 486 | ||
901 | /** | ||
902 | * @defgroup Ecore_IMF_Context_Module_Group Ecore Input Method Context Module Functions | ||
903 | * @ingroup Ecore_IMF_Lib_Group | ||
904 | * | ||
905 | * Functions that should be used by Ecore Input Method Context modules. | ||
906 | */ | ||
907 | |||
908 | /** | ||
909 | * Creates a new Input Method Context with klass specified by @p ctxc. | ||
910 | * | ||
911 | * This method should be used by modules implementing the Input | ||
912 | * Method Context interface. | ||
913 | * | ||
914 | * @param ctxc An #Ecore_IMF_Context_Class. | ||
915 | * @return A new #Ecore_IMF_Context; on failure it returns NULL. | ||
916 | * @ingroup Ecore_IMF_Context_Module_Group | ||
917 | */ | ||
918 | EAPI Ecore_IMF_Context * | 487 | EAPI Ecore_IMF_Context * |
919 | ecore_imf_context_new(const Ecore_IMF_Context_Class *ctxc) | 488 | ecore_imf_context_new(const Ecore_IMF_Context_Class *ctxc) |
920 | { | 489 | { |
@@ -931,18 +500,6 @@ ecore_imf_context_new(const Ecore_IMF_Context_Class *ctxc) | |||
931 | return ctx; | 500 | return ctx; |
932 | } | 501 | } |
933 | 502 | ||
934 | /** | ||
935 | * Set the Input Method Context specific data. | ||
936 | * | ||
937 | * Note that this method should be used by modules to set | ||
938 | * the Input Method Context specific data and it's not meant to | ||
939 | * be used by applications to store application specific data. | ||
940 | * | ||
941 | * @param ctx An #Ecore_IMF_Context. | ||
942 | * @param data The Input Method Context specific data. | ||
943 | * @return A new #Ecore_IMF_Context; on failure it returns NULL. | ||
944 | * @ingroup Ecore_IMF_Context_Module_Group | ||
945 | */ | ||
946 | EAPI void | 503 | EAPI void |
947 | ecore_imf_context_data_set(Ecore_IMF_Context *ctx, void *data) | 504 | ecore_imf_context_data_set(Ecore_IMF_Context *ctx, void *data) |
948 | { | 505 | { |
@@ -955,15 +512,6 @@ ecore_imf_context_data_set(Ecore_IMF_Context *ctx, void *data) | |||
955 | ctx->data = data; | 512 | ctx->data = data; |
956 | } | 513 | } |
957 | 514 | ||
958 | /** | ||
959 | * Get the Input Method Context specific data. | ||
960 | * | ||
961 | * See @ref ecore_imf_context_data_set for more details. | ||
962 | * | ||
963 | * @param ctx An #Ecore_IMF_Context. | ||
964 | * @return The Input Method Context specific data. | ||
965 | * @ingroup Ecore_IMF_Context_Module_Group | ||
966 | */ | ||
967 | EAPI void *ecore_imf_context_data_get(Ecore_IMF_Context *ctx) | 515 | EAPI void *ecore_imf_context_data_get(Ecore_IMF_Context *ctx) |
968 | { | 516 | { |
969 | if (!ECORE_MAGIC_CHECK(ctx, ECORE_MAGIC_CONTEXT)) | 517 | if (!ECORE_MAGIC_CHECK(ctx, ECORE_MAGIC_CONTEXT)) |
@@ -975,31 +523,6 @@ EAPI void *ecore_imf_context_data_get(Ecore_IMF_Context *ctx) | |||
975 | return ctx->data; | 523 | return ctx->data; |
976 | } | 524 | } |
977 | 525 | ||
978 | /** | ||
979 | * Retrieve context around insertion point. | ||
980 | * Input methods typically want context in order to constrain input text based on existing text; | ||
981 | * this is important for languages such as Thai where only some sequences of characters are allowed. | ||
982 | * In addition, the text around the insertion point can be used for supporting autocapital feature. | ||
983 | * | ||
984 | * This function is implemented by calling the | ||
985 | * Ecore_IMF_Context::retrieve_surrounding_func ( | ||
986 | * set using #ecore_imf_context_retrieve_surrounding_callback_set). | ||
987 | * | ||
988 | * There is no obligation for a widget to respond to the | ||
989 | * retrieve_surrounding_func, so input methods must be prepared | ||
990 | * to function without context. | ||
991 | * | ||
992 | * @param ctx An #Ecore_IMF_Context. | ||
993 | * @param text Location to store a UTF-8 encoded string of text | ||
994 | * holding context around the insertion point. | ||
995 | * If the function returns @c EINA_TRUE, then you must free | ||
996 | * the result stored in this location with free(). | ||
997 | * @param cursor_pos Location to store the position in characters of | ||
998 | * the insertion cursor within @p text. | ||
999 | * @return @c EINA_TRUE if surrounding text was provided; otherwise | ||
1000 | * @c EINA_FALSE. | ||
1001 | * @ingroup Ecore_IMF_Context_Module_Group | ||
1002 | */ | ||
1003 | EAPI Eina_Bool | 526 | EAPI Eina_Bool |
1004 | ecore_imf_context_surrounding_get(Ecore_IMF_Context *ctx, char **text, int *cursor_pos) | 527 | ecore_imf_context_surrounding_get(Ecore_IMF_Context *ctx, char **text, int *cursor_pos) |
1005 | { | 528 | { |
@@ -1030,16 +553,6 @@ _ecore_imf_event_free_preedit(void *data EINA_UNUSED, void *event) | |||
1030 | free(event); | 553 | free(event); |
1031 | } | 554 | } |
1032 | 555 | ||
1033 | /** | ||
1034 | * Adds ECORE_IMF_EVENT_PREEDIT_START to the event queue. | ||
1035 | * | ||
1036 | * ECORE_IMF_EVENT_PREEDIT_START should be added when a new preedit sequence starts. | ||
1037 | * It's asynchronous method to put event to the event queue. | ||
1038 | * ecore_imf_context_event_callback_call() can be used as synchronous method. | ||
1039 | * | ||
1040 | * @param ctx An #Ecore_IMF_Context. | ||
1041 | * @ingroup Ecore_IMF_Context_Module_Group | ||
1042 | */ | ||
1043 | EAPI void | 556 | EAPI void |
1044 | ecore_imf_context_preedit_start_event_add(Ecore_IMF_Context *ctx) | 557 | ecore_imf_context_preedit_start_event_add(Ecore_IMF_Context *ctx) |
1045 | { | 558 | { |
@@ -1058,16 +571,6 @@ ecore_imf_context_preedit_start_event_add(Ecore_IMF_Context *ctx) | |||
1058 | ev, _ecore_imf_event_free_preedit, NULL); | 571 | ev, _ecore_imf_event_free_preedit, NULL); |
1059 | } | 572 | } |
1060 | 573 | ||
1061 | /** | ||
1062 | * Adds ECORE_IMF_EVENT_PREEDIT_END to the event queue. | ||
1063 | * | ||
1064 | * ECORE_IMF_EVENT_PREEDIT_END should be added when a new preedit sequence has been completed or canceled. | ||
1065 | * It's asynchronous method to put event to the event queue. | ||
1066 | * ecore_imf_context_event_callback_call() can be used as synchronous method. | ||
1067 | * | ||
1068 | * @param ctx An #Ecore_IMF_Context. | ||
1069 | * @ingroup Ecore_IMF_Context_Module_Group | ||
1070 | */ | ||
1071 | EAPI void | 574 | EAPI void |
1072 | ecore_imf_context_preedit_end_event_add(Ecore_IMF_Context *ctx) | 575 | ecore_imf_context_preedit_end_event_add(Ecore_IMF_Context *ctx) |
1073 | { | 576 | { |
@@ -1086,15 +589,6 @@ ecore_imf_context_preedit_end_event_add(Ecore_IMF_Context *ctx) | |||
1086 | ev, _ecore_imf_event_free_preedit, NULL); | 589 | ev, _ecore_imf_event_free_preedit, NULL); |
1087 | } | 590 | } |
1088 | 591 | ||
1089 | /** | ||
1090 | * Adds ECORE_IMF_EVENT_PREEDIT_CHANGED to the event queue. | ||
1091 | * | ||
1092 | * It's asynchronous method to put event to the event queue. | ||
1093 | * ecore_imf_context_event_callback_call() can be used as synchronous method. | ||
1094 | * | ||
1095 | * @param ctx An #Ecore_IMF_Context. | ||
1096 | * @ingroup Ecore_IMF_Context_Module_Group | ||
1097 | */ | ||
1098 | EAPI void | 592 | EAPI void |
1099 | ecore_imf_context_preedit_changed_event_add(Ecore_IMF_Context *ctx) | 593 | ecore_imf_context_preedit_changed_event_add(Ecore_IMF_Context *ctx) |
1100 | { | 594 | { |
@@ -1123,16 +617,6 @@ _ecore_imf_event_free_commit(void *data EINA_UNUSED, void *event) | |||
1123 | free(ev); | 617 | free(ev); |
1124 | } | 618 | } |
1125 | 619 | ||
1126 | /** | ||
1127 | * Adds ECORE_IMF_EVENT_COMMIT to the event queue. | ||
1128 | * | ||
1129 | * It's asynchronous method to put event to the event queue. | ||
1130 | * ecore_imf_context_event_callback_call() can be used as synchronous method. | ||
1131 | * | ||
1132 | * @param ctx An #Ecore_IMF_Context. | ||
1133 | * @param str The committed string. | ||
1134 | * @ingroup Ecore_IMF_Context_Module_Group | ||
1135 | */ | ||
1136 | EAPI void | 620 | EAPI void |
1137 | ecore_imf_context_commit_event_add(Ecore_IMF_Context *ctx, const char *str) | 621 | ecore_imf_context_commit_event_add(Ecore_IMF_Context *ctx, const char *str) |
1138 | { | 622 | { |
@@ -1150,7 +634,6 @@ ecore_imf_context_commit_event_add(Ecore_IMF_Context *ctx, const char *str) | |||
1150 | ev->str = str ? strdup(str) : NULL; | 634 | ev->str = str ? strdup(str) : NULL; |
1151 | ecore_event_add(ECORE_IMF_EVENT_COMMIT, | 635 | ecore_event_add(ECORE_IMF_EVENT_COMMIT, |
1152 | ev, _ecore_imf_event_free_commit, NULL); | 636 | ev, _ecore_imf_event_free_commit, NULL); |
1153 | |||
1154 | } | 637 | } |
1155 | 638 | ||
1156 | static void | 639 | static void |
@@ -1159,21 +642,6 @@ _ecore_imf_event_free_delete_surrounding(void *data EINA_UNUSED, void *event) | |||
1159 | free(event); | 642 | free(event); |
1160 | } | 643 | } |
1161 | 644 | ||
1162 | /** | ||
1163 | * Adds ECORE_IMF_EVENT_DELETE_SURROUNDING to the event queue. | ||
1164 | * | ||
1165 | * Asks the widget that the input context is attached to to delete characters around the cursor position | ||
1166 | * by adding the ECORE_IMF_EVENT_DELETE_SURROUNDING to the event queue. | ||
1167 | * Note that offset and n_chars are in characters not in bytes. | ||
1168 | * | ||
1169 | * It's asynchronous method to put ECORE_IMF_EVENT_DELETE_SURROUNDING event to the event queue. | ||
1170 | * ecore_imf_context_event_callback_call() can be used as synchronous method. | ||
1171 | * | ||
1172 | * @param ctx An #Ecore_IMF_Context. | ||
1173 | * @param offset The start offset of surrounding to be deleted. | ||
1174 | * @param n_chars The number of characters to be deleted. | ||
1175 | * @ingroup Ecore_IMF_Context_Module_Group | ||
1176 | */ | ||
1177 | EAPI void | 645 | EAPI void |
1178 | ecore_imf_context_delete_surrounding_event_add(Ecore_IMF_Context *ctx, int offset, int n_chars) | 646 | ecore_imf_context_delete_surrounding_event_add(Ecore_IMF_Context *ctx, int offset, int n_chars) |
1179 | { | 647 | { |
@@ -1194,38 +662,6 @@ ecore_imf_context_delete_surrounding_event_add(Ecore_IMF_Context *ctx, int offse | |||
1194 | ev, _ecore_imf_event_free_delete_surrounding, NULL); | 662 | ev, _ecore_imf_event_free_delete_surrounding, NULL); |
1195 | } | 663 | } |
1196 | 664 | ||
1197 | /** | ||
1198 | * Add (register) a callback function to a given context event. | ||
1199 | * | ||
1200 | * This function adds a function callback to the context @p ctx when the | ||
1201 | * event of type @p type occurs on it. The function pointer is @p | ||
1202 | * func. | ||
1203 | * | ||
1204 | * The event type @p type to trigger the function may be one of | ||
1205 | * #ECORE_IMF_CALLBACK_PREEDIT_START, #ECORE_IMF_CALLBACK_PREEDIT_END, | ||
1206 | * #ECORE_IMF_CALLBACK_PREEDIT_CHANGED, #ECORE_IMF_CALLBACK_COMMIT and | ||
1207 | * #ECORE_IMF_CALLBACK_DELETE_SURROUNDING. | ||
1208 | * | ||
1209 | * @param ctx Ecore_IMF_Context to attach a callback to. | ||
1210 | * @param type The type of event that will trigger the callback | ||
1211 | * @param func The (callback) function to be called when the event is | ||
1212 | * triggered | ||
1213 | * @param data The data pointer to be passed to @p func | ||
1214 | * @ingroup Ecore_IMF_Context_Group | ||
1215 | * @since 1.2.0 | ||
1216 | * | ||
1217 | * Example | ||
1218 | * @code | ||
1219 | * static void | ||
1220 | * _imf_event_commit_cb(void *data, Ecore_IMF_Context *ctx, void *event_info) | ||
1221 | * { | ||
1222 | * char *commit_str = event_info; | ||
1223 | * // something to do | ||
1224 | * } | ||
1225 | * | ||
1226 | * ecore_imf_context_event_callback_add(en->imf_context, ECORE_IMF_CALLBACK_COMMIT, _imf_event_commit_cb, data); | ||
1227 | * @endcode | ||
1228 | */ | ||
1229 | EAPI void | 665 | EAPI void |
1230 | ecore_imf_context_event_callback_add(Ecore_IMF_Context *ctx, Ecore_IMF_Callback_Type type, Ecore_IMF_Event_Cb func, const void *data) | 666 | ecore_imf_context_event_callback_add(Ecore_IMF_Context *ctx, Ecore_IMF_Callback_Type type, Ecore_IMF_Event_Cb func, const void *data) |
1231 | { | 667 | { |
@@ -1250,23 +686,6 @@ ecore_imf_context_event_callback_add(Ecore_IMF_Context *ctx, Ecore_IMF_Callback_ | |||
1250 | ctx->callbacks = eina_list_append(ctx->callbacks, fn); | 686 | ctx->callbacks = eina_list_append(ctx->callbacks, fn); |
1251 | } | 687 | } |
1252 | 688 | ||
1253 | /** | ||
1254 | * Delete (unregister) a callback function registered to a given | ||
1255 | * context event. | ||
1256 | * | ||
1257 | * This function removes a function callback from the context @p ctx when the | ||
1258 | * event of type @p type occurs on it. The function pointer is @p | ||
1259 | * func. | ||
1260 | * | ||
1261 | * @see ecore_imf_context_event_callback_add() for more details | ||
1262 | * | ||
1263 | * @param ctx Ecore_IMF_Context to remove a callback from. | ||
1264 | * @param type The type of event that was triggering the callback | ||
1265 | * @param func The (callback) function that was to be called when the event was triggered | ||
1266 | * @return the data pointer | ||
1267 | * @ingroup Ecore_IMF_Context_Group | ||
1268 | * @since 1.2.0 | ||
1269 | */ | ||
1270 | EAPI void * | 689 | EAPI void * |
1271 | ecore_imf_context_event_callback_del(Ecore_IMF_Context *ctx, Ecore_IMF_Callback_Type type, Ecore_IMF_Event_Cb func) | 690 | ecore_imf_context_event_callback_del(Ecore_IMF_Context *ctx, Ecore_IMF_Callback_Type type, Ecore_IMF_Event_Cb func) |
1272 | { | 691 | { |
@@ -1297,23 +716,6 @@ ecore_imf_context_event_callback_del(Ecore_IMF_Context *ctx, Ecore_IMF_Callback_ | |||
1297 | return NULL; | 716 | return NULL; |
1298 | } | 717 | } |
1299 | 718 | ||
1300 | /** | ||
1301 | * Call a given callback on the context @p ctx. | ||
1302 | * | ||
1303 | * ecore_imf_context_preedit_start_event_add(), ecore_imf_context_preedit_end_event_add(), | ||
1304 | * ecore_imf_context_preedit_changed_event_add(), ecore_imf_context_commit_event_add() and | ||
1305 | * ecore_imf_context_delete_surrounding_event_add() APIs are asynchronous | ||
1306 | * because those API adds each event to the event queue. | ||
1307 | * | ||
1308 | * This API provides the way to call each callback function immediately. | ||
1309 | * | ||
1310 | * @param ctx Ecore_IMF_Context. | ||
1311 | * @param type The type of event that will trigger the callback | ||
1312 | * @param event_info The pointer to event specific struct or information to | ||
1313 | * pass to the callback functions registered on this event | ||
1314 | * @ingroup Ecore_IMF_Context_Module_Group | ||
1315 | * @since 1.2.0 | ||
1316 | */ | ||
1317 | EAPI void | 719 | EAPI void |
1318 | ecore_imf_context_event_callback_call(Ecore_IMF_Context *ctx, Ecore_IMF_Callback_Type type, void *event_info) | 720 | ecore_imf_context_event_callback_call(Ecore_IMF_Context *ctx, Ecore_IMF_Callback_Type type, void *event_info) |
1319 | { | 721 | { |
@@ -1334,13 +736,6 @@ ecore_imf_context_event_callback_call(Ecore_IMF_Context *ctx, Ecore_IMF_Callback | |||
1334 | } | 736 | } |
1335 | } | 737 | } |
1336 | 738 | ||
1337 | /** | ||
1338 | * Ask the Input Method Context to show the control panel of using Input Method. | ||
1339 | * | ||
1340 | * @param ctx An #Ecore_IMF_Context. | ||
1341 | * @ingroup Ecore_IMF_Context_Group | ||
1342 | * @since 1.1.0 | ||
1343 | */ | ||
1344 | EAPI void | 739 | EAPI void |
1345 | ecore_imf_context_control_panel_show(Ecore_IMF_Context *ctx) | 740 | ecore_imf_context_control_panel_show(Ecore_IMF_Context *ctx) |
1346 | { | 741 | { |
@@ -1354,13 +749,6 @@ ecore_imf_context_control_panel_show(Ecore_IMF_Context *ctx) | |||
1354 | if (ctx->klass->control_panel_show) ctx->klass->control_panel_show(ctx); | 749 | if (ctx->klass->control_panel_show) ctx->klass->control_panel_show(ctx); |
1355 | } | 750 | } |
1356 | 751 | ||
1357 | /** | ||
1358 | * Ask the Input Method Context to hide the control panel of using Input Method. | ||
1359 | * | ||
1360 | * @param ctx An #Ecore_IMF_Context. | ||
1361 | * @ingroup Ecore_IMF_Context_Group | ||
1362 | * @since 1.1.0 | ||
1363 | */ | ||
1364 | EAPI void | 752 | EAPI void |
1365 | ecore_imf_context_control_panel_hide(Ecore_IMF_Context *ctx) | 753 | ecore_imf_context_control_panel_hide(Ecore_IMF_Context *ctx) |
1366 | { | 754 | { |
@@ -1374,13 +762,6 @@ ecore_imf_context_control_panel_hide(Ecore_IMF_Context *ctx) | |||
1374 | if (ctx->klass->control_panel_hide) ctx->klass->control_panel_hide(ctx); | 762 | if (ctx->klass->control_panel_hide) ctx->klass->control_panel_hide(ctx); |
1375 | } | 763 | } |
1376 | 764 | ||
1377 | /** | ||
1378 | * Ask the Input Method Context to show the input panel (virtual keyboard). | ||
1379 | * | ||
1380 | * @param ctx An #Ecore_IMF_Context. | ||
1381 | * @ingroup Ecore_IMF_Context_Group | ||
1382 | * @since 1.1.0 | ||
1383 | */ | ||
1384 | EAPI void | 765 | EAPI void |
1385 | ecore_imf_context_input_panel_show(Ecore_IMF_Context *ctx) | 766 | ecore_imf_context_input_panel_show(Ecore_IMF_Context *ctx) |
1386 | { | 767 | { |
@@ -1394,13 +775,6 @@ ecore_imf_context_input_panel_show(Ecore_IMF_Context *ctx) | |||
1394 | if (ctx->klass->show) ctx->klass->show(ctx); | 775 | if (ctx->klass->show) ctx->klass->show(ctx); |
1395 | } | 776 | } |
1396 | 777 | ||
1397 | /** | ||
1398 | * Ask the Input Method Context to hide the input panel. | ||
1399 | * | ||
1400 | * @param ctx An #Ecore_IMF_Context. | ||
1401 | * @ingroup Ecore_IMF_Context_Group | ||
1402 | * @since 1.1.0 | ||
1403 | */ | ||
1404 | EAPI void | 778 | EAPI void |
1405 | ecore_imf_context_input_panel_hide(Ecore_IMF_Context *ctx) | 779 | ecore_imf_context_input_panel_hide(Ecore_IMF_Context *ctx) |
1406 | { | 780 | { |
@@ -1414,15 +788,6 @@ ecore_imf_context_input_panel_hide(Ecore_IMF_Context *ctx) | |||
1414 | if (ctx->klass->hide) ctx->klass->hide(ctx); | 788 | if (ctx->klass->hide) ctx->klass->hide(ctx); |
1415 | } | 789 | } |
1416 | 790 | ||
1417 | /** | ||
1418 | * Set the layout of the input panel. | ||
1419 | * | ||
1420 | * @param ctx An #Ecore_IMF_Context. | ||
1421 | * @param layout see #Ecore_IMF_Input_Panel_Layout | ||
1422 | * @note Default layout type is ECORE_IMF_INPUT_PANEL_LAYOUT_NORMAL. | ||
1423 | * @ingroup Ecore_IMF_Context_Group | ||
1424 | * @since 1.1.0 | ||
1425 | */ | ||
1426 | EAPI void | 791 | EAPI void |
1427 | ecore_imf_context_input_panel_layout_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Panel_Layout layout) | 792 | ecore_imf_context_input_panel_layout_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Panel_Layout layout) |
1428 | { | 793 | { |
@@ -1439,14 +804,6 @@ ecore_imf_context_input_panel_layout_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input | |||
1439 | ctx->input_panel_layout = layout; | 804 | ctx->input_panel_layout = layout; |
1440 | } | 805 | } |
1441 | 806 | ||
1442 | /** | ||
1443 | * Get the layout of the current active input panel. | ||
1444 | * | ||
1445 | * @param ctx An #Ecore_IMF_Context. | ||
1446 | * @return layout see #Ecore_IMF_Input_Panel_Layout | ||
1447 | * @ingroup Ecore_IMF_Context_Group | ||
1448 | * @since 1.1.0 | ||
1449 | */ | ||
1450 | EAPI Ecore_IMF_Input_Panel_Layout | 807 | EAPI Ecore_IMF_Input_Panel_Layout |
1451 | ecore_imf_context_input_panel_layout_get(Ecore_IMF_Context *ctx) | 808 | ecore_imf_context_input_panel_layout_get(Ecore_IMF_Context *ctx) |
1452 | { | 809 | { |
@@ -1463,15 +820,6 @@ ecore_imf_context_input_panel_layout_get(Ecore_IMF_Context *ctx) | |||
1463 | return ECORE_IMF_INPUT_PANEL_LAYOUT_INVALID; | 820 | return ECORE_IMF_INPUT_PANEL_LAYOUT_INVALID; |
1464 | } | 821 | } |
1465 | 822 | ||
1466 | /** | ||
1467 | * Set the language of the input panel. | ||
1468 | * This API can be used when you want to show the English keyboard. | ||
1469 | * | ||
1470 | * @param ctx An #Ecore_IMF_Context. | ||
1471 | * @param lang the language to be set to the input panel. | ||
1472 | * @ingroup Ecore_IMF_Context_Group | ||
1473 | * @since 1.1.0 | ||
1474 | */ | ||
1475 | EAPI void | 823 | EAPI void |
1476 | ecore_imf_context_input_panel_language_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Panel_Lang lang) | 824 | ecore_imf_context_input_panel_language_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Panel_Lang lang) |
1477 | { | 825 | { |
@@ -1486,16 +834,6 @@ ecore_imf_context_input_panel_language_set(Ecore_IMF_Context *ctx, Ecore_IMF_Inp | |||
1486 | ctx->input_panel_lang = lang; | 834 | ctx->input_panel_lang = lang; |
1487 | } | 835 | } |
1488 | 836 | ||
1489 | /** | ||
1490 | * Get the language of the input panel. | ||
1491 | * | ||
1492 | * See @ref ecore_imf_context_input_panel_language_set for more details. | ||
1493 | * | ||
1494 | * @param ctx An #Ecore_IMF_Context. | ||
1495 | * @return Ecore_IMF_Input_Panel_Lang | ||
1496 | * @ingroup Ecore_IMF_Context_Group | ||
1497 | * @since 1.1.0 | ||
1498 | */ | ||
1499 | EAPI Ecore_IMF_Input_Panel_Lang | 837 | EAPI Ecore_IMF_Input_Panel_Lang |
1500 | ecore_imf_context_input_panel_language_get(Ecore_IMF_Context *ctx) | 838 | ecore_imf_context_input_panel_language_get(Ecore_IMF_Context *ctx) |
1501 | { | 839 | { |
@@ -1509,15 +847,6 @@ ecore_imf_context_input_panel_language_get(Ecore_IMF_Context *ctx) | |||
1509 | return ctx->input_panel_lang; | 847 | return ctx->input_panel_lang; |
1510 | } | 848 | } |
1511 | 849 | ||
1512 | /** | ||
1513 | * Set whether the Input Method Context should request to show the input panel automatically | ||
1514 | * when the widget has focus. | ||
1515 | * | ||
1516 | * @param ctx An #Ecore_IMF_Context. | ||
1517 | * @param enabled If true, the input panel will be shown when the widget is clicked or has focus. | ||
1518 | * @ingroup Ecore_IMF_Context_Group | ||
1519 | * @since 1.1.0 | ||
1520 | */ | ||
1521 | EAPI void | 850 | EAPI void |
1522 | ecore_imf_context_input_panel_enabled_set(Ecore_IMF_Context *ctx, | 851 | ecore_imf_context_input_panel_enabled_set(Ecore_IMF_Context *ctx, |
1523 | Eina_Bool enabled) | 852 | Eina_Bool enabled) |
@@ -1532,14 +861,6 @@ ecore_imf_context_input_panel_enabled_set(Ecore_IMF_Context *ctx, | |||
1532 | ctx->input_panel_enabled = enabled; | 861 | ctx->input_panel_enabled = enabled; |
1533 | } | 862 | } |
1534 | 863 | ||
1535 | /** | ||
1536 | * Get whether the Input Method Context requests to show the input panel automatically. | ||
1537 | * | ||
1538 | * @param ctx An #Ecore_IMF_Context. | ||
1539 | * @return Return the attribute to show the input panel automatically | ||
1540 | * @ingroup Ecore_IMF_Context_Group | ||
1541 | * @since 1.1.0 | ||
1542 | */ | ||
1543 | EAPI Eina_Bool | 864 | EAPI Eina_Bool |
1544 | ecore_imf_context_input_panel_enabled_get(Ecore_IMF_Context *ctx) | 865 | ecore_imf_context_input_panel_enabled_get(Ecore_IMF_Context *ctx) |
1545 | { | 866 | { |
@@ -1553,18 +874,6 @@ ecore_imf_context_input_panel_enabled_get(Ecore_IMF_Context *ctx) | |||
1553 | return ctx->input_panel_enabled; | 874 | return ctx->input_panel_enabled; |
1554 | } | 875 | } |
1555 | 876 | ||
1556 | /** | ||
1557 | * Set the input panel-specific data to deliver to the input panel. | ||
1558 | * This API is used by applications to deliver specific data to the input panel. | ||
1559 | * The data format MUST be negotiated by both application and the input panel. | ||
1560 | * The size and format of data are defined by the input panel. | ||
1561 | * | ||
1562 | * @param ctx An #Ecore_IMF_Context. | ||
1563 | * @param data The specific data to be set to the input panel. | ||
1564 | * @param len the length of data, in bytes, to send to the input panel | ||
1565 | * @ingroup Ecore_IMF_Context_Group | ||
1566 | * @since 1.2.0 | ||
1567 | */ | ||
1568 | EAPI void | 877 | EAPI void |
1569 | ecore_imf_context_input_panel_imdata_set(Ecore_IMF_Context *ctx, const void *data, int len) | 878 | ecore_imf_context_input_panel_imdata_set(Ecore_IMF_Context *ctx, const void *data, int len) |
1570 | { | 879 | { |
@@ -1581,15 +890,6 @@ ecore_imf_context_input_panel_imdata_set(Ecore_IMF_Context *ctx, const void *dat | |||
1581 | ctx->klass->input_panel_imdata_set(ctx, data, len); | 890 | ctx->klass->input_panel_imdata_set(ctx, data, len); |
1582 | } | 891 | } |
1583 | 892 | ||
1584 | /** | ||
1585 | * Get the specific data of the current active input panel. | ||
1586 | * | ||
1587 | * @param ctx An #Ecore_IMF_Context. | ||
1588 | * @param data The specific data to be got from the input panel | ||
1589 | * @param len The length of data | ||
1590 | * @ingroup Ecore_IMF_Context_Group | ||
1591 | * @since 1.2.0 | ||
1592 | */ | ||
1593 | EAPI void | 893 | EAPI void |
1594 | ecore_imf_context_input_panel_imdata_get(Ecore_IMF_Context *ctx, void *data, int *len) | 894 | ecore_imf_context_input_panel_imdata_get(Ecore_IMF_Context *ctx, void *data, int *len) |
1595 | { | 895 | { |
@@ -1606,17 +906,6 @@ ecore_imf_context_input_panel_imdata_get(Ecore_IMF_Context *ctx, void *data, int | |||
1606 | ctx->klass->input_panel_imdata_get(ctx, data, len); | 906 | ctx->klass->input_panel_imdata_get(ctx, data, len); |
1607 | } | 907 | } |
1608 | 908 | ||
1609 | /** | ||
1610 | * Set the "return" key type. This type is used to set string or icon on the "return" key of the input panel. | ||
1611 | * | ||
1612 | * An input panel displays the string or icon associated with this type | ||
1613 | * | ||
1614 | * @param ctx An #Ecore_IMF_Context. | ||
1615 | * @param return_key_type The type of "return" key on the input panel | ||
1616 | * @note Default type is ECORE_IMF_INPUT_PANEL_RETURN_KEY_TYPE_DEFAULT. | ||
1617 | * @ingroup Ecore_IMF_Context_Group | ||
1618 | * @since 1.2.0 | ||
1619 | */ | ||
1620 | EAPI void | 909 | EAPI void |
1621 | ecore_imf_context_input_panel_return_key_type_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Panel_Return_Key_Type return_key_type) | 910 | ecore_imf_context_input_panel_return_key_type_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Panel_Return_Key_Type return_key_type) |
1622 | { | 911 | { |
@@ -1631,16 +920,6 @@ ecore_imf_context_input_panel_return_key_type_set(Ecore_IMF_Context *ctx, Ecore_ | |||
1631 | if (ctx->klass->input_panel_return_key_type_set) ctx->klass->input_panel_return_key_type_set(ctx, return_key_type); | 920 | if (ctx->klass->input_panel_return_key_type_set) ctx->klass->input_panel_return_key_type_set(ctx, return_key_type); |
1632 | } | 921 | } |
1633 | 922 | ||
1634 | /** | ||
1635 | * Get the "return" key type. | ||
1636 | * | ||
1637 | * @see ecore_imf_context_input_panel_return_key_type_set() for more details | ||
1638 | * | ||
1639 | * @param ctx An #Ecore_IMF_Context. | ||
1640 | * @return The type of "return" key on the input panel | ||
1641 | * @ingroup Ecore_IMF_Context_Group | ||
1642 | * @since 1.2.0 | ||
1643 | */ | ||
1644 | EAPI Ecore_IMF_Input_Panel_Return_Key_Type | 923 | EAPI Ecore_IMF_Input_Panel_Return_Key_Type |
1645 | ecore_imf_context_input_panel_return_key_type_get(Ecore_IMF_Context *ctx) | 924 | ecore_imf_context_input_panel_return_key_type_get(Ecore_IMF_Context *ctx) |
1646 | { | 925 | { |
@@ -1654,14 +933,6 @@ ecore_imf_context_input_panel_return_key_type_get(Ecore_IMF_Context *ctx) | |||
1654 | return ctx->input_panel_return_key_type; | 933 | return ctx->input_panel_return_key_type; |
1655 | } | 934 | } |
1656 | 935 | ||
1657 | /** | ||
1658 | * Set the return key on the input panel to be disabled. | ||
1659 | * | ||
1660 | * @param ctx An #Ecore_IMF_Context. | ||
1661 | * @param disabled The state | ||
1662 | * @ingroup Ecore_IMF_Context_Group | ||
1663 | * @since 1.2.0 | ||
1664 | */ | ||
1665 | EAPI void | 936 | EAPI void |
1666 | ecore_imf_context_input_panel_return_key_disabled_set(Ecore_IMF_Context *ctx, Eina_Bool disabled) | 937 | ecore_imf_context_input_panel_return_key_disabled_set(Ecore_IMF_Context *ctx, Eina_Bool disabled) |
1667 | { | 938 | { |
@@ -1676,14 +947,6 @@ ecore_imf_context_input_panel_return_key_disabled_set(Ecore_IMF_Context *ctx, Ei | |||
1676 | if (ctx->klass->input_panel_return_key_disabled_set) ctx->klass->input_panel_return_key_disabled_set(ctx, disabled); | 947 | if (ctx->klass->input_panel_return_key_disabled_set) ctx->klass->input_panel_return_key_disabled_set(ctx, disabled); |
1677 | } | 948 | } |
1678 | 949 | ||
1679 | /** | ||
1680 | * Get whether the return key on the input panel should be disabled or not. | ||
1681 | * | ||
1682 | * @param ctx An #Ecore_IMF_Context. | ||
1683 | * @return @c EINA_TRUE if it should be disabled. | ||
1684 | * @ingroup Ecore_IMF_Context_Group | ||
1685 | * @since 1.2.0 | ||
1686 | */ | ||
1687 | EAPI Eina_Bool | 950 | EAPI Eina_Bool |
1688 | ecore_imf_context_input_panel_return_key_disabled_get(Ecore_IMF_Context *ctx) | 951 | ecore_imf_context_input_panel_return_key_disabled_get(Ecore_IMF_Context *ctx) |
1689 | { | 952 | { |
@@ -1697,14 +960,6 @@ ecore_imf_context_input_panel_return_key_disabled_get(Ecore_IMF_Context *ctx) | |||
1697 | return ctx->input_panel_return_key_disabled; | 960 | return ctx->input_panel_return_key_disabled; |
1698 | } | 961 | } |
1699 | 962 | ||
1700 | /** | ||
1701 | * Set the caps lock mode on the input panel. | ||
1702 | * | ||
1703 | * @param ctx An #Ecore_IMF_Context. | ||
1704 | * @param mode Turn on caps lock on the input panel if @c EINA_TRUE. | ||
1705 | * @ingroup Ecore_IMF_Context_Group | ||
1706 | * @since 1.2.0 | ||
1707 | */ | ||
1708 | EAPI void | 963 | EAPI void |
1709 | ecore_imf_context_input_panel_caps_lock_mode_set(Ecore_IMF_Context *ctx, Eina_Bool mode) | 964 | ecore_imf_context_input_panel_caps_lock_mode_set(Ecore_IMF_Context *ctx, Eina_Bool mode) |
1710 | { | 965 | { |
@@ -1721,14 +976,6 @@ ecore_imf_context_input_panel_caps_lock_mode_set(Ecore_IMF_Context *ctx, Eina_Bo | |||
1721 | ctx->input_panel_caps_lock_mode = mode; | 976 | ctx->input_panel_caps_lock_mode = mode; |
1722 | } | 977 | } |
1723 | 978 | ||
1724 | /** | ||
1725 | * Get the caps lock mode on the input panel. | ||
1726 | * | ||
1727 | * @param ctx An #Ecore_IMF_Context. | ||
1728 | * @return @c EINA_TRUE if the caps lock is turned on. | ||
1729 | * @ingroup Ecore_IMF_Context_Group | ||
1730 | * @since 1.2.0 | ||
1731 | */ | ||
1732 | EAPI Eina_Bool | 979 | EAPI Eina_Bool |
1733 | ecore_imf_context_input_panel_caps_lock_mode_get(Ecore_IMF_Context *ctx) | 980 | ecore_imf_context_input_panel_caps_lock_mode_get(Ecore_IMF_Context *ctx) |
1734 | { | 981 | { |
@@ -1742,17 +989,6 @@ ecore_imf_context_input_panel_caps_lock_mode_get(Ecore_IMF_Context *ctx) | |||
1742 | return ctx->input_panel_caps_lock_mode; | 989 | return ctx->input_panel_caps_lock_mode; |
1743 | } | 990 | } |
1744 | 991 | ||
1745 | /** | ||
1746 | * Get the position of the current active input panel. | ||
1747 | * | ||
1748 | * @param ctx An #Ecore_IMF_Context. | ||
1749 | * @param x top-left x co-ordinate of the input panel | ||
1750 | * @param y top-left y co-ordinate of the input panel | ||
1751 | * @param w width of the input panel | ||
1752 | * @param h height of the input panel | ||
1753 | * @ingroup Ecore_IMF_Context_Group | ||
1754 | * @since 1.3 | ||
1755 | */ | ||
1756 | EAPI void | 992 | EAPI void |
1757 | ecore_imf_context_input_panel_geometry_get(Ecore_IMF_Context *ctx, int *x, int *y, int *w, int *h) | 993 | ecore_imf_context_input_panel_geometry_get(Ecore_IMF_Context *ctx, int *x, int *y, int *w, int *h) |
1758 | { | 994 | { |
@@ -1767,14 +1003,6 @@ ecore_imf_context_input_panel_geometry_get(Ecore_IMF_Context *ctx, int *x, int * | |||
1767 | ctx->klass->input_panel_geometry_get(ctx, x, y, w, h); | 1003 | ctx->klass->input_panel_geometry_get(ctx, x, y, w, h); |
1768 | } | 1004 | } |
1769 | 1005 | ||
1770 | /** | ||
1771 | * Get state of current active input panel. | ||
1772 | * | ||
1773 | * @param ctx An #Ecore_IMF_Context. | ||
1774 | * @return The state of input panel. | ||
1775 | * @ingroup Ecore_IMF_Context_Group | ||
1776 | * @since 1.3 | ||
1777 | */ | ||
1778 | EAPI Ecore_IMF_Input_Panel_State | 1006 | EAPI Ecore_IMF_Input_Panel_State |
1779 | ecore_imf_context_input_panel_state_get(Ecore_IMF_Context *ctx) | 1007 | ecore_imf_context_input_panel_state_get(Ecore_IMF_Context *ctx) |
1780 | { | 1008 | { |
@@ -1792,18 +1020,6 @@ ecore_imf_context_input_panel_state_get(Ecore_IMF_Context *ctx) | |||
1792 | return state; | 1020 | return state; |
1793 | } | 1021 | } |
1794 | 1022 | ||
1795 | /** | ||
1796 | * Register a callback function which will be called if there is change in input panel state,language,mode etc. | ||
1797 | * In order to deregister the callback function | ||
1798 | * Use @ref ecore_imf_context_input_panel_event_callback_del. | ||
1799 | * | ||
1800 | * @param ctx An #Ecore_IMF_Context | ||
1801 | * @param type event type | ||
1802 | * @param func the callback function | ||
1803 | * @param data application-input panel specific data. | ||
1804 | * @ingroup Ecore_IMF_Context_Group | ||
1805 | * @since 1.3 | ||
1806 | */ | ||
1807 | EAPI void | 1023 | EAPI void |
1808 | ecore_imf_context_input_panel_event_callback_add(Ecore_IMF_Context *ctx, | 1024 | ecore_imf_context_input_panel_event_callback_add(Ecore_IMF_Context *ctx, |
1809 | Ecore_IMF_Input_Panel_Event type, | 1025 | Ecore_IMF_Input_Panel_Event type, |
@@ -1821,15 +1037,6 @@ ecore_imf_context_input_panel_event_callback_add(Ecore_IMF_Context *ctx, | |||
1821 | ctx->klass->input_panel_event_callback_add(ctx, type, func, (void *)data); | 1037 | ctx->klass->input_panel_event_callback_add(ctx, type, func, (void *)data); |
1822 | } | 1038 | } |
1823 | 1039 | ||
1824 | /** | ||
1825 | * Unregister a callback function which will be called if there is change in input panel state, language, mode etc. | ||
1826 | * | ||
1827 | * @param ctx An #Ecore_IMF_Context. | ||
1828 | * @param type An #Ecore_IMF_Input_Panel_Event. | ||
1829 | * @param func the callback function | ||
1830 | * @ingroup Ecore_IMF_Context_Group | ||
1831 | * @since 1.3 | ||
1832 | */ | ||
1833 | EAPI void | 1040 | EAPI void |
1834 | ecore_imf_context_input_panel_event_callback_del(Ecore_IMF_Context *ctx, | 1041 | ecore_imf_context_input_panel_event_callback_del(Ecore_IMF_Context *ctx, |
1835 | Ecore_IMF_Input_Panel_Event type, | 1042 | Ecore_IMF_Input_Panel_Event type, |
@@ -1846,17 +1053,6 @@ ecore_imf_context_input_panel_event_callback_del(Ecore_IMF_Context *ctx, | |||
1846 | ctx->klass->input_panel_event_callback_del(ctx, type, func); | 1053 | ctx->klass->input_panel_event_callback_del(ctx, type, func); |
1847 | } | 1054 | } |
1848 | 1055 | ||
1849 | /** | ||
1850 | * Get the current language locale of the input panel. | ||
1851 | * | ||
1852 | * ex) fr_FR | ||
1853 | * | ||
1854 | * @param ctx An #Ecore_IMF_Context. | ||
1855 | * @param lang Location to store the retrieved language string. The | ||
1856 | * string retrieved must be freed with free(). | ||
1857 | * @ingroup Ecore_IMF_Context_Group | ||
1858 | * @since 1.3 | ||
1859 | */ | ||
1860 | EAPI void | 1056 | EAPI void |
1861 | ecore_imf_context_input_panel_language_locale_get(Ecore_IMF_Context *ctx, char **lang) | 1057 | ecore_imf_context_input_panel_language_locale_get(Ecore_IMF_Context *ctx, char **lang) |
1862 | { | 1058 | { |
@@ -1875,17 +1071,6 @@ ecore_imf_context_input_panel_language_locale_get(Ecore_IMF_Context *ctx, char * | |||
1875 | } | 1071 | } |
1876 | } | 1072 | } |
1877 | 1073 | ||
1878 | /** | ||
1879 | * Get the geometry information of the candidate panel. | ||
1880 | * | ||
1881 | * @param ctx An #Ecore_IMF_Context. | ||
1882 | * @param x top-left x co-ordinate of the candidate panel | ||
1883 | * @param y top-left y co-ordinate of the candidate panel | ||
1884 | * @param w width of the candidate panel | ||
1885 | * @param h height of the candidate panel | ||
1886 | * @ingroup Ecore_IMF_Context_Group | ||
1887 | * @since 1.3 | ||
1888 | */ | ||
1889 | EAPI void | 1074 | EAPI void |
1890 | ecore_imf_context_candidate_panel_geometry_get(Ecore_IMF_Context *ctx, int *x, int *y, int *w, int *h) | 1075 | ecore_imf_context_candidate_panel_geometry_get(Ecore_IMF_Context *ctx, int *x, int *y, int *w, int *h) |
1891 | { | 1076 | { |