Changelog: Implemented GetDCPenColor and GetDCBrushColor. Vincent
Index: objects/dc.c =================================================================== RCS file: /home/wine/wine/objects/dc.c,v retrieving revision 1.102 diff -u -r1.102 dc.c --- objects/dc.c 5 Nov 2003 01:43:57 -0000 1.102 +++ objects/dc.c 5 Nov 2003 02:39:49 -0000 @@ -1459,6 +1459,29 @@ } /*********************************************************************** + * GetDCBrushColor (GDI32.@) + * + * Retrieves the current brush color for the specified device + * context (DC). + * + */ +COLORREF WINAPI GetDCBrushColor(HDC hdc) +{ + DC *dc; + COLORREF dcBrushColor = CLR_INVALID; + + TRACE("hdc(%p)\n", hdc); + + dc = DC_GetDCPtr( hdc ); + if (dc) + { + dcBrushColor = dc->dcBrushColor; + } + + return dcBrushColor; +} + +/*********************************************************************** * SetDCBrushColor (GDI32.@) * * Sets the current device context (DC) brush color to the specified @@ -1496,6 +1519,29 @@ } return oldClr; +} + +/*********************************************************************** + * GetDCPenColor (GDI32.@) + * + * Retrieves the current pen color for the specified device + * context (DC). + * + */ +COLORREF WINAPI GetDCPenColor(HDC hdc) +{ + DC *dc; + COLORREF dcPenColor = CLR_INVALID; + + TRACE("hdc(%p)\n", hdc); + + dc = DC_GetDCPtr( hdc ); + if (dc) + { + dcPenColor = dc->dcPenColor; + } + + return dcPenColor; } /*********************************************************************** Index: dlls/gdi/gdi32.spec =================================================================== RCS file: /home/wine/wine/dlls/gdi/gdi32.spec,v retrieving revision 1.31 diff -u -r1.31 gdi32.spec --- dlls/gdi/gdi32.spec 5 Nov 2003 01:43:57 -0000 1.31 +++ dlls/gdi/gdi32.spec 5 Nov 2003 02:40:21 -0000 @@ -198,7 +198,9 @@ @ stdcall GetColorSpace(long) @ stdcall GetCurrentObject(long long) @ stdcall GetCurrentPositionEx(long ptr) +@ stdcall GetDCBrushColor(long) @ stdcall GetDCOrgEx(long ptr) +@ stdcall GetDCPenColor(long) @ stdcall GetDIBColorTable(long long long ptr) @ stdcall GetDIBits(long long long long ptr ptr long) @ stdcall GetDeviceCaps(long long) @@ -412,8 +414,6 @@ @ extern pfnRealizePalette @ extern pfnSelectPalette @ stub pstackConnect -@ stub GetDCBrushColor #stdcall (long) -@ stub GetDCPenColor #stdcall (long) ################################################################ # Wine extensions: Win16 functions that are needed by other dlls