Commit 007776bc authored by Juanma Barranquero's avatar Juanma Barranquero

(Fx_display_color_cells): Force 24+ bit color depths to 24-bit.

parent ded0c207
2002-03-08 Juanma Barranquero <lektu@terra.es>
* w32fns.c (Fx_display_color_cells): Force 24+ bit color depths to
24-bit.
2002-03-06 Jason Rumney <jasonr@gnu.org>
* w32term.c (x_draw_hollow_cursor): Draw same size as block cursor.
......
......@@ -7768,8 +7768,10 @@ If omitted or nil, that stands for the selected frame's display. */)
else
cap = GetDeviceCaps (hdc,NUMCOLORS);
/* We force 24+ bit depths to 24-bit, both to prevent an overflow
and because probably is more meaningful on Windows anyway */
if (cap < 0)
cap = 1 << (dpyinfo->n_planes * dpyinfo->n_cbits);
cap = 1 << min(dpyinfo->n_planes * dpyinfo->n_cbits, 24);
ReleaseDC (dpyinfo->root_window, hdc);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment