#include <prnmks.h>
Public Member Functions | |
PrintMark () | |
Construct a new print mark. | |
~PrintMark () | |
virtual destructor, destroys all instances of the 'MarkPositions' list | |
void | SetCustomOrDefault (BOOL IsCustom) |
void | SetIDByte (BYTE NewID) |
void | SetType (MarkType type) |
void | SetMarkMenuText (const String_256 *pMenuText) |
Set this print mars menu text. | |
void | SetOrientation (MarkOrient orient) |
void | SetDefaultState (BOOL enabled) |
void | AddNewPosition (MarkPosition *pMarkPos) |
Return the menu text string saved in this print mark. | |
BOOL | DefaultsToOn () const |
BOOL | IsCustom (void) const |
BYTE | GetIDByte (void) const |
MarkType | GetType () const |
String_256 | GetMarkMenuText () const |
Return the menu text string saved in this print mark. | |
BOOL | FindMarkPosition (const MarkPosition *pSearchMark, MarkPosition **pFoundMark=NULL) const |
Check the cache to see if there's a mark already in it which matches pSearchMark. You can get the pointer to this cached mark by using pFoundMark. | |
BOOL | IsSimilarTo (const PrintMark *pOther) const |
Checks whether this print mark is similar to pOther. The current checks for similarity are... (1) the mark is of the same type (2) the mark has the same menu text. | |
MarkOrient | GetOrientation () const |
MarkPosition * | GetFirstPosition () const |
MarkPosition * | GetNextPosition (MarkPosition *pMP) const |
Private Member Functions | |
CC_DECLARE_MEMDUMP (PrintMark) | |
Private Attributes | |
BOOL | MarkIsCustom |
BYTE | IDByte |
MarkType | Type |
MarkOrient | Orientation |
BOOL | OnAsDefault |
String_256 | MenuText |
List | MarkPositions |
Definition at line 289 of file prnmks.h.
|
Construct a new print mark.
Definition at line 320 of file prnmks.cpp. 00321 { 00322 MarkIsCustom = FALSE; 00323 IDByte = 0; 00324 Type = MarkType_Unknown; 00325 Orientation = MO_None; 00326 OnAsDefault = FALSE; 00327 }
|
|
virtual destructor, destroys all instances of the 'MarkPositions' list
Definition at line 340 of file prnmks.cpp. 00341 { 00342 MarkPosition* pMarkPos; 00343 while ((pMarkPos=(MarkPosition*)MarkPositions.RemoveTail())) 00344 delete pMarkPos; 00345 }
|
|
Return the menu text string saved in this print mark.
Definition at line 399 of file prnmks.cpp. 00400 { 00401 ERROR3IF(pNewMarkPos==NULL,"NULL MarkPosition pointer passed to AddNewPosition"); 00402 if (pNewMarkPos) 00403 { 00404 if (!FindMarkPosition(pNewMarkPos)) 00405 MarkPositions.AddTail(pNewMarkPos); 00406 } 00407 }
|
|
|
|
Definition at line 305 of file prnmks.h. 00305 { return OnAsDefault; }
|
|
Check the cache to see if there's a mark already in it which matches pSearchMark. You can get the pointer to this cached mark by using pFoundMark.
Definition at line 429 of file prnmks.cpp. 00430 { 00431 ERROR3IF(pSearchMark==NULL,"PrintMark::FindMarkPosition passed a NULL search mark pointer"); 00432 if (pSearchMark) 00433 { 00434 MarkPosition* pMarkPos = GetFirstPosition(); 00435 while (pMarkPos) 00436 { 00437 // Check to see if this exists 00438 if (pSearchMark->IsEqualTo(pMarkPos)) 00439 { 00440 if (pFoundMark!=NULL) 00441 (*pFoundMark=pMarkPos); 00442 return TRUE; 00443 } 00444 pMarkPos = GetNextPosition(pMarkPos); 00445 } 00446 } 00447 if (pFoundMark!=NULL) 00448 (*pFoundMark=NULL); 00449 return FALSE; 00450 }
|
|
Definition at line 316 of file prnmks.h. 00316 { return (MarkPosition*)MarkPositions.GetHead(); }
|
|
Definition at line 308 of file prnmks.h. 00308 { return(IDByte); }
|
|
Return the menu text string saved in this print mark.
Definition at line 381 of file prnmks.cpp. 00382 { 00383 return MenuText; 00384 }
|
|
Definition at line 318 of file prnmks.h. 00319 { return (MarkPosition*)MarkPositions.GetNext(pMP); }
|
|
Definition at line 314 of file prnmks.h. 00314 { return Orientation; }
|
|
Definition at line 309 of file prnmks.h. 00309 { return Type; }
|
|
Definition at line 307 of file prnmks.h. 00307 { return(MarkIsCustom); }
|
|
Checks whether this print mark is similar to pOther. The current checks for similarity are... (1) the mark is of the same type (2) the mark has the same menu text.
Definition at line 468 of file prnmks.cpp. 00469 { 00470 ERROR2IF(pOther==NULL, FALSE, "NULL PrintMark pointer passed to IsSimilar()"); 00471 00472 if (Type == pOther->GetType()) 00473 { 00474 if (MenuText == pOther->GetMarkMenuText()) 00475 return TRUE; 00476 } 00477 return FALSE; 00478 }
|
|
Definition at line 297 of file prnmks.h. 00297 { MarkIsCustom = IsCustom; }
|
|
Definition at line 302 of file prnmks.h. 00302 { OnAsDefault = enabled; }
|
|
Definition at line 298 of file prnmks.h. 00298 { IDByte = NewID; }
|
|
Set this print mars menu text.
Definition at line 361 of file prnmks.cpp. 00362 { 00363 ERROR3IF(pMenuText==NULL,"ERROR ERROR, NULL pointer passed to SetMarkMenuText"); 00364 if (pMenuText!=NULL) 00365 MenuText = (*pMenuText); 00366 }
|
|
Definition at line 301 of file prnmks.h. 00301 { Orientation = orient; }
|
|
Definition at line 299 of file prnmks.h.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|