Hi,

I was assuming that there was a way to change the background color of the window during runtime? As for using a class, I had already tried that:

use Win32::GUI;
use strict;
my $WC = new Win32::GUI::Class(
   -name => "Background",
  # -style => 0,
   -background => [208,187,255],
);

my $win = new Win32::GUI::Window (
   -pos         => [100, 100],
   -size        => [550, 235],
   -name        => "Window",
   -text        => "testing",
   -class       => $WC,
);

$win->Show();

Win32::GUI::Dialog();

No joy - but running the FetchURL.pl example in loft did bring up a window with a different window (then crashed on exit - that DC issue).

Cheers,

jez.
----- Original Message ----- From: "Johan Lindstrom" <[EMAIL PROTECTED]>
To: "guihackers" <perl-win32-gui-hackers@lists.sourceforge.net>
Sent: Tuesday, October 26, 2004 4:40 PM
Subject: Re: [perl-win32-gui-hackers] Setting the background of a window - broken?


At 17:26 2004-10-26, Jez White wrote:
For the life of me I can't seem to be able to set the background color of a window - I know you could in previous versions.

Surely -background => [255,0,0] should work just like with controls?

I don't think that ever worked, but I'm not sure. You need to create a Win32::GUI::Class and assign a background color to it and assign the class to the window.

There's a TGL demo program that does this.


/J

-------- ------ ---- --- -- --  --  -     -     -        -          -
Johan Lindström    Sourcerer @ Boss Casinos   johanl AT DarSerMan.com

Latest bookmark: "TCP Connection Passing"
http://tcpcp.sourceforge.net/
dmoz: /Computers/Programming/Languages/JavaScript/ 12



-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
Perl-Win32-GUI-Hackers mailing list
Perl-Win32-GUI-Hackers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-hackers


Reply via email to