FillEffectAttribute Class Reference

Specifies the fill 'effect', i.e. how it passes from one colour to another. e.g. fade, rainbow, alternate rainbow. More...

#include <fillval.h>

Inheritance diagram for FillEffectAttribute:

AttributeValue CCObject SimpleCCObject FillEffectAltRainbowAttribute FillEffectFadeAttribute FillEffectRainbowAttribute List of all members.

Public Member Functions

virtual void Restore (RenderRegion *, BOOL)
 Restores the fill type attribute for the given render region. i.e. all paths filled will now be filled with this fill attribute.
virtual void Render (RenderRegion *, BOOL Temp=FALSE)
 Sets the fill type attribute for the given render region. i.e. all paths filled will now be filled with this fill attribute.
virtual void SimpleCopy (AttributeValue *)
 See AttributeValue::SimpleCopy.
virtual BOOL IsDifferent (AttributeValue *)
 See AttributeValue::IsDifferent.
virtual FillEffectAttributeoperator= (FillEffectAttribute &Attrib)
 Make this effect the same as another.
virtual INT32 operator== (const FillEffectAttribute &Attrib)
 See if two effects are the same.

Static Public Member Functions

static BOOL Init ()
 Registers fill effect attribute, and provides a default attribute to give standard RGB fade between two colours.

Detailed Description

Specifies the fill 'effect', i.e. how it passes from one colour to another. e.g. fade, rainbow, alternate rainbow.

Author:
Tim_Browse (Xara Group Ltd) <camelotdev@xara.com>
Date:
18/07/94
See also:
AttributeValue

Definition at line 1695 of file fillval.h.


Member Function Documentation

BOOL FillEffectAttribute::Init void   )  [static]
 

Registers fill effect attribute, and provides a default attribute to give standard RGB fade between two colours.

Author:
Will_Cowling (Xara Group Ltd) <camelotdev@xara.com>
Date:
23/8/94
Returns:
TRUE - initialised ok; FALSE if not.

Errors: Out of memory.

See also:
AttributeManager

Reimplemented from SimpleCCObject.

Definition at line 8131 of file fillval.cpp.

08132 {
08133     // Default to simple RGB fade effect (ignored for flat fills, obviously)
08134     FillEffectAttribute *pAttr = new FillEffectFadeAttribute;
08135     if (pAttr==NULL)
08136         // error message has already been set by new
08137         return FALSE;
08138 
08139     UINT32 ID = AttributeManager::RegisterDefaultAttribute(CC_RUNTIME_CLASS(NodeRenderableInk), 
08140                                                          pAttr);
08141 
08142     ERROR2IF(ID == ATTR_BAD_ID, FALSE, "Bad ID when Initialising FillEffectAttribute");
08143     ERROR2IF(ID != ATTR_FILLEFFECT, FALSE, "Incorrect ID for FillEffectAttribute");
08144 
08145     return TRUE;
08146 }

BOOL FillEffectAttribute::IsDifferent AttributeValue pVal  )  [virtual]
 

See AttributeValue::IsDifferent.

Author:
Will_Cowling (Xara Group Ltd) <camelotdev@xara.com>
Date:
8/6/95
Parameters:
pVal - pointer to the AttributeValue to copy. [INPUTS]

Reimplemented from AttributeValue.

Definition at line 8216 of file fillval.cpp.

08217 {
08218     return (pVal->GetRuntimeClass() != GetRuntimeClass());
08219 }

FillEffectAttribute & FillEffectAttribute::operator= FillEffectAttribute Attrib  )  [virtual]
 

Make this effect the same as another.

Author:
Will_Cowling (Xara Group Ltd) <camelotdev@xara.com>
Date:
8/6/95
Parameters:
Attrib - the AttributeValue to copy. [INPUTS]

Definition at line 8232 of file fillval.cpp.

08233 {
08234     return (*this);
08235 }

INT32 FillEffectAttribute::operator== const FillEffectAttribute Attrib  )  [virtual]
 

See if two effects are the same.

Author:
Will_Cowling (Xara Group Ltd) <camelotdev@xara.com>
Date:
8/6/95
Parameters:
Attrib - The AttributeValue to test. [INPUTS]

Definition at line 8248 of file fillval.cpp.

08249 {
08250     return (Attrib.GetRuntimeClass() == GetRuntimeClass());
08251 }

void FillEffectAttribute::Render RenderRegion pRegion,
BOOL  Temp = FALSE
[virtual]
 

Sets the fill type attribute for the given render region. i.e. all paths filled will now be filled with this fill attribute.

Author:
Will_Cowling (Xara Group Ltd) <camelotdev@xara.com>
Date:
23/8/94
Parameters:
pRegion - the render region to render this attribute into. [INPUTS]
See also:
FillEffectAttribute; RenderStack; AttributeValue; NodeAttribute; FillEffectAttribute::Restore; AttributeValue::Render; AttributeValue::Restore; AttributeValue::SimpleCopy

Implements AttributeValue.

Definition at line 8163 of file fillval.cpp.

08164 {
08165     pRegion->SetFillEffect(this, Temp);
08166 }

void FillEffectAttribute::Restore RenderRegion pRegion,
BOOL  Temp
[virtual]
 

Restores the fill type attribute for the given render region. i.e. all paths filled will now be filled with this fill attribute.

Author:
Will_Cowling (Xara Group Ltd) <camelotdev@xara.com>
Date:
23/8/94
Parameters:
pRegion - the render region to restore the attribute into. [INPUTS] Temp - TRUE if this is a temporary attribute, FALSE if it is permanent (e.g. it's in a document tree).
See also:
FillEffectAttribute; RenderStack; AttributeValue; NodeAttribute; FillEffectAttribute::Render; AttributeValue::Render; AttributeValue::Restore; AttributeValue::SimpleCopy

Implements AttributeValue.

Definition at line 8185 of file fillval.cpp.

08186 {
08187     pRegion->RestoreFillEffect(this, Temp);
08188 }

void FillEffectAttribute::SimpleCopy AttributeValue pVal  )  [virtual]
 

See AttributeValue::SimpleCopy.

Author:
Will_Cowling (Xara Group Ltd) <camelotdev@xara.com>
Date:
8/6/95
Parameters:
pVal - pointer to the AttributeValue to copy. [INPUTS]

Implements AttributeValue.

Definition at line 8201 of file fillval.cpp.

08202 {
08203 }


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