commonuisupport/uilaf/inc/exparser.h
changeset 0 2f259fa3e83a
equal deleted inserted replaced
-1:000000000000 0:2f259fa3e83a
       
     1 // Copyright (c) 1999-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 // An example parser
       
    15 // 
       
    16 //
       
    17 
       
    18 #ifndef __EXPARSER_H__
       
    19 #define __EXPARSER_H__
       
    20 
       
    21 #include <mparser.h>
       
    22 
       
    23 class CRichText;
       
    24 class TCharFormat;
       
    25 
       
    26 class ExampleParser
       
    27 	{
       
    28 public:
       
    29 	EXPORT_C static MParser* NewParserL();
       
    30 	};
       
    31 
       
    32 class CExampleParser : public CBase, public MParser
       
    33 	{
       
    34 public:
       
    35 	inline CExampleParser();
       
    36 public: // from MParser
       
    37 	void Release();
       
    38 	TBool ParseThisText(const CRichText& aTextObj,TBool aAllowBack,TInt aStartScan,
       
    39 							TInt aScanLength,TInt& aStartTag, TInt& aTagLength);
       
    40 	const TDesC& CreateDoItText(const CRichText& aTextObj,TInt aStartText,TInt aLength);
       
    41 	void ActivateThisTextL(const CRichText& aTextObj,TInt aStartText,TInt aLength);
       
    42 	TBool ReformatOnRecognise() const;
       
    43 	TBool ReformatOnRollover() const;
       
    44 	void GetRecogniseFormat(TCharFormat& aFormat);
       
    45 	void GetRolloverFormat(TCharFormat& aFormat);
       
    46 	};
       
    47 
       
    48 inline CExampleParser::CExampleParser()
       
    49 	{}
       
    50 
       
    51 #endif