[Bug 7757] New: GetDeviceCaps(NUMCOLORS) returns wrong value: -1

Wine Bugs wine-bugs at winehq.org
Thu Mar 15 19:10:20 CDT 2007


http://bugs.winehq.org/show_bug.cgi?id=7757

           Summary: GetDeviceCaps(NUMCOLORS) returns wrong value: -1
           Product: Wine
           Version: unspecified
          Platform: Other
        OS/Version: other
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: wine-x11driver
        AssignedTo: wine-bugs at winehq.org
        ReportedBy: dv5a at dc.uba.ar


The function GetDeviceCaps(NUMCOLORS) must return 1 if device uses more than 
256 colors (see http://msdn.microsoft.com/library/en-us/gdi/devcons_88s3.asp )
But is return -1. This is wrong.

http://source.winehq.org/source/dlls/winex11.drv/init.c#L213http://source.winehq.org/source/dlls/winex11.drv/init.c#L213

Fix is trivial :

216  * color depths, 1 is returned. */
217  return (screen_depth > 8) ? 1 : (1 << screen_depth);

This bug makes COMPUMAP application (a street map of Buenos Aires) crash on 
printing.

-- 
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the wine-bugs mailing list