Key focus and widgets without GdkWindow



I guess this is a very basic question, bit I still don't get it :/

I've understood that only widgets with a GdkWindow of their own can grab
focus. What is the reason for this? Or have I completely misunderstood
something here?

When I look in the code, it seems Gdk passes all key press events to a
GtkWindow widget, which in turn dispatches that event to its' focus widget.
I don't see the connection with GdkWindows here.

I'm about to write a widget which really doesn't need a window of its own,
but it needs to be able to grab focus. 

Regards,
Dag Helstad



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