Answer the question
In order to leave comments, you need to log in
[WinAPI] TextOut() color and window background color do not match, how to set the same color for both of them?
The problem is that text is displayed in the window and its background does not match the background of the window.
It looks like this:
The color of the window itself looks like this:
...
wc.hbrBackground = (HBRUSH)(COLOR_WINDOW);
...
SetBkColor(hdc, ...);
SetBkColor(hdc, RGB(
GetRValue(GetSysColor(COLOR_WINDOW)),
GetGValue(GetSysColor(COLOR_WINDOW)),
GetBValue(GetSysColor(COLOR_WINDOW))
));
GetRValue(GetSysColor(COLOR_WINDOW)),
GetGValue(GetSysColor(COLOR_WINDOW)),
GetBValue(GetSysColor(COLOR_WINDOW))
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question