I'm having a problem with the Emacs X code. Specifically, on the
Maemo platform, standard GTK widgets that accept text entry will get a
pop-up keyboard. With Emacs, however, I am not able to get that
keyboard with Emacs buffer windows. I was pointed to some
documentation, which suggests that either I need to use standard GTK
widgets or manually call the functions Window::AcquireKeyboardInput()
and Window::ReleaseKeyboardInput(), plus handle some X events.
I'm using this post as reference:
http://www.gossamer-threads.com/lists/maemo/developers/13600?search_string=input;#13600
Plus these snippets:
https://garage.maemo.org/snippet/browse.php?by=lang&lang=2
You can get more information about input methods for Maemo here:
http://maemo.org/platform/docs/tutorials/Maemo_tutorial.html#input
You can install the Maemo SDK easily on a Debian system:
http://maemo.org/platform/docs/howtos/Maemo_tutorial_bora.html
My questions:
1) are buffer windows text-input-capable GTK widgets when --with-gtk
is used? If yes, something is going wrong in the setup phase, and
they don't accept keyboard input when they should.
2) Assuming "no" to (1), if I have to use the manual acquire/release
keyboard functions, where would I make that change? I couldn't find a
gain/lose focus event in the C code. Also, where would I handle the X
events? I need to handle them to tell Maemo that the keyboard is safe
to bring up.
I think I can use src/window.c:select-window() to acquire the
keyboard. X Events seem to be processed in
src/xterm.c:XTread_socket(). My inexperience with GTK and X, however,
is making it hard for me to understand what's going on, and I would
like some help from people that understand the Emacs X internals better.