Re: Changing focus from one window to another



>
> "Ian King" <king eiffel com> writes:
> >
> > I have a program that has two top level windows, one with a button, one
with
> > a text entry in it.  It is set up so that when I click the button, the
focus
> > is set to the text entry in the other window using
> > gtk_widget_set_focus(entry_widget).  However, the window containing the
> > entry widget doesn't receive the focus.  Am I doing something wrong?
> >
>
> GTK can't change the focus between toplevel windows, only the window
> manager can do that.
>
> (You can try calling XSetInputFocus() as a low-level hack, but
> if the user is using focus-follows-mouse or something it won't work
> out very well.)
>
> Havoc

Does that mean the gtk_widget_set_focus (window) will never work?  If so,
then an autocomplete window that comes up when you are typing code would
then surely be impossible to implement, or is there another way?

Thanks

Ian King






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]