AttrOverprintLine Class Reference

Attribute indicating if overprint-line is enabled or disabled. More...

#include <isetattr.h>

Inheritance diagram for AttrOverprintLine:

AttrImagesetting NodeAttribute NodeRenderable Node CCObject SimpleCCObject List of all members.

Public Member Functions

 AttrOverprintLine ()
 Default constructor for AttrOverprintLine.
 AttrOverprintLine (Node *ContextNode, AttachNodeDirection Direction, BOOL Locked=FALSE, BOOL Mangled=FALSE, BOOL Marked=FALSE, BOOL Selected=FALSE)
 Constructs an AttrOverprintLine Attribute.
virtual UINT32 GetAttrNameID (void)
 Retrieves a string resource ID describing this attribute.
virtual AttrIndex GetAttributeIndex ()
virtual void GetDebugDetails (StringBase *Str)
 Produces debug details about this node.
virtual UINT32 GetNodeSize () const
 For finding the size of the node, in bytes.
virtual NodeSimpleCopy ()
 This method returns a shallow copy of the node with all Node pointers NULL. The function is virtual, and must be defined for all derived classes.
virtual INT32 operator== (const NodeAttribute &NodeAttrib)
 Comparison operator - determines if the AttributeValues of both objects are ==.
virtual AttributeValueGetAttributeValue ()
virtual BOOL WritePreChildrenWeb (BaseCamelotFilter *pFilter)
 Writes out a record that represents the node, to either Native or Web file format.
virtual BOOL WritePreChildrenNative (BaseCamelotFilter *pFilter)

Public Attributes

OverprintLineAttrValue Value

Detailed Description

Attribute indicating if overprint-line is enabled or disabled.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
23/7/96

Definition at line 228 of file isetattr.h.


Constructor & Destructor Documentation

AttrOverprintLine::AttrOverprintLine  ) 
 

Default constructor for AttrOverprintLine.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
23/7/96

Definition at line 531 of file isetattr.cpp.

00532 {
00533 }

AttrOverprintLine::AttrOverprintLine Node ContextNode,
AttachNodeDirection  Direction,
BOOL  Locked = FALSE,
BOOL  Mangled = FALSE,
BOOL  Marked = FALSE,
BOOL  Selected = FALSE
 

Constructs an AttrOverprintLine Attribute.

Definition at line 552 of file isetattr.cpp.

00558                 : AttrImagesetting(ContextNode, Direction, Locked, Mangled, Marked, Selected)
00559 {
00560 }


Member Function Documentation

virtual AttrIndex AttrOverprintLine::GetAttributeIndex  )  [inline, virtual]
 

Reimplemented from NodeAttribute.

Definition at line 243 of file isetattr.h.

00243 { return ATTR_OVERPRINTLINE; }

virtual AttributeValue* AttrOverprintLine::GetAttributeValue  )  [inline, virtual]
 

Reimplemented from NodeAttribute.

Definition at line 250 of file isetattr.h.

00250 { return(&Value); };

UINT32 AttrOverprintLine::GetAttrNameID void   )  [virtual]
 

Retrieves a string resource ID describing this attribute.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
23/7/96
Returns:
Attribute description string-resource ID

Reimplemented from NodeAttribute.

Definition at line 608 of file isetattr.cpp.

00609 {
00610     return(_R(IDS_ATTROVERPRINTLINE));
00611 }

void AttrOverprintLine::GetDebugDetails StringBase Str  )  [virtual]
 

Produces debug details about this node.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
23/7/96
Parameters:
On return, Str is filled in with details on this node [OUTPUTS]

Reimplemented from NodeRenderable.

Definition at line 628 of file isetattr.cpp.

00629 {
00630 #ifdef _DEBUG
00631     NodeAttribute::GetDebugDetails(Str);
00632 
00633     String_256 TempStr;
00634     TempStr._MakeMsg( _T("\r\nOverprint of Lines is #1%s\r\n"), (Value.IsOverprintOn()) ? _T("ON") : _T("OFF") );
00635     *Str += TempStr;
00636 #endif
00637 }

UINT32 AttrOverprintLine::GetNodeSize  )  const [virtual]
 

For finding the size of the node, in bytes.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
23/7/96
Returns:
The size of this node, in bytes

Reimplemented from Node.

Definition at line 654 of file isetattr.cpp.

00655 {
00656     return(sizeof(AttrOverprintLine));
00657 }

INT32 AttrOverprintLine::operator== const NodeAttribute NodeAttrib  )  [virtual]
 

Comparison operator - determines if the AttributeValues of both objects are ==.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
23/7/96
Parameters:
NodeAttrib - The node to compare this node to [INPUTS]
Returns:
TRUE if the nodes are considered equal

Reimplemented from NodeAttribute.

Definition at line 675 of file isetattr.cpp.

00676 {
00677     // First check they are of the same type
00678     if (((NodeAttribute*)&NodeAttrib)->GetAttributeType() != GetAttributeType())
00679         return FALSE;
00680 
00681     // Make a more sensible pointer
00682     AttrOverprintLine *Attr = (AttrOverprintLine *) &NodeAttrib;
00683 
00684     // Now let the AttributeValues compare themselves
00685     return( *((OverprintLineAttrValue *) Attr->GetAttributeValue())  ==
00686             *((OverprintLineAttrValue *) GetAttributeValue()) );
00687 }

Node * AttrOverprintLine::SimpleCopy void   )  [virtual]
 

This method returns a shallow copy of the node with all Node pointers NULL. The function is virtual, and must be defined for all derived classes.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
24/7/96
Returns:
A copy of the node, or NULL if memory runs out

Reimplemented from NodeAttribute.

Definition at line 578 of file isetattr.cpp.

00579 {
00580     AttrOverprintLine* NodeCopy = new AttrOverprintLine;
00581     if (NodeCopy == NULL)
00582         return(NULL);
00583 
00584     // Call the base class
00585     NodeAttribute::CopyNodeContents(NodeCopy);
00586 
00587     // And call our AttributeValue to copy itself too
00588     NodeCopy->GetAttributeValue()->SimpleCopy(GetAttributeValue());
00589     
00590     return(NodeCopy);
00591 }

BOOL AttrOverprintLine::WritePreChildrenNative BaseCamelotFilter pFilter  )  [virtual]
 

Reimplemented from Node.

Definition at line 731 of file isetattr.cpp.

00732 {
00733 #ifdef DO_EXPORT
00734     ERROR3IF(pFilter == NULL, "Illegal NULL param");
00735 
00736     CamelotFileRecord *Rec = NULL;
00737     if (Value.IsOverprintOn())
00738         Rec = new CamelotFileRecord(pFilter, TAG_OVERPRINTLINEON, TAG_OVERPRINTLINEON_SIZE);
00739     else
00740         Rec = new CamelotFileRecord(pFilter, TAG_OVERPRINTLINEOFF, TAG_OVERPRINTLINEOFF_SIZE);
00741 
00742     BOOL ok = (Rec != NULL);
00743 
00744     if (ok) ok = Rec->Init();
00745     if (ok) ok = pFilter->Write(Rec);
00746 
00747     if (!ok)
00748         pFilter->GotError(_R(IDE_FILE_WRITE_ERROR));
00749 
00750     if (Rec != NULL)        // We've written the record - now delete it
00751         delete Rec;
00752 
00753     return(ok);
00754 #else
00755     return FALSE;
00756 #endif
00757 }

BOOL AttrOverprintLine::WritePreChildrenWeb BaseCamelotFilter pFilter  )  [virtual]
 

Writes out a record that represents the node, to either Native or Web file format.

Author:
Jason_Williams (Xara Group Ltd) <camelotdev@xara.com>
Date:
26/7/96
Parameters:
pFilter - filter to write to [INPUTS]
Returns:
TRUE if the Node has written out a record to the filter
This function is called before any of the AttrOverprintLine's children are written to the filter.

If the AttrOverprintLine writes out a record successfully to the file, it will return TRUE.

If the AttrOverprintLine chooses not to write itself to the filter (e.g. because it is not appropriate for this filter), then this function will return FALSE.

See also:
Node::WritePreChildrenNative; Node::WritePreChildrenWeb; ImagesettingAttrRecordHandler::HandleRecord

Reimplemented from Node.

Definition at line 721 of file isetattr.cpp.

00722 {
00723 #ifdef DO_EXPORT
00724     // Imagesetting attributes are not saved in the web file format
00725     return FALSE;
00726 #else
00727     return FALSE;
00728 #endif
00729 }


Member Data Documentation

OverprintLineAttrValue AttrOverprintLine::Value
 

Definition at line 264 of file isetattr.h.


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