CMXReferDotDash Class Reference

#include <cmxexdc.h>

Inheritance diagram for CMXReferDotDash:

CMXReferListItem ListItem CCObject SimpleCCObject CMXReferDefaultDotDash List of all members.

Public Member Functions

 CMXReferDotDash (CMXExportDC *pDC)
void Set (DashRec *ptDash)
INT32 IsInWhichDesc (void)
BOOL WriteInDesc (CMXExportDC *pDC)
 writes a dot dash pattern to the description section
virtual BOOL AreYouThisDotDash (DashRec *ptDash)

Protected Attributes

DashRecpDash

Private Member Functions

 CC_DECLARE_DYNAMIC (CMXReferDotDash)

Detailed Description

Definition at line 515 of file cmxexdc.h.


Constructor & Destructor Documentation

CMXReferDotDash::CMXReferDotDash CMXExportDC pDC  )  [inline]
 

Definition at line 520 of file cmxexdc.h.

00520 : CMXReferListItem(pDC) {pDash = 0;};


Member Function Documentation

virtual BOOL CMXReferDotDash::AreYouThisDotDash DashRec ptDash  )  [inline, virtual]
 

Reimplemented in CMXReferDefaultDotDash.

Definition at line 527 of file cmxexdc.h.

00527 {return ((*pDash) == (*ptDash))?TRUE:FALSE;};

CMXReferDotDash::CC_DECLARE_DYNAMIC CMXReferDotDash   )  [private]
 

INT32 CMXReferDotDash::IsInWhichDesc void   )  [inline, virtual]
 

Reimplemented from CMXReferListItem.

Reimplemented in CMXReferDefaultDotDash.

Definition at line 524 of file cmxexdc.h.

00524 {return cmxDESC_DOTDASH;};

void CMXReferDotDash::Set DashRec ptDash  )  [inline]
 

Definition at line 522 of file cmxexdc.h.

00522 {pDash = ptDash;};

BOOL CMXReferDotDash::WriteInDesc CMXExportDC pDC  )  [virtual]
 

writes a dot dash pattern to the description section

Author:
Ben_Summers (Xara Group Ltd) <camelotdev@xara.com>
Date:
25/07/96
Parameters:
none [INPUTS]
Returns:
success
See also:

Reimplemented from CMXReferListItem.

Reimplemented in CMXReferDefaultDotDash.

Definition at line 2876 of file cmxexdc.cpp.

02877 {
02878     pDash->CheckAndFix();           // just in case
02879 
02880     // start the tag
02881     if(!pDC->StartTag(cmxTAG_DescrSection_Dash))
02882         return FALSE;
02883 
02884     // dot count
02885     WORD DotCount = (WORD)pDash->Elements;
02886     if(!pDC->WriteData(&DotCount, sizeof(DotCount)))
02887         return FALSE;
02888 
02889     // write the elements
02890     for(INT32 l = 0; l < pDash->Elements; l++)
02891     {
02892         WORD Element = (WORD)((pDash->ElementData[l] + 4) / pDash->LineWidth);
02893         if(Element <= 0) Element = 1;
02894         Element *= 4;
02895         if(!pDC->WriteData(&Element, sizeof(Element)))
02896             return FALSE;
02897     }
02898 
02899     // end the tag and write the end tag
02900     if(!pDC->EndTag() || !pDC->WriteMinEndTag())
02901         return FALSE;
02902 
02903     return TRUE;
02904 }


Member Data Documentation

DashRec* CMXReferDotDash::pDash [protected]
 

Definition at line 527 of file cmxexdc.h.


The documentation for this class was generated from the following files:
Generated on Sat Nov 10 03:52:42 2007 for Camelot by  doxygen 1.4.4