Hi:

>> It's not a problem of being early: I even tried to put a 1-second timer
>> to call to grab_focus(), but didn't work.
>>
>> In fact, the first time I create the window it works fine, but seems to
>> fail when I hide it and show it again.
> So it may be related to the window manager?

I suspect that. In fact, I think I'm going to just save the internal
widget and create a new window every time I press the hotkey.

It is a guake clone written in Vala, using Gtk3. I'm using libkeybinder
to detect a global key. It is the same library used by guake and
terminator, but they use Gtk2. I also implemented a guake mode in
terminator, but had to do some tricks to ensure that the window received
the focus on those same cases when my vala code fails (I use a
show-hide-show scheme, that seems to guarantee that the window receives
the focus; but it seems to work only with gtk2, but not gtk3).

> Is it Linux with Gnome3 shell? Gnome 3.20?

That's right. I'm using debian sid.

> May other programs steal the focus?

No, AFAIK.

> Do other tools work fine? When you hide and show gedit, will it have
> the focus?
>

Yes, everything works fine.

-- 
Nos leemos
                         RASTER    (Linux user #228804)
ras...@rastersoft.com              http://www.rastersoft.com

_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Reply via email to