#include <rechellp.h>
Inheritance diagram for EllipseRecordHandler:
Public Member Functions | |
EllipseRecordHandler () | |
~EllipseRecordHandler () | |
UINT32 * | GetTagList () |
Returns an array of records handled by this class. See Also: EllispeRecordHandler::HandleRecord. | |
BOOL | HandleRecord (CXaraFileRecord *pCXaraFileRecord) |
Handles ellipse type records for the new file format. | |
Private Member Functions | |
CC_DECLARE_DYNAMIC (EllipseRecordHandler) | |
BOOL | ReadEllipseSimple (CXaraFileRecord *pCXaraFileRecord) |
Reads in an ellise record. | |
BOOL | ReadEllipseComplex (CXaraFileRecord *pCXaraFileRecord) |
Definition at line 124 of file rechellp.h.
|
Definition at line 130 of file rechellp.h.
|
|
Definition at line 131 of file rechellp.h.
|
|
|
|
Returns an array of records handled by this class. See Also: EllispeRecordHandler::HandleRecord.
Reimplemented from RegularShapeRecordHandler. Definition at line 138 of file rechellp.cpp. 00139 { 00140 static UINT32 TagList[] = {TAG_ELLIPSE_SIMPLE, 00141 TAG_ELLIPSE_COMPLEX, 00142 CXFRH_TAG_LIST_END}; 00143 return &TagList[0]; 00144 }
|
|
Handles ellipse type records for the new file format.
Reimplemented from RegularShapeRecordHandler. Definition at line 158 of file rechellp.cpp. 00159 { 00160 BOOL ok; 00161 00162 switch (pCXaraFileRecord->GetTag()) 00163 { 00164 case TAG_ELLIPSE_SIMPLE : ok = ReadEllipseSimple(pCXaraFileRecord); break; 00165 case TAG_ELLIPSE_COMPLEX : ok = ReadEllipseComplex(pCXaraFileRecord); break; 00166 default : ok = ReadShapeInvalid(pCXaraFileRecord); break; 00167 } 00168 00169 return ok; 00170 }
|
|
Definition at line 212 of file rechellp.cpp. 00213 { 00214 BOOL ok = TRUE; 00215 00216 NodeRegularShape *pEllipse; 00217 DocCoord CentrePoint; 00218 DocCoord MajorAxis; 00219 DocCoord MinorAxis; 00220 00221 pEllipse = new NodeRegularShape; 00222 00223 if (ok) ok = SetupShape(pEllipse); 00224 if (ok) ok = SetIsCircular(pEllipse, TRUE); 00225 00226 if (ok) ok = pCXaraFileRecord->ReadCoord(&CentrePoint); 00227 if (ok) ok = SetCentrePoint(pEllipse, CentrePoint); 00228 00229 if (ok) ok = pCXaraFileRecord->ReadCoordTrans(&MajorAxis,0,0); 00230 if (ok) ok = SetMajorAxis(pEllipse, MajorAxis); 00231 00232 if (ok) ok = pCXaraFileRecord->ReadCoordTrans(&MinorAxis,0,0); 00233 if (ok) ok = SetMinorAxis(pEllipse, MinorAxis); 00234 00235 if (ok) ok = InvalidateCache(pEllipse); 00236 if (ok) ok = InsertNode(pEllipse); 00237 00238 return ok; 00239 }
|
|
Reads in an ellise record.
Definition at line 185 of file rechellp.cpp. 00186 { 00187 BOOL ok = TRUE; 00188 00189 NodeRegularShape * pEllipse; 00190 DocCoord CentrePoint; 00191 INT32 Height; 00192 INT32 Width; 00193 00194 pEllipse = new NodeRegularShape; 00195 00196 if (ok) ok = SetupShape(pEllipse); 00197 if (ok) ok = SetIsCircular(pEllipse, TRUE); 00198 00199 if (ok) ok = pCXaraFileRecord->ReadCoord(&CentrePoint); 00200 if (ok) ok = SetCentrePoint(pEllipse, CentrePoint); 00201 00202 if (ok) ok = pCXaraFileRecord->ReadINT32(&Width); 00203 if (ok) ok = pCXaraFileRecord->ReadINT32(&Height); 00204 if (ok) ok = SetHeightAndWidth(pEllipse, Height, Width); 00205 00206 if (ok) ok = InvalidateCache(pEllipse); 00207 if (ok) ok = InsertNode(pEllipse); 00208 00209 return ok; 00210 }
|