It's because EventBox is a widget which has its own
gdkwindow so it can be rendered above its parent
gdkwindow. If you try to set the EventBox to has no
visible window then you will find that the window
background cover everything again.

For those no window widgets, child widgets on the top
will be always rendered first and the bottom most
parent window widget last.(when try to catch expose
event and draw your own)

I don't know how to reverse the rendering order
though.

Does anyone know how?

Regards,

Kev


--- "Boncek, John" <[EMAIL PROTECTED]> wrote:

> I had the same problem a while back and asked here
> about it.  I was told
> to put the button in an EventBox, which caused it to
> start working.  I
> never received an explanation of why it didn't work
> the first way or why
> it does work with the EventBox.
> 
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On
> Behalf Of Kevin Brooks
> Sent: Sunday, October 02, 2005 1:32 AM
> To: gtk-app-devel-list@gnome.org
> Subject: gtk rendering order
> 
> Hello,
> 
> I had a gtk window and a gtk button was put on the
> window. But the button was totally covered by the
> window background when the window background was set
> to solid color or image.
> 
> Does anyone know how to solve this problem?
> 
> I also want to know the rendering order of gtk
> widgets.
> 
> The gtk window was supposed to render its own
> background first and then the child widgets resided
> on
> it so that those child widgets would not be covered
> by
> the window's background.
> 
> Did I miss something?
> 
> Thanks.
> 
> Kev
> 
> 
> 
>               
> __________________________________ 
> Yahoo! Mail - PC Magazine Editors' Choice 2005 
> http://mail.yahoo.com
> _______________________________________________
> gtk-app-devel-list mailing list
> gtk-app-devel-list@gnome.org
>
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
> 



                
__________________________________ 
Yahoo! Mail - PC Magazine Editors' Choice 2005 
http://mail.yahoo.com
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Reply via email to