diff --git a/client/X11/xf_gdi.c b/client/X11/xf_gdi.c index f1760f2c9..3441b6589 100644 --- a/client/X11/xf_gdi.c +++ b/client/X11/xf_gdi.c @@ -432,7 +432,9 @@ void xf_gdi_opaque_rect(rdpContext* context, OPAQUE_RECT_ORDER* opaque_rect) uint32 color; xfInfo* xfi = ((xfContext*) context)->xfi; - color = freerdp_color_convert_var_rgb(opaque_rect->color, xfi->srcBpp, 32, xfi->clrconv); + color = (xfi->clrconv->invert)? + freerdp_color_convert_var_bgr(opaque_rect->color, xfi->srcBpp, 32, xfi->clrconv): + freerdp_color_convert_var_rgb(opaque_rect->color, xfi->srcBpp, 32, xfi->clrconv); XSetFunction(xfi->display, xfi->gc, GXcopy); XSetFillStyle(xfi->display, xfi->gc, FillSolid); @@ -461,7 +463,9 @@ void xf_gdi_multi_opaque_rect(rdpContext* context, MULTI_OPAQUE_RECT_ORDER* mult DELTA_RECT* rectangle; xfInfo* xfi = ((xfContext*) context)->xfi; - color = freerdp_color_convert_var_rgb(multi_opaque_rect->color, xfi->srcBpp, 32, xfi->clrconv); + color = (xfi->clrconv->invert)? + freerdp_color_convert_var_bgr(multi_opaque_rect->color, xfi->srcBpp, 32, xfi->clrconv): + freerdp_color_convert_var_rgb(multi_opaque_rect->color, xfi->srcBpp, 32, xfi->clrconv); XSetFunction(xfi->display, xfi->gc, GXcopy); XSetFillStyle(xfi->display, xfi->gc, FillSolid);