|
|
|
|
Forum
Please
Log In
to post a new message or reply to an existing one. If you are not registered, please
register.
NOTE: Some forums may be read-only if you are not currently subscribed to
our technical support services.
Subject |
Author |
Date |
|
Christophe Guibert
|
Jan 6, 2008 - 11:39 AM
|
Hello,
I would like to paint the CMainFrame background with the current paint manager theme, as you did in the views of the MDIDOCVIEW sample.
I added an OnPaint() method to the main frame in your sample, and naively thought it would do the trick :
void CMainFrame::OnPaint()
{
CPaintDC dcPaint( this );
CExtMemoryDC dc( &dcPaint );
CRect rcClient;
GetClientRect( &rcClient );
if( ! g_PaintManager->PaintDocumentClientAreaBkgnd( dc, this ) )
{
dc.FillSolidRect(
&rcClient,
g_PaintManager->GetColor( COLOR_WINDOW, this )
);
}
}
The PaintDocumentClientAreaBkgnd() method returns true, but nothing seems to be done.
Could you tell me what I am missing in your sample ?
Thank you and best regards,
Christophe Guibert
|
|
Suhai Gyorgy
|
Jan 7, 2008 - 3:00 AM
|
|
|
Christophe Guibert
|
Jan 7, 2008 - 2:14 PM
|
Hello Suhai,
Thank you very much : exactly what I needed, and it works fine.
Best Regards,
Christophe Guibert
|
|