A
AlexanderZel
Guest
Hi,
I'm trying to change the background color of my toolbar.
class CMyToolBar : public CMFCToolBar { void OnFillBackground(CDC* pDC) ; };
void CMyToolBar ::OnFillBackground(CDC* pDC) { CRect crect; this->GetClientRect(&crect); CDC *pdcCtrl = this->GetDC(); CDC dcDst; dcDst.CreateCompatibleDC(pdcCtrl); dcDst.FillSolidRect(&crect,RGB(255,0,0)); } The function is being called from CMFCToolBar:oPaint(CDC* pDCPaint), but no color change.
Thanks,
Alex
Continue reading...
I'm trying to change the background color of my toolbar.
class CMyToolBar : public CMFCToolBar { void OnFillBackground(CDC* pDC) ; };
void CMyToolBar ::OnFillBackground(CDC* pDC) { CRect crect; this->GetClientRect(&crect); CDC *pdcCtrl = this->GetDC(); CDC dcDst; dcDst.CreateCompatibleDC(pdcCtrl); dcDst.FillSolidRect(&crect,RGB(255,0,0)); } The function is being called from CMFCToolBar:oPaint(CDC* pDCPaint), but no color change.
Thanks,
Alex
Continue reading...