Fix display of BW images on MS-Windows

* src/image.c (convert_mono_to_color_image) [HAVE_NTGUI]: Swap the
fore- and the back-ground colors back to their normal conventions.
(Bug#6918)
This commit is contained in:
Kazuhiro Ito 2010-08-26 07:35:54 +00:00 committed by Eli Zaretskii
parent 26089c8c44
commit ba278e4a9b

View file

@ -3547,10 +3547,8 @@ convert_mono_to_color_image (struct frame *f, struct image *img,
release_frame_dc (f, hdc);
old_prev = SelectObject (old_img_dc, img->pixmap);
new_prev = SelectObject (new_img_dc, new_pixmap);
/* Windows convention for mono bitmaps is black = background,
white = foreground. */
SetTextColor (new_img_dc, background);
SetBkColor (new_img_dc, foreground);
SetTextColor (new_img_dc, foreground);
SetBkColor (new_img_dc, background);
BitBlt (new_img_dc, 0, 0, img->width, img->height, old_img_dc,
0, 0, SRCCOPY);