Re: commit -- fixed #522


Subject: Re: commit -- fixed #522
From: Daniel Weber (dweber1@austin.rr.com)
Date: Wed Feb 09 2000 - 00:31:21 CST


sterwill@abisource.com wrote:

> Daniel Weber wrote:
>
> > I'd just convinced myself something deep and strange was going on - Ill
> > be glad to be corrected....
>
> Something deep and strange is going on. :) I haven't traced the
> "deep and strange" path entirely, but the drop-down boxes are taking
> focus when they're clicked on (or something from them is selected),
> and they never relinquish focus (save for a "tab" key pointed at them).
> The problem is that when AbiWord's frame gets a key press, it handles it
> (through the edit methods), and then passes on the key if and only if
> it's an ALT key (so that GTK can handle all those menu hot-keys, like
> "Alt-F" for File menu, etc.).
>
>

I've been mulling it a little more and haven't been able to come up with a solution. One possibility is to attach the signal handler for "changed" in the combo boxes in the "in-focus" event and then detach
it in the "out-focus". This solves most issues, but won't change the fact that the combo box will still appear "focused". This will perhaps involve creating a structure for the user_data that holds the
signal handler id and the wd pointer. These structures would have to be g_new'd and deleted, as well. I'm not sure if this approach is correct, given the large amount of code I haven't found yet :-)

The big issue is that there doesn't appear to be any gtk functions to ditch the focus. It get's even stranger for me when I put checks in for the focus, and the combo boxes didn't believe they had it!

I'll spend some time digging around Havoc Pennington's book and see if anything jumps out at me.



This archive was generated by hypermail 2b25 : Tue Feb 08 2000 - 23:29:20 CST