Tabbed dialogs offer built-in background handling, using background colors, background bitmaps and even through an application-defined callback, which can paint the background.
Background bitmaps are only supported on Windows XP (using Common Controls version 6) and above. While it is possible to enable background bitmaps for all environments, most Windows controls will not be rendered correctly. Background colors based on SFTTABS_TAB, colorClientArea are supported in all environments.
If special background handling is used, any controls located on the tab page are automatically rendered in a style allowing portions of the background to show through the control, giving a transparent effect.
Some third-party controls do not properly support transparent rendering. These controls cannot be used with special background handling. Most standard Windows controls and common controls support transparent rendering without problems. Most ActiveX controls and third-party controls also work correctly, but may have to be defined using their API to support transparency.
An application can define a background color for a tab page using the SFTTABS_TAB, colorClientArea member (see SetTabInfo). This defined color is automatically applied to the background of the tab page.
If a background color is not defined for a tab page, the tab control's defined background bitmap is used instead. The background bitmap is defined using the SFTTABS_CONTROL, hInsideBitmap member (see SetControlInfo).
If Windows themes are active, the theme's background supersedes the application's defined background color or background bitmap. These are never used if themes are active.
An application can define a callback which is called when the background needs to be painted. This callback may optionally be used even if Windows themes are active.
When using C, the SftTabs_TransparentControls function handles background painting.
When using C++/MFC, CSftTabsPage::m_lpfnDrawBackground can be used to define a background painting callback.