Here's a new version. You can give it any bitmap (see line 18, and change the bmp file to any bmp file that you'd like.
The default transparent color is white, but you can change it on line 52. I just got this working, so there are some issues. You still can't drag the app when skinned. I had to do some manual adjustments on the alignment of the skin, and I only have W2K to test with, so I don't know how it will look on XP. It also takes a second to create the skin each time that you switch to skin mode. I've included 1 new example bitmaps. (Note that skin3.bmp has white borders around the edges. It was how I created the images in PSP. It's actually a fade to white that I didn't mean to put there.) Let me know if I'm on the right track! Would it be worth creating a Win32::GUI::Skin module? Brian Millham This message traveled at least 44,000 miles to reach you! Creator of the DW6000 Monitor http://www.millham.net/dw6000 [EMAIL PROTECTED] -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Plum, Jason Sent: Monday, February 27, 2006 10:12 AM To: perl-win32-gui-users@lists.sourceforge.net Subject: RE: [perl-win32-gui-users] Skins in Win32-GUI From the examples I have sen on non-perl sites, the pixel lineup issue is actually a pre XP vs XP issue. I'll try to find it again to see what we can do to make the alignments. Something about the applications' theming in XP. The adjustment is soemthing in the order of 2-4 pixels. Jason P. -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brian Millham Sent: Monday, February 27, 2006 12:48 AM To: perl-win32-gui-users@lists.sourceforge.net Subject: RE: [perl-win32-gui-users] Skins in Win32-GUI Here's a much improved version. The 2 errors still show when switching to skin mode. You can you switch between window and skin mode by right clicking the mouse. I need to add the code to move the window when in skin mode. The skin isn't lined up right yet. It's off by a few pixels at the top. I've also found some sample code (in C++) to read a bitmap, and create the regions from the bitmap. I'll work on that next. Brian Millham This message traveled at least 44,000 miles to reach you! Creator of the DW6000 Monitor http://www.millham.net/dw6000 [EMAIL PROTECTED] -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Brian Millham Sent: Sunday, February 26, 2006 7:22 PM To: perl-win32-gui-users@lists.sourceforge.net Subject: [perl-win32-gui-users] Skins in Win32-GUI Hi all, I've been playing with this a little bit this afternoon, and have a very simple, incomplete app that is sort-of skinned. The skin bitmap is not properly positioned (I'm not sure how to move it yet, it needs to cover the complete window, including the title bar) and there are 2 errors when you start the program complaining about the CreateEllipticRgn sub. Oh, and there's no way to close it, you have to Ctrl-C it from the command line. To run this, just save the script and the bmp file in the same directory. Over all, this shows that it's not to difficult to create a skinned app with perl and Win32::GUI. I hope that this helps someone, and I'll send an updated version once I figure out the glitches. Brian Millham This message traveled at least 44,000 miles to reach you! Creator of the DW6000 Monitor http://www.millham.net/dw6000 [EMAIL PROTECTED] --- avast! Antivirus: Outbound message clean. Virus Database (VPS): 0608-1, 02/23/2006 Tested on: 2/26/2006 7:21:50 PM avast! is copyright (c) 2000-2003 ALWIL Software. http://www.avast.com --- avast! Antivirus: Inbound message clean. Virus Database (VPS): 0608-1, 02/23/2006 Tested on: 2/26/2006 8:00:43 PM avast! is copyright (c) 2000-2003 ALWIL Software. http://www.avast.com --- avast! Antivirus: Outbound message clean. Virus Database (VPS): 0608-1, 02/23/2006 Tested on: 2/27/2006 12:47:39 AM avast! is copyright (c) 2000-2003 ALWIL Software. http://www.avast.com ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=k&kid0944&bid$1720&dat1642 _______________________________________________ Perl-Win32-GUI-Users mailing list Perl-Win32-GUI-Users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users http://perl-win32-gui.sourceforge.net/ --- avast! Antivirus: Inbound message clean. Virus Database (VPS): 0609-0, 02/27/2006 Tested on: 2/27/2006 10:37:21 AM avast! is copyright (c) 2000-2003 ALWIL Software. http://www.avast.com --- avast! Antivirus: Outbound message clean. Virus Database (VPS): 0609-1, 03/01/2006 Tested on: 3/1/2006 10:59:30 PM avast! is copyright (c) 2000-2003 ALWIL Software. http://www.avast.com --- avast! Antivirus: Outbound message clean. Virus Database (VPS): 0609-1, 03/01/2006 Tested on: 3/1/2006 11:15:15 PM avast! is copyright (c) 2000-2003 ALWIL Software. http://www.avast.com
skin.pl
Description: Binary data
<<attachment: skin3.bmp>>