MCoeControlBackground Class Reference

#include <mw/coecntrl.h>

Link against: cone.lib

class MCoeControlBackground
Public Member Functions
pure virtual voidDraw(CWindowGc &, const CCoeControl &, const TRect &)
virtual IMPORT_C voidGetTextDrawer(CCoeTextDrawerBase *&, const CCoeControl *)
Protected Member Functions
MCoeControlBackground()

Detailed Description

Interface to be used if a control elects to be a background drawer.

Parent controls can elect to take responsibility for drawing the background for their child controls. To achieve this, they should aggregate an object that implements this interface. CCoeControl::SetBackground() accepts the object and sets it as the background drawer

See also: CCoeControl::EnableWindowTransparency()

Constructor & Destructor Documentation

MCoeControlBackground ( )

IMPORT_CMCoeControlBackground()[protected]

Member Function Documentation

Draw ( CWindowGc &, const CCoeControl &, const TRect & )

voidDraw(CWindowGc &aGc,
const CCoeControl &aControl,
const TRect &aRect
)const [pure virtual]

Draw the background for a given control. The text drawer that shall be used to draw text on the specific background can be fetched through the GetTextDrawer() method.

Parameters
aGcGraphics context used for drawing
aControlThe control being drawn (may be a child of the drawer)
aRectThe area to be redrawn

GetTextDrawer ( CCoeTextDrawerBase *&, const CCoeControl * )

IMPORT_C voidGetTextDrawer(CCoeTextDrawerBase *&aTextDrawer,
const CCoeControl *aDrawingControl
)const [virtual]

This function retrieves the text drawer associated with the background. Default empty method.

Parameters
aTextDrawerNot used.
aDrawingControlNot used.