AttrTxtItalic Class Reference

AttrTxtFontTypeface specifies if text is italic or not. More...

#include <txtattr.h>

Inheritance diagram for AttrTxtItalic:

AttrTxtBase NodeAttribute NodeRenderable Node CCObject SimpleCCObject List of all members.

Public Member Functions

 AttrTxtItalic ()
 Default constructor for AttrTxtItalic class.
 AttrTxtItalic (Node *ContextNode, AttachNodeDirection Direction, BOOL Locked=FALSE, BOOL Mangled=FALSE, BOOL Marked=FALSE, BOOL Selected=FALSE)
 Creates a AttrTxtItalic Attribute.
void Render (RenderRegion *pRender)
 'Renders' a Line Width attribute.
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)
 A virtual comparison operator. See NodeAttribute::operator== for a description of why it's required.
virtual UINT32 GetAttrNameID (void)
 Returns back a string resource ID describing the attribute.
virtual AttrIndex GetAttributeIndex ()
void GetDebugDetails (StringBase *Str)
 Used for debugging purposes during developement. Override in your own class and output suitable debugging details.
virtual UINT32 GetNodeSize () const
 For finding the size of the node.
virtual AttributeValueGetAttributeValue ()
virtual void PolyCopyNodeContents (NodeRenderable *pNodeCopy)
 Polymorphically copies the contents of this node to another.
virtual BOOL WritePreChildrenWeb (BaseCamelotFilter *pFilter)
 Saves the text font italic attribute to the new file format filter.
virtual BOOL WritePreChildrenNative (BaseCamelotFilter *pFilter)

Public Attributes

TxtItalicAttribute Value

Private Member Functions

void CopyNodeContents (AttrTxtItalic *NodeCopy)
 This method copies the node's contents to the node pointed to by NodeCopy.

Detailed Description

AttrTxtFontTypeface specifies if text is italic or not.

Author:
Simon_Maneggio (Xara Group Ltd) <camelotdev@xara.com>
Date:
07/03/95

Definition at line 956 of file txtattr.h.


Constructor & Destructor Documentation

AttrTxtItalic::AttrTxtItalic  ) 
 

Default constructor for AttrTxtItalic class.

Author:
Simon_Maneggio (Xara Group Ltd) <camelotdev@xara.com>
Date:
13/03/95
Parameters:
- [INPUTS]
- [OUTPUTS]
Returns:
-

Errors: -

See also:
-

Definition at line 4437 of file txtattr.cpp.

04438 {
04439 }

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

Creates a AttrTxtItalic Attribute.

Author:
Simon_Maneggio (Xara Group Ltd) <camelotdev@xara.com>
Date:
13/03/95
Parameters:
- [INPUTS]
- [OUTPUTS]
Returns:
-

Errors: -

See also:
-

Definition at line 4412 of file txtattr.cpp.

04418              : AttrTxtBase(ContextNode, Direction, Locked, Mangled, Marked, Selected)  
04419 {                         
04420 } 


Member Function Documentation

void AttrTxtItalic::CopyNodeContents AttrTxtItalic NodeCopy  )  [private]
 

This method copies the node's contents to the node pointed to by NodeCopy.

Author:
Simon_Maneggio (Xara Group Ltd) <camelotdev@xara.com>
Date:
28/4/93
Parameters:
[INPUTS] 
A copy of this node [OUTPUTS]
Returns:
-

Errors: An assertion failure will occur if NodeCopy is NULL

Scope: protected

Definition at line 4559 of file txtattr.cpp.

04560 {
04561     // Let the base class do its bit
04562     AttrTxtBase::CopyNodeContents( NodeCopy );
04563     
04564     //Copy contents specific to derived class here
04565     NodeCopy->Value.ItalicOn = Value.ItalicOn;
04566 } 

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

Reimplemented from NodeAttribute.

Definition at line 978 of file txtattr.h.

00978 { return ATTR_TXTITALIC; }

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

Reimplemented from NodeAttribute.

Definition at line 986 of file txtattr.h.

00986 { return &Value; }

UINT32 AttrTxtItalic::GetAttrNameID void   )  [virtual]
 

Returns back a string resource ID describing the attribute.

Author:
Simon_Maneggio (Xara Group Ltd) <camelotdev@xara.com>
Date:
22/2/94
Parameters:
- [INPUTS]
- [OUTPUTS]
Returns:
Attribute description ID

Errors: -

See also:
-

Reimplemented from NodeAttribute.

Definition at line 4535 of file txtattr.cpp.

04536 {
04537     return (_R(IDS_ITALIC)); 
04538 }  

void AttrTxtItalic::GetDebugDetails StringBase Str  )  [virtual]
 

Used for debugging purposes during developement. Override in your own class and output suitable debugging details.

Author:
Mike_Kenny (Xara Group Ltd) <camelotdev@xara.com>
Date:
24/04/94
Parameters:
- [INPUTS]

Reimplemented from NodeRenderable.

Definition at line 4625 of file txtattr.cpp.

04626 {
04627     NodeAttribute::GetDebugDetails( Str );
04628 
04629     String_256 TempStr;
04630     TCHAR* p;
04631 
04632     (Value.ItalicOn) ? (p = _T("TRUE")) : (p = _T("FALSE"));
04633     TempStr._MakeMsg( TEXT("\r\nItalic=#1%s\r\n"), p);
04634     (*Str) += TempStr;
04635 }

UINT32 AttrTxtItalic::GetNodeSize  )  const [virtual]
 

For finding the size of the node.

Author:
Simon_Maneggio (Xara Group Ltd) <camelotdev@xara.com>
Date:
6/10/93
Parameters:
- [INPUTS]
- [OUTPUTS]
Returns:
The size of the node in bytes
See also:
Node::GetSubtreeSize

Reimplemented from Node.

Definition at line 4607 of file txtattr.cpp.

04608 {     
04609     return (sizeof(AttrTxtItalic)); 
04610 }

INT32 AttrTxtItalic::operator== const NodeAttribute Attrib  )  [virtual]
 

A virtual comparison operator. See NodeAttribute::operator== for a description of why it's required.

Author:
Simon_Maneggio (Xara Group Ltd) <camelotdev@xara.com>
Date:
13/03/95
Parameters:
Atrib,: The attribute to compare, which must be an AttrLineWidth [INPUTS]
- [OUTPUTS]
Returns:
-

Errors: An ENSURE failure will occur if Attrib does not have a AttrTxtItalic runtime class.

See also:
NodeAttribute::operator==

Reimplemented from NodeAttribute.

Definition at line 4510 of file txtattr.cpp.

04511 {
04512     ENSURE(Attrib.IsKindOf(CC_RUNTIME_CLASS(AttrTxtItalic)), 
04513         "Trying to compare two objects with different types"); 
04514     AttrTxtItalic* Attr = (AttrTxtItalic*) &Attrib;
04515     return (Attr->Value.ItalicOn == Value.ItalicOn); 
04516 } 

void AttrTxtItalic::PolyCopyNodeContents NodeRenderable pNodeCopy  )  [virtual]
 

Polymorphically copies the contents of this node to another.

Author:
Phil_Martin (Xara Group Ltd) <camelotdev@xara.com>
Date:
18/12/2003
Parameters:
- [OUTPUTS]
Returns:
Errors: An assertion failure will occur if NodeCopy is NULL Scope: protected

Reimplemented from NodeRenderable.

Definition at line 4581 of file txtattr.cpp.

04582 {
04583     ENSURE(pNodeCopy, "Trying to copy a node's contents into a NULL node");
04584     ENSURE(IS_A(pNodeCopy, AttrTxtItalic), "PolyCopyNodeContents given wrong dest node type");
04585 
04586     if (IS_A(pNodeCopy, AttrTxtItalic))
04587         CopyNodeContents((AttrTxtItalic*)pNodeCopy);
04588 }

void AttrTxtItalic::Render RenderRegion pRegion  )  [virtual]
 

'Renders' a Line Width attribute.

Author:
Simon_Maneggio (Xara Group Ltd) <camelotdev@xara.com>
Date:
13/03/95
Parameters:
- [INPUTS]
- [OUTPUTS]
Returns:
-

Errors: -

See also:
-

Reimplemented from NodeAttribute.

Definition at line 4457 of file txtattr.cpp.

04458 {
04459     pRegion->SetTxtItalic(&Value, FALSE);
04460 }

Node * AttrTxtItalic::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:
Simon_Maneggio (Xara Group Ltd) <camelotdev@xara.com>
Date:
13/03/95
Parameters:
- [INPUTS]
[OUTPUTS] 
Returns:
A copy of the node, or NULL if memory runs out

Errors: If memory runs out when trying to copy, then ERROR is called with an out of memory error and the function returns NULL.

Scope: protected

Reimplemented from NodeAttribute.

Definition at line 4483 of file txtattr.cpp.

04484 {
04485     AttrTxtItalic* NodeCopy = new AttrTxtItalic();
04486     ERRORIF(NodeCopy == NULL, _R(IDE_NOMORE_MEMORY), NULL); 
04487     CopyNodeContents(NodeCopy);
04488     return NodeCopy;
04489 } 

BOOL AttrTxtItalic::WritePreChildrenNative BaseCamelotFilter pFilter  )  [virtual]
 

Reimplemented from Node.

Definition at line 4661 of file txtattr.cpp.

04662 {
04663 #ifdef DO_EXPORT
04664     ERROR2IF(pFilter==NULL, FALSE, "Parameter pFilter == NULL.");
04665 
04666     return CXaraFileTxtItalic::WritePreChildrenNative(pFilter, this);
04667 #else
04668     return FALSE;
04669 #endif
04670 }

BOOL AttrTxtItalic::WritePreChildrenWeb BaseCamelotFilter pFilter  )  [virtual]
 

Saves the text font italic attribute to the new file format filter.

Author:
Andy_Hayward (Xara Group Ltd) <camelotdev@xara.com>
Date:
09/07/96
Parameters:
pFilter - new camelot filter to save to [INPUTS]
Returns:
TRUE if successful, FALSE otherwise

Reimplemented from Node.

Definition at line 4650 of file txtattr.cpp.

04651 {
04652 #ifdef DO_EXPORT
04653     ERROR2IF(pFilter==NULL, FALSE, "Parameter pFilter == NULL.");
04654 
04655     return CXaraFileTxtItalic::WritePreChildrenWeb(pFilter, this);
04656 #else
04657     return FALSE;
04658 #endif
04659 }


Member Data Documentation

TxtItalicAttribute AttrTxtItalic::Value
 

Definition at line 999 of file txtattr.h.


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