Symbian
Symbian Developer Library

SYMBIAN OS V9.4

Feedback

[Index] [Previous] [Next]

#include <coetextdrawer.h>
Link against: cone.lib

Class CCoePlainTextDrawer

class CCoePlainTextDrawer : public CCoeTextDrawerBase;

Description

This is a basic text drawer without any text effects. The default text drawer that can be used if no other (device specific) text drawers has been added to the system.

Derivation

Members

Defined in CCoePlainTextDrawer:

Inherited from CBase:

Inherited from CCoeTextDrawerBase:

Inherited from MObjectProvider:


Member functions


New(TRgb)

IMPORT_C static CCoePlainTextDrawer* New(TRgb aTextColor);

Description

Created a new plain text drawer on the heap. This shall typically be done in the CCoeControl::GetTextDrawer(CCoeTextDrawerBase *&,const CCoeControl *,TInt)const method, or better, in the constructor of the owner of the text drawer.

Do not call this method from within a CCoeControl::Draw(const TRect &)const method. If all you want is access to a text drawer, call CCoeControl::TextDrawer(TInt)const.

Parameters

TRgb aTextColor

The color that will be used to draw text.

Return value

CCoePlainTextDrawer *

A new CCoePlainTextDrawer instance or null if the creation of a new instance failed.


TextColor()const

IMPORT_C virtual TRgb TextColor() const;

Description

See CCoeTextDrawerBase::TextColor()const.

Return value

TRgb

See also:


SetTextColor(TRgb)

IMPORT_C virtual void SetTextColor(TRgb aTextColor);

Description

See CCoeTextDrawerBase::SetTextColor(TRgb).

Parameters

TRgb aTextColor

See also:


MopSupplyObject(TTypeUid)

protected: IMPORT_C virtual TTypeUid::Ptr MopSupplyObject(TTypeUid aId);

Description

This function is defined by the MObjectProvider class. It allows the actual type of text drawer to be identified.

Parameters

TTypeUid aId

The type of the desired object.

Return value

TTypeUid::Ptr

A pointer to an object.

See also:


DrawText(CGraphicsContext &,const TCoeTextTypeAdaptor &,const CFont &,const TRect &,const TRect &)const

private: virtual void DrawText(CGraphicsContext &aGc, const TCoeTextTypeAdaptor &aText, const CFont &aFont, const TRect &aTextRect, const TRect &aClipRect) const;

Description

Draws the text provided as parameter.

Parameters

CGraphicsContext &aGc

The graphics context.

const TCoeTextTypeAdaptor &aText

The TCoeTextTypeAdaptor text object to draw.

const CFont &aFont

Font to be used for drawing the text.

const TRect &aTextRect

The rectangle to draw the text in.

const TRect &aClipRect

The clipping rectangle.

See also:


Reset()

private: virtual void Reset();

Description

See CCoeTextDrawerBase::Reset().

[Top]


Member enumerations


Enum anonymous

n/a

Description

ETypeId