examples/ForumNokia/SMSExample/GUI/inc/SMSExampleRTEContainer.h

00001 /*
00002  * Copyright © 2008 Nokia Corporation.
00003  */
00004 
00005 #ifndef SMS_EXAMPLE_RTE_CONTAINER_H
00006 #define SMS_EXAMPLE_RTE_CONTAINER_H
00007 
00008 #include <coecntrl.h>
00009 #include <eikrted.h>  // CEikRichTextEditor
00010 #include <txtfrmat.h> // TCharFormat, TCharFormatMask
00011    
00015 class CSMSExampleRTEContainer : public CCoeControl
00016     {
00017     public:  // Constructors and destructor
00023         static CSMSExampleRTEContainer* NewL(const TRect& aRect);
00024 
00028         static CSMSExampleRTEContainer* NewLC(const TRect& aRect);
00029 
00034         void ConstructL(const TRect& aRect);
00035 
00039         ~CSMSExampleRTEContainer();
00040 
00041     public:  // New functions
00046         void DrawTextWithoutCarriageL( const TDesC& aText );
00047 
00052         void DrawTextL( const TDesC& aText );
00053 
00057         void AddCarriageReturnL();
00058 
00063         void DrawUnderlinedTextL( const TDesC& aText );
00064 
00068         void DrawLineL();
00069 
00070     private:  // New functions
00074         TInt GetScrollbarWidth() const;
00075         
00076     private:  // Functions from base classes
00080         void SizeChanged();
00081 
00085         TInt CountComponentControls() const;
00086 
00090         CCoeControl* ComponentControl(TInt aIndex) const;
00091 
00095         void Draw(const TRect& aRect) const;
00096 
00100         TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType);
00101 
00102     private:  // Data
00103         CEikRichTextEditor* iRTE;
00104         // Formatting options for the RTE
00105         TCharFormatMask iCharacterFormatMask;
00106         TCharFormat iCharacterFormat;
00107     };
00108 
00109 #endif // SMS_EXAMPLE_RTE_CONTAINER_H

Generated by  doxygen 1.6.2