CMFCVisualManager::OnFillBarBackground

The framework calls this method when it fills the background of a CBasePane object.

virtual void OnFillBarBackground(
   CDC* pDC,
   CBasePane* pBar,
   CRect rectClient,
   CRect rectClip,
   BOOL bNCArea = FALSE
);

Parameters

  • [in] pDC
    A pointer to the device context for a control bar.

  • [in] pBar
    A pointer to a CBasePane object. The framework fills the background of this pane.

  • [in] rectClient
    A rectangle that specifies the boundaries of the pane.

  • [in] rectClip
    A rectangle that specifies the clipping area of the pane.

  • [in] bNCArea
    A reserved value.

Remarks

The default implementation of this method fills the background of the bar with the 3d background color from the global variable afxGlobalData. Override this method in a derived visual manager to customize the background of a pane.

Example

The following example demonstrates how to use the OnFillBarBackground in the CMFCVisualManager class. This code snippet is part of the Outlook Demo sample.

// CDC* pDC 
    // CRect rectClient 
    // The this pointer points to a CMailBar class which extends the CPaneDialog class.
    CMFCVisualManager::GetInstance()->OnFillBarBackground(pDC, this, rectClient, rectClient);

Requirements

Header: afxvisualmanager.h

See Also

Reference

CMFCVisualManager Class

Hierarchy Chart

CBasePane Class