|
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_CSVGFONTELEMENTIMPL_ |
|
20 #define _INC_CSVGFONTELEMENTIMPL_ |
|
21 |
|
22 #include "SVGElementImpl.h" |
|
23 #include "GfxFloatFixPt.h" |
|
24 |
|
25 |
|
26 |
|
27 |
|
28 #ifdef SVG_FONTS_INCLUDE |
|
29 |
|
30 class CSvgDocumentImpl; |
|
31 |
|
32 |
|
33 /** |
|
34 * Class description goes here. |
|
35 * |
|
36 * @lib SVGEngine.lib |
|
37 * @since 1.0 |
|
38 */ |
|
39 class CSvgFontElementImpl : public CSvgElementImpl |
|
40 { |
|
41 public: |
|
42 |
|
43 // Constructor/deconstructor |
|
44 |
|
45 |
|
46 /** |
|
47 * Need method description |
|
48 * |
|
49 * @since 1.0 |
|
50 * @param |
|
51 * @return |
|
52 */ |
|
53 static CSvgFontElementImpl*NewL( const TUint8 aElemID, |
|
54 CSvgDocumentImpl* aDoc ); |
|
55 |
|
56 /** |
|
57 * Need method description |
|
58 * |
|
59 * @since 1.0 |
|
60 * @param |
|
61 * @return |
|
62 */ |
|
63 static CSvgFontElementImpl*NewLC( const TUint8 aElemID, |
|
64 CSvgDocumentImpl* aDoc ); |
|
65 |
|
66 private: |
|
67 /** |
|
68 * Need method description |
|
69 * |
|
70 * @since 1.0 |
|
71 * @param |
|
72 * @return |
|
73 */ |
|
74 void ConstructL( const TUint8 aElemID ); |
|
75 |
|
76 |
|
77 |
|
78 public: |
|
79 |
|
80 |
|
81 /** |
|
82 * Need method description |
|
83 * |
|
84 * @since 1.0 |
|
85 * @param |
|
86 * @return |
|
87 */ |
|
88 virtual ~CSvgFontElementImpl(); |
|
89 |
|
90 // From SVG DOM: |
|
91 |
|
92 |
|
93 /** |
|
94 * Need method description |
|
95 * |
|
96 * @since 1.0 |
|
97 * @param |
|
98 * @return |
|
99 */ |
|
100 TFloatFixPt GetHorzOrgX(); |
|
101 |
|
102 |
|
103 /** |
|
104 * Need method description |
|
105 * |
|
106 * @since 1.0 |
|
107 * @param |
|
108 * @return |
|
109 */ |
|
110 TFloatFixPt GetHorzOrgY(); |
|
111 |
|
112 |
|
113 /** |
|
114 * Need method description |
|
115 * |
|
116 * @since 1.0 |
|
117 * @param |
|
118 * @return |
|
119 */ |
|
120 TFloatFixPt GetHorzAdvX(); |
|
121 |
|
122 // SVG Implementation: |
|
123 |
|
124 /** |
|
125 * Need method description |
|
126 * |
|
127 * @since 1.0 |
|
128 * @param |
|
129 * @return |
|
130 */ |
|
131 TInt SetAttributeFloatL( const TInt aNameId, |
|
132 const TFloatFixPt aValue ); |
|
133 |
|
134 /** |
|
135 * Need method description |
|
136 * |
|
137 * @since 1.0 |
|
138 * @param |
|
139 * @return |
|
140 */ |
|
141 TInt SetAttributeL( const TDesC& aName, |
|
142 const TDesC& aValue ); |
|
143 |
|
144 |
|
145 /** |
|
146 * Need method description |
|
147 * |
|
148 * @since 1.0 |
|
149 * @param |
|
150 * @return |
|
151 */ |
|
152 MXmlElement* CloneL(MXmlElement* aParentElement); |
|
153 |
|
154 |
|
155 /** |
|
156 * Need method description |
|
157 * |
|
158 * @since 1.0 |
|
159 * @param |
|
160 * @return |
|
161 */ |
|
162 TBool DrawL( CGfx2dGc* aGc, |
|
163 CSvgElementImpl* aElement ); |
|
164 // From MXmlElementOpt API |
|
165 |
|
166 |
|
167 /** |
|
168 * Need method description |
|
169 * |
|
170 * @since 1.0 |
|
171 * @param |
|
172 * @return |
|
173 */ |
|
174 TInt GetAttributeFloat( const TInt aNameId, |
|
175 TFloatFixPt& aValue ); |
|
176 |
|
177 void Print( TBool aIsEncodeOn ); |
|
178 |
|
179 private: |
|
180 |
|
181 TFloatFixPt iHorzOrgX; |
|
182 TFloatFixPt iHorzOrgY; |
|
183 TFloatFixPt iHorzAdvX; |
|
184 |
|
185 |
|
186 |
|
187 /** |
|
188 * Need method description |
|
189 * |
|
190 * @since 1.0 |
|
191 * @param |
|
192 * @return |
|
193 */ |
|
194 CSvgFontElementImpl( CSvgDocumentImpl* aDoc ); |
|
195 }; |
|
196 |
|
197 #endif /* SVG_FONTS_INCLUDE */ |
|
198 |
|
199 #endif |