Problem setting the back color
I have problem setting the backcolor on a checkbox or editbox or any other control.
It is like this.
SetBkColor(hdc, color)
I provide it the hdc or the control and the color but it does not change the color of the given control.
Do you know why it does not change it?
I have alomost made a text editor
Lots of links are MSDN down because they are rebuilding that section
---------------------------------------------------------------------------------
I am making a kind of text editor that is able to show two dialog boxes and that can save and open a file.
The problem is that when put this code in my main main windows' message handling routine, it just takes lots of memory. And when I run the application, and try to press enter lots of times or move the text around, it manipulates the whole text like chicken scratches:
Code:
case WM_CTLCOLOREDIT:
if(edithwnd == (HWND)lParam)
{
SetBkMode((HDC)wParam, TRANSPARENT);
SetTextColor((HDC)wParam, RGB(59, 195, 25));
return (LRESULT)GetStockObject(BLACK_BRUSH);
}
break;
It only happens when I put the above code in.
Why is it taking so much memory?