[maemo-developers] Word completion in Fremantle

From: Cornelius Hald hald at icandy.de
Date: Sat Nov 7 21:12:42 EET 2009
> P.S. Maybe I could use a signal emission hook to intercept the
> "preedit-changed" signal. Not sure, but it could work. I'll give it a
> try...

I've tried that now, but still no luck. My code looks like this:

static gboolean
on_preedit_changed (GSignalInvocationHint *ihint,
                    guint n_param_values,
                    const GValue *param_values,
                    gpointer data)
    g_printerr("### Preedit parameter count: %i\n", n_param_values);

guint sid = g_signal_lookup("preedit-changed", GTK_TYPE_IM_CONTEXT);
g_signal_add_emission_hook(sid, 0, on_preedit_changed, textview, NULL);

on_preedit_changed() is called only one time during startup and with a
bogus parameter. It might be that I should use HILDON_TYPE_IM_CONTEXT as
type, but that's not possible, because the header file
hildon-im-context.h is missing from the SDK. I don't know why and I
don't know whether or not that's the problem. Maybe I'm doing something
else wrong?!

Anyways, more help would really be appreciated!


More information about the maemo-developers mailing list