Go through http://discussion.forum.nokia.com/fo...d.php?t=113871 for details
Use the necessary code from the following
const CFont* logicalFont = AknLayoutUtils::FontFromId(EAknLogicalFontPrimarySmallFont);
// Extract font information
TFontSpec fontspec = logicalFont->FontSpecInTwips();
TCharFormat charFormat = TCharFormat(fontspec.iTypeface.iName, fontspec.iHeight);
charFormat.iFontPresentation.iTextColor = KRgbRed;
TCharFormatMask charFormatMask;
charFormatMask.SetAttrib(EAttFontTypeface);
charFormatMask.SetAttrib(EAttFontHeight);
charFormatMask.SetAttrib(EAttColor);
CCharFormatLayer* cCharFL = CCharFormatLayer::NewL(charFormat,charFormatMask);
iUrEditor->SetCharFormatLayer(cCharFL);
// Extract font information
TFontSpec fontspec = logicalFont->FontSpecInTwips();
TCharFormat charFormat = TCharFormat(fontspec.iTypeface.iName, fontspec.iHeight);
charFormat.iFontPresentation.iTextColor = KRgbRed;
TCharFormatMask charFormatMask;
charFormatMask.SetAttrib(EAttFontTypeface);
charFormatMask.SetAttrib(EAttFontHeight);
charFormatMask.SetAttrib(EAttColor);
CCharFormatLayer* cCharFL = CCharFormatLayer::NewL(charFormat,charFormatMask);
iUrEditor->SetCharFormatLayer(cCharFL);