This is an automatically generated mail from the syncmail system. Do not reply
directly to this email. Further discussion should take place on the hackers
list: [email protected]
Update of /cvsroot/perl-win32-gui/Win32-GUI
In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv25161
Modified Files:
CHANGELOG DC.xs Makefile.PL
Log Message:
Added methods GradientFillTriangle and GradientFillRectangle to DC.xs
Index: CHANGELOG
===================================================================
RCS file: /cvsroot/perl-win32-gui/Win32-GUI/CHANGELOG,v
retrieving revision 1.147
retrieving revision 1.148
diff -C2 -d -r1.147 -r1.148
*** CHANGELOG 20 Feb 2010 12:22:27 -0000 1.147
--- CHANGELOG 22 Feb 2010 16:24:32 -0000 1.148
***************
*** 6,9 ****
--- 6,14 ----
Win32-GUI ChangeLog
===================
+ + [Jeremy White] : 22 February 2010 - Added methods to DC.xs
+ - DC.xs - added GradientFillTriangle and GradientFillRectangle
+ - Makefile.PL - added lib lmsimg32
+ - GradientFill.pl - added sample showing how to use new methods
+
+ [Jeremy White] : 20 February 2010 - Bug fix
- GUI_Helpers.cpp fix of bug #1941264 causing crash with menus
Index: Makefile.PL
===================================================================
RCS file: /cvsroot/perl-win32-gui/Win32-GUI/Makefile.PL,v
retrieving revision 1.31
retrieving revision 1.32
diff -C2 -d -r1.31 -r1.32
*** Makefile.PL 8 Feb 2008 18:02:05 -0000 1.31
--- Makefile.PL 22 Feb 2010 16:24:32 -0000 1.32
***************
*** 229,233 ****
NAME => 'Win32::GUI',
VERSION_FROM => 'GUI.pm',
! LIBS => [':nosearch -lcomctl32 -lcomdlg32 -lshell32 -lgdi32
-luser32 -lversion'],
PREREQ_PM => {
'Test::More' => 0,
--- 229,233 ----
NAME => 'Win32::GUI',
VERSION_FROM => 'GUI.pm',
! LIBS => [':nosearch -lcomctl32 -lcomdlg32 -lshell32 -lgdi32
-luser32 -lversion -lmsimg32'],
PREREQ_PM => {
'Test::More' => 0,
***************
*** 270,274 ****
if ($main::BUILDENV eq "cygwin") {
! $MakefileArgs{'LIBS'} = ['-L/usr/lib/w32api -lcomctl32 -lcomdlg32 -lshell32
-lgdi32 -luser32 -lversion'];
$MakefileArgs{'DEFINE'} = '-UWIN32';
$MakefileArgs{'MYEXTLIB'} = './libcyg.a';
--- 270,274 ----
if ($main::BUILDENV eq "cygwin") {
! $MakefileArgs{'LIBS'} = ['-L/usr/lib/w32api -lcomctl32 -lcomdlg32 -lshell32
-lgdi32 -luser32 -lversion -lmsimg32'];
$MakefileArgs{'DEFINE'} = '-UWIN32';
$MakefileArgs{'MYEXTLIB'} = './libcyg.a';
Index: DC.xs
===================================================================
RCS file: /cvsroot/perl-win32-gui/Win32-GUI/DC.xs,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -d -r1.18 -r1.19
*** DC.xs 15 Jul 2007 18:39:51 -0000 1.18
--- DC.xs 22 Feb 2010 16:24:32 -0000 1.19
***************
*** 1260,1264 ****
--- 1260,1358 ----
OUTPUT:
RETVAL
+
+
###########################################################################
+ # (@)METHOD:GradientFillTriangle(X0, Y0, COLOR0, X1, Y1, COLOR1, X2, Y2,
COLOR2)
+ # Fills the area of the triangle using smooth shading from color0 at point
+ # zero through to the other points.
+ #
+
+ BOOL
+ GradientFillTriangle(handle, x0, y0, color0, x1, y1, color1, x2, y2, color2)
+ HDC handle
+ int x0
+ int y0
+ COLORREF color0
+ int x1
+ int y1
+ COLORREF color1
+ int x2
+ int y2
+ COLORREF color2
+ CODE:
+ TRIVERTEX vertex[3];
+ vertex[0].x = x0;
+ vertex[0].y = y0;
+ vertex[0].Red = (COLOR16) (GetRValue(color0) << 8);;
+ vertex[0].Green = (COLOR16) (GetGValue(color0) << 8);;
+ vertex[0].Blue = (COLOR16) (GetBValue(color0) << 8);;
+ vertex[0].Alpha = 0x0000;
+
+ vertex[1].x = x1;
+ vertex[1].y = y1;
+ vertex[1].Red = (COLOR16) (GetRValue(color1) << 8);;
+ vertex[1].Green = (COLOR16) (GetGValue(color1) << 8);;
+ vertex[1].Blue = (COLOR16) (GetBValue(color1) << 8);;
+ vertex[1].Alpha = 0x0000;
+
+ vertex[2].x = x2;
+ vertex[2].y = y2;
+ vertex[2].Red = (COLOR16) (GetRValue(color2) << 8);;
+ vertex[2].Green = (COLOR16) (GetGValue(color2) << 8);;
+ vertex[2].Blue = (COLOR16) (GetBValue(color2) << 8);;
+ vertex[2].Alpha = 0x0000;
+
+ GRADIENT_TRIANGLE gTriangle;
+ gTriangle.Vertex1 = 0;
+ gTriangle.Vertex2 = 1;
+ gTriangle.Vertex3 = 2;
+
+ RETVAL = GradientFill(handle, vertex, 3, &gTriangle, 1,
GRADIENT_FILL_TRIANGLE);
+ OUTPUT:
+ RETVAL
+
+
###########################################################################
+ # (@)METHOD:GradientFillRectangle(X0, Y0, COLOR0, X1, Y1, COLOR1, X2, Y2,
COLOR2,DIRECTION)
+ # Fills the area of the Rectangle using smooth shading from color0 to
color1.
+ # As a default the smoothing will be horizontal, to specify vertical
smoothing pass any
+ # value as the final parameter.
+ #
+ BOOL
+ GradientFillRectangle(handle, x0, y0, x1, y1,
color0,color1,direction=GRADIENT_FILL_RECT_H)
+ HDC handle
+ int x0
+ int y0
+ int x1
+ int y1
+ COLORREF color0
+ COLORREF color1
+ int direction
+ CODE:
+ if (direction!=GRADIENT_FILL_RECT_H) {
+ direction = GRADIENT_FILL_RECT_V;
+ }
+ TRIVERTEX vertex[2] ;
+ vertex[0].x = x0;
+ vertex[0].y = y0;
+ vertex[0].Red = (COLOR16) (GetRValue(color0) << 8);
+ vertex[0].Green = (COLOR16) (GetGValue(color0) << 8);
+ vertex[0].Blue = (COLOR16) (GetBValue(color0) << 8);
+ vertex[0].Alpha = 0x0000;
+
+ vertex[1].x = x1;
+ vertex[1].y = x1;
+ vertex[1].Red = (COLOR16) (GetRValue(color1) << 8);
+ vertex[1].Green = (COLOR16) (GetGValue(color1) << 8);
+ vertex[1].Blue = (COLOR16) (GetBValue(color1) << 8);
+ vertex[1].Alpha = 0x0000;
+
+ GRADIENT_RECT gRect;
+ gRect.UpperLeft = 0;
+ gRect.LowerRight = 1;
+
+ RETVAL = GradientFill(handle, vertex, 2, &gRect, 1, direction);
+ OUTPUT:
+ RETVAL
+
###########################################################################
# (@)METHOD:GetPixel(X, Y)
------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Perl-win32-gui-cvscommit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-cvscommit
http://perl-win32-gui.sourceforge.net/