Re: Transparent background?



John McDermott said:

I've done Gtk programming in C and in Perl, but I don't know how to pack
one widget on top of another, nor how to create the transparent
background in the top window.  Any help will be appreciated.

as for getting one on top of the other --- a Fixed layout container (as in
GtkFixed) may help you there.  it should know how to get the GdkWindows of the
various widgets to overlap, provided you give it the proper stacking order and
all that business.  you'll have to override/provide handlers for size_allocate
and the like to ensure that the widgets are always placed where you want them.


i always thought that gdk_window_shape_combine_mask() was only for toplevel
windows (the XShape extension), but that may not be true, since there also
exists (in Gtk2 1.011, at least) gtk_widget_shape_combine_mask().  YMMV.

on the other hand, labels are an example of a windowless widget which draws on
its parent.  this may be easier than trying to make a shaped GdkWindow if you
don't need to be able to drag that window around or anything.

is an EventBox transparent?

-- 
muppet <scott at asofyet dot org>



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