> Hello, perl-win32-gui-users, 
> 
> Anybody knows if it's possible  to display a background bitmap image  in a

> MDIFrame? If it's possible, I will appreciate a short example .
> 
> I'm using de MDI.pl example (Win32-GUI examples) for test. 
> 
> Thanks!

One possibility is to add a Label with a bitmap to the MDIFrame:

 $Window = new Win32::GUI::MDIFrame (
     ...
     -onResize => sub { $Window->{BGImg}->Resize($Window->ScaleWidth(),
                        $Window->ScaleHeight())
                      },
 ) or die "Window";

 my $bgimg = new Win32::GUI::Label (
     -parent  => $Window,
     -name    => 'BGImg',
     -bitmap  => my $bitmap = new Win32::GUI::BitmapInline(q( ... )),
 ) or die "BGImg";

The problem is, that you will have to catch quite a lot of messages/events
because the repainting of the Label and sometimes even the MDIChilds isn't
done in the way one would expect and so you'll have to take care of it on
your own.

Regards,
Uwe.

Reply via email to