If I do a
I get a black and white patterned square instead of a nice red square. Any idea how this could happen. (I am using a colour display and a normal window)
Thanks,
Code:
hDC = GetDC(m_hWnd);
m_hDC = CreateCompatibleDC(hDC);
m_hBrush = CreateSolidBrush(RGB(0xFF, 0, 0));
SelectObject(m_hDC, m_hBrush)
RECT rect;
rect.top = (m_ry * m_iSize) + m_iOffsetY;
rect.left = (m_rx * m_iSize) + m_iOffsetX;
rect.right = ((m_rx + 1) * m_iSize) + m_iOffsetX;
rect.bottom = ((m_ry + 1) * m_iSize) + m_iOffsetX;
FillRect(m_hDC, &rect, m_hBrush);
I get a black and white patterned square instead of a nice red square. Any idea how this could happen. (I am using a colour display and a normal window)
Thanks,