parent
d1a1b62fa8
commit
fbdfa54f82
|
@ -275,7 +275,7 @@ struct _Ecore_IMF_Context_Class
|
|||
void (*cursor_position_set) (Ecore_IMF_Context *ctx, int cursor_pos);
|
||||
void (*use_preedit_set) (Ecore_IMF_Context *ctx, int use_preedit);
|
||||
void (*input_mode_set) (Ecore_IMF_Context *ctx, Ecore_IMF_Input_Mode input_mode);
|
||||
int (*filter_event) (Ecore_IMF_Context *ctx, Ecore_IMF_Event_Type type, Ecore_IMF_Event *event);
|
||||
Eina_Bool (*filter_event) (Ecore_IMF_Context *ctx, Ecore_IMF_Event_Type type, Ecore_IMF_Event *event);
|
||||
};
|
||||
|
||||
struct _Ecore_IMF_Context_Info
|
||||
|
@ -311,16 +311,16 @@ EAPI void ecore_imf_context_focus_out(Ecore_IMF_Context
|
|||
EAPI void ecore_imf_context_reset(Ecore_IMF_Context *ctx);
|
||||
EAPI void ecore_imf_context_cursor_position_set(Ecore_IMF_Context *ctx, int cursor_pos);
|
||||
EAPI void ecore_imf_context_use_preedit_set(Ecore_IMF_Context *ctx, int use_preedit);
|
||||
EAPI void ecore_imf_context_retrieve_surrounding_callback_set(Ecore_IMF_Context *ctx, int (*func)(void *data, Ecore_IMF_Context *ctx, char **text, int *cursor_pos), const void *data);
|
||||
EAPI void 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);
|
||||
EAPI void ecore_imf_context_input_mode_set(Ecore_IMF_Context *ctx, Ecore_IMF_Input_Mode input_mode);
|
||||
EAPI Ecore_IMF_Input_Mode ecore_imf_context_input_mode_get(Ecore_IMF_Context *ctx);
|
||||
EAPI int ecore_imf_context_filter_event(Ecore_IMF_Context *ctx, Ecore_IMF_Event_Type type, Ecore_IMF_Event *event);
|
||||
EAPI Eina_Bool ecore_imf_context_filter_event(Ecore_IMF_Context *ctx, Ecore_IMF_Event_Type type, Ecore_IMF_Event *event);
|
||||
|
||||
/* plugin specific functions */
|
||||
EAPI Ecore_IMF_Context *ecore_imf_context_new(const Ecore_IMF_Context_Class *ctxc);
|
||||
EAPI void ecore_imf_context_data_set(Ecore_IMF_Context *ctx, void *data);
|
||||
EAPI void *ecore_imf_context_data_get(Ecore_IMF_Context *ctx);
|
||||
EAPI int ecore_imf_context_surrounding_get(Ecore_IMF_Context *ctx, char **text, int *cursor_pos);
|
||||
EAPI Eina_Bool ecore_imf_context_surrounding_get(Ecore_IMF_Context *ctx, char **text, int *cursor_pos);
|
||||
EAPI void ecore_imf_context_preedit_start_event_add(Ecore_IMF_Context *ctx);
|
||||
EAPI void ecore_imf_context_preedit_end_event_add(Ecore_IMF_Context *ctx);
|
||||
EAPI void ecore_imf_context_preedit_changed_event_add(Ecore_IMF_Context *ctx);
|
||||
|
|
|
@ -446,7 +446,7 @@ ecore_imf_context_use_preedit_set(Ecore_IMF_Context *ctx, int use_preedit)
|
|||
* @ingroup Ecore_IMF_Context_Group
|
||||
*/
|
||||
EAPI void
|
||||
ecore_imf_context_retrieve_surrounding_callback_set(Ecore_IMF_Context *ctx, int (*func)(void *data, Ecore_IMF_Context *ctx, char **text, int *cursor_pos), const void *data)
|
||||
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)
|
||||
{
|
||||
if (!ECORE_MAGIC_CHECK(ctx, ECORE_MAGIC_CONTEXT))
|
||||
{
|
||||
|
@ -506,30 +506,30 @@ ecore_imf_context_input_mode_get(Ecore_IMF_Context *ctx)
|
|||
|
||||
/**
|
||||
* Allow an Ecore Input Context to internally handle an event.
|
||||
* If this function returns 1, then no further processing
|
||||
* If this function returns EINA_TRUE, then no further processing
|
||||
* should be done for this event.
|
||||
*
|
||||
* Input methods must be able to accept all types of events (simply
|
||||
* returning 0 if the event was not handled), but there is no
|
||||
* returning EINA_FALSE if the event was not handled), but there is no
|
||||
* obligation of any events to be submitted to this function.
|
||||
*
|
||||
* @param ctx An #Ecore_IMF_Context.
|
||||
* @param type The type of event defined by #Ecore_IMF_Event_Type.
|
||||
* @param event The event itself.
|
||||
* @return 1 if the event was handled; otherwise 0.
|
||||
* @return EINA_TRUE if the event was handled; otherwise .
|
||||
* @ingroup Ecore_IMF_Context_Group
|
||||
*/
|
||||
EAPI int
|
||||
EAPI Eina_Bool
|
||||
ecore_imf_context_filter_event(Ecore_IMF_Context *ctx, Ecore_IMF_Event_Type type, Ecore_IMF_Event *event)
|
||||
{
|
||||
if (!ECORE_MAGIC_CHECK(ctx, ECORE_MAGIC_CONTEXT))
|
||||
{
|
||||
ECORE_MAGIC_FAIL(ctx, ECORE_MAGIC_CONTEXT,
|
||||
"ecore_imf_context_filter_event");
|
||||
return 0;
|
||||
return EINA_FALSE;
|
||||
}
|
||||
if (ctx->klass->filter_event) return ctx->klass->filter_event(ctx, type, event);
|
||||
return 0;
|
||||
return EINA_FALSE;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -622,23 +622,23 @@ EAPI void *ecore_imf_context_data_get(Ecore_IMF_Context *ctx)
|
|||
* @param ctx An #Ecore_IMF_Context.
|
||||
* @param text Location to store a UTF-8 encoded string of text
|
||||
* holding context around the insertion point.
|
||||
* If the function returns 1, then you must free
|
||||
* If the function returns Eina_True, then you must free
|
||||
* the result stored in this location with free().
|
||||
* @param cursor_pos Location to store the position in characters of
|
||||
* the insertion cursor within @text.
|
||||
* @return 1 if surrounding text was provided; otherwise 0.
|
||||
* @return EINA_TRUE if surrounding text was provided; otherwise EINA_FALSE.
|
||||
* @ingroup Ecore_IMF_Context_Module_Group
|
||||
*/
|
||||
EAPI int
|
||||
EAPI Eina_Bool
|
||||
ecore_imf_context_surrounding_get(Ecore_IMF_Context *ctx, char **text, int *cursor_pos)
|
||||
{
|
||||
int result = 0;
|
||||
int result = EINA_FALSE;
|
||||
|
||||
if (!ECORE_MAGIC_CHECK(ctx, ECORE_MAGIC_CONTEXT))
|
||||
{
|
||||
ECORE_MAGIC_FAIL(ctx, ECORE_MAGIC_CONTEXT,
|
||||
"ecore_imf_context_surrounding_get");
|
||||
return 0;
|
||||
return EINA_FALSE;
|
||||
}
|
||||
|
||||
if (ctx->retrieve_surrounding_func)
|
||||
|
|
|
@ -43,7 +43,7 @@ struct _Ecore_IMF_Context
|
|||
const Ecore_IMF_Context_Class *klass;
|
||||
void *data;
|
||||
int input_mode;
|
||||
int (*retrieve_surrounding_func)(void *data, Ecore_IMF_Context *ctx, char **text, int *cursor_pos);
|
||||
Eina_Bool (*retrieve_surrounding_func)(void *data, Ecore_IMF_Context *ctx, char **text, int *cursor_pos);
|
||||
void *retrieve_surrounding_data;
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue