svgtopt/SVG/SVGImpl/inc/SVGMissingGlyphElementImpl.h
changeset 46 88edb906c587
equal deleted inserted replaced
-1:000000000000 46:88edb906c587
       
     1 /*
       
     2 * Copyright (c) 2003 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  SVG Implementation header file
       
    15  *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef _INC_CSVGMISSINGGLYPHELEMENTIMPL_
       
    20 #define _INC_CSVGMISSINGGLYPHELEMENTIMPL_
       
    21 
       
    22 #include "SVGElementImpl.h"
       
    23 #include "GfxFloatFixPt.h"
       
    24 
       
    25 
       
    26 
       
    27 #ifdef SVG_FONTS_INCLUDE
       
    28 
       
    29 class   CSvgDocumentImpl;
       
    30 
       
    31 
       
    32 /**
       
    33  * Class description goes here.
       
    34  *
       
    35  *  @lib SVGEngine.lib
       
    36  *  @since 1.0
       
    37  */
       
    38 class CSvgMissingGlyphElementImpl : public CSvgElementImpl
       
    39     {
       
    40     public:
       
    41 
       
    42         // Constructor/deconstructor
       
    43 
       
    44 
       
    45 		/**
       
    46          * Need method description
       
    47          *
       
    48          * @since 1.0
       
    49          * @param
       
    50          * @return
       
    51          */
       
    52         static CSvgMissingGlyphElementImpl*NewL(  const TUint8 aElemID,
       
    53                                       CSvgDocumentImpl* aDoc );
       
    54 
       
    55 		/**
       
    56          * Need method description
       
    57          *
       
    58          * @since 1.0
       
    59          * @param
       
    60          * @return
       
    61          */
       
    62         static CSvgMissingGlyphElementImpl*NewLC(  const TUint8 aElemID,
       
    63                                        CSvgDocumentImpl* aDoc );
       
    64 
       
    65 	private:
       
    66 		/**
       
    67          * Need method description
       
    68          *
       
    69          * @since 1.0
       
    70          * @param
       
    71          * @return
       
    72          */
       
    73         void                            ConstructL(  const TUint8 aElemID  );
       
    74 
       
    75 
       
    76 
       
    77 	public:
       
    78 
       
    79 
       
    80         /**
       
    81          * Need method description
       
    82          *
       
    83          * @since 1.0
       
    84          * @param
       
    85          * @return
       
    86          */
       
    87         virtual                             ~CSvgMissingGlyphElementImpl();
       
    88 
       
    89         // From SVG DOM:
       
    90 
       
    91 
       
    92         /**
       
    93          * Need method description
       
    94          *
       
    95          * @since 1.0
       
    96          * @param
       
    97          * @return
       
    98          */
       
    99         TFloatFixPt                              GetHorzAdvX();
       
   100 
       
   101         // SVG Implementation:
       
   102 
       
   103 
       
   104         /**
       
   105          * Need method description
       
   106          *
       
   107          * @since 1.0
       
   108          * @param
       
   109          * @return
       
   110          */
       
   111         void                                SetPath( const TDesC& aPath );
       
   112 
       
   113 
       
   114 
       
   115 		/**
       
   116          * Need method description
       
   117          *
       
   118          * @since 1.0
       
   119          * @param
       
   120          * @return
       
   121          */
       
   122          TInt								SetAttributeFloatL( const TInt aNameId, const TFloatFixPt aValue );
       
   123 
       
   124         // From MXmlElement API
       
   125 
       
   126 
       
   127         /**
       
   128          * Need method description
       
   129          *
       
   130          * @since 1.0
       
   131          * @param
       
   132          * @return
       
   133          */
       
   134         TInt                                SetAttributeL( const TDesC& aName,
       
   135                                                            const TDesC& aValue );
       
   136 
       
   137         /**
       
   138          * Need method description
       
   139          *
       
   140          * @since 1.0
       
   141          * @param
       
   142          * @return
       
   143          */
       
   144         MXmlElement*        CloneL(MXmlElement* aParentElement);
       
   145 
       
   146 
       
   147         /**
       
   148          * Need method description
       
   149          *
       
   150          * @since 1.0
       
   151          * @param
       
   152          * @return
       
   153          */
       
   154         TBool                               DrawL( CGfx2dGc* aGc,
       
   155                                                    CSvgElementImpl* aElement );
       
   156         // From MXmlElementOpt API
       
   157 
       
   158         /**
       
   159          * Need method description
       
   160          *
       
   161          * @since 1.0
       
   162          * @param
       
   163          * @return
       
   164          */
       
   165         TInt                                GetAttributeFloat( const TInt aNameId,
       
   166                                                                TFloatFixPt& aValue );
       
   167 
       
   168 
       
   169         /**
       
   170          * Need method description
       
   171          *
       
   172          * @since 1.0
       
   173          * @param
       
   174          * @return
       
   175          */
       
   176         TInt                                GetAttributePath( const TInt aNameId,
       
   177                                                               CGfxGeneralPath*& aValue );
       
   178 
       
   179         /**
       
   180          * Need method description
       
   181          *
       
   182          * @since 1.0
       
   183          * @param
       
   184          * @return
       
   185          */
       
   186         TInt                                SetAttributePathL( const TInt aNameId,
       
   187                                                                CGfxGeneralPath* aValue );
       
   188 
       
   189 		TInt                                SetAttributePathRef( const TInt aNameId,
       
   190                                                        CGfxGeneralPath*& aValue );
       
   191 
       
   192 		CGfxGeneralPath* GetPathAttribute(TInt aAttributeId);
       
   193 		void SetPathAttribute(TInt aAttributeId, CGfxGeneralPath* aPathHandle);
       
   194 		
       
   195 		void Print( TBool aIsEncodeOn );
       
   196 		
       
   197     private:
       
   198 
       
   199         TFloatFixPt                              iHorzAdvX;
       
   200 
       
   201         //    TInt16 iPathLength;
       
   202 
       
   203         CGfxGeneralPath*                    iShape;
       
   204 
       
   205 
       
   206 
       
   207 
       
   208 
       
   209         /**
       
   210          * Need method description
       
   211          *
       
   212          * @since 1.0
       
   213          * @param
       
   214          * @return
       
   215          */
       
   216                                             CSvgMissingGlyphElementImpl( CSvgDocumentImpl* aDoc );
       
   217     };
       
   218 
       
   219 #endif /* SVG_FONTS_INCLUDE */
       
   220 
       
   221 #endif /* #ifndef _INC_CSVGMISSINGGLYPHElementIMPL_ */