[maemo-developers] onscreen keyboard on N900

From: ds ds2 at physik.de
Date: Fri Jan 8 17:48:12 EET 2010
I had some code, which brought up the onscreen keyboard on N770-N810.

It seems to bring up an onscreen keyboard on N900 too (I do not have,
but I received a bug report).

The problem is:

When I press toolbar button to pop up software keyboard, keyboard's
input string is non-empty - it always contains 'flash' word, and I have
to manually relete it before typing what I need. Very inconvenient :(

I could not find porting instructions for onscreen keyboard. But it
seems to be handy in some cases, otherwize I would not have received a
bug report:-)

Any idea, what I might do to fix?

Thanks a lot


The code simulates a key press in the widget, as far as I remember. It
was taken from some tipps from the maemo team some 4 years ago I think. 

    // send enter key press and release to VNC widget
      GdkEventKey eventKey;
      GdkKeymapKey *keys;
      gint n_keys;
&keys, &n_keys);
      eventKey.type = GDK_KEY_PRESS;
      eventKey.hardware_keycode = keys[0].keycode;
      eventKey.keyval = GDK_Return;
      eventKey.state = 0;
      eventKey.window = (GTK_WIDGET(mainview->vnc))->window;
      eventKey.length = 1;
      eventKey.string = "\r";
      eventKey.send_event = 0;
      eventKey.group = 0;


      vnc_viewer_key_press_event(GTK_WIDGET(mainview->vnc), &eventKey);

More information about the maemo-developers mailing list