[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Emacs X/GTK code trouble with Maemo (was: porting and packaging Emacs to
Emacs X/GTK code trouble with Maemo (was: porting and packaging Emacs to a new platform: Maemo)
Mon, 22 Jan 2007 16:43:37 -0500
Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.92 (gnu/linux)
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:
Plus these snippets:
You can get more information about input methods for Maemo here:
You can install the Maemo SDK easily on a Debian system:
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.