PATCH: console bg/fg swapped

Marcus Meissner marcus at jet.franken.de
Sun Dec 30 13:25:00 CST 2001


Hi,

My win32 console application had fore and background color swapped. Fixed.

Ciao, Marcus

Changelog:
	Swap fg/bg color to be correct.

Index: user.c
===================================================================
RCS file: /home/wine/wine/programs/wineconsole/user.c,v
retrieving revision 1.2
diff -u -r1.2 user.c
--- user.c	2001/12/04 20:46:54	1.2
+++ user.c	2001/12/30 17:41:42
@@ -39,8 +39,8 @@
 	for (i = 0; i < data->curcfg.win_width; i++)
 	{
 	    attr = cell[i].Attributes;
-	    SetBkColor(PRIVATE(data)->hMemDC, WCUSER_ColorMap[attr & 0x0F]);
-	    SetTextColor(PRIVATE(data)->hMemDC, WCUSER_ColorMap[(attr >> 4) & 0x0F]);
+	    SetBkColor(PRIVATE(data)->hMemDC,WCUSER_ColorMap[(attr>>4)&0x0F]);
+	    SetTextColor(PRIVATE(data)->hMemDC, WCUSER_ColorMap[attr&0x0F]);
 	    for (k = i; k < data->curcfg.win_width && cell[k].Attributes == attr; k++)
 	    {
 		line[k - i] = cell[k].Char.UnicodeChar;




More information about the wine-patches mailing list