language is c, im having trouble with the `WM_PAINT.
case WM_PAINT:
{
PAINTSTRUCT ps;
HDC hdc = BeginPaint(hwnd, &ps);
FillRect(hdc, &ps.rcPaint, (COLOR_WINDOW+1));
RECT r1 = mr(0, 0, 1000, 1000);
FillRect(hdc, &r1, (HBRUSH) RGB(255, 0, 0));
EndPaint(hwnd, &ps);
}
`
im trying to get it to draw a red rectangle but i dont see it.
`if (hwnd == NULL)
{
return 0;
}
ShowWindow(hwnd, nCmdShow);
MSG msg;
ZeroMemory(&msg, sizeof(MSG));
while (GetMessage(&msg, NULL, 0, 0) > 0)
{
TranslateMessage(&msg);
DispatchMessage(&msg);
}
}`
msg system^
the window shows, WM PAINT is called, but FILLRECT is where it seems to not do anything so i think i might of typed it out wrong?
either way idk what to do