[Gtk-sharp-list] Re: Background image

Freon freongrr at gmail.com
Wed Aug 10 17:20:08 EDT 2005


In case anybody cares, the AppPaintable property of the widget the
background is applied to must be set to "true".

On 8/9/05, Freon <freongrr at gmail.com> wrote:
> Hi,
> 
> I'd like to set an image background to a window (and still be able to
> add things inside, that's why using a Gtk.Image is out of question).
> I've made some researches and found out how it was done in classic
> gtk. Yet, it couldn't get it to work with Gtk#.
> 
> I've made a simple test program (attached). The window background
> isn't changed, but when I resize the window, the image flashes before
> the content of the window is redrawn (see attached screenshot).
> I guess Gtk tries to fill my window with the background color. Maybe I
> should set it to transparent somehow?
> 
> To build the test class, copy win.cs and window.png somewhere and run
> mcs win.cs /pkg:gtk-sharp /out:win.exe
> run with
> mono win.exe
> 
> I'm using Mono 1.1.7.1+Gtk# bundle on Windows.
> 
> Thanks in advance :)
> 
> 
>


More information about the Gtk-sharp-list mailing list