wxArt2D
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members

Clipping Path property that can be added to a2dCanvasObject's. More...

#include <canprop.h>

Inheritance diagram for a2dClipPathProperty:
Inheritance graph
[legend]
Collaboration diagram for a2dClipPathProperty:
Collaboration graph
[legend]

Public Member Functions

 a2dClipPathProperty (const a2dPropertyIdCanvasClipPath *id, a2dPolygonL *clip)
 
 a2dClipPathProperty (const a2dClipPathProperty &other, a2dObject::CloneOptions options)
 
void Assign (const a2dNamedProperty &other)
 Virtual assignment operator.
 
virtual a2dPolygonLGetClipObject () const
 return a2dPolygonL that is used for clipping
 
void SetCanvasObject (a2dPolygonL *clip)
 set object to use for clipping
 
void PushClip (a2dDrawingPart *drawer, a2dBooleanClip clipoperation=a2dCLIP_AND)
 
void PopClip (a2dDrawingPart *drawer)
 
virtual void SetVisible (bool visible)
 the object is visible or not. More...
 
virtual bool GetVisible () const
 return true if the object is visible.
 
void SetCanRender (bool render)
 if object can be rendered or not. More...
 
bool GetCanRender () const
 return true if the object can be rendered.
 
virtual a2dObjectGetRefObject () const
 when a2dProperty, return its value else assert
 
virtual a2dObjectGetRefObjectNA () const
 when a2dProperty, return its value else return NULL
 
- Public Member Functions inherited from a2dNamedProperty
 a2dNamedProperty ()
 Default constructor.
 
 a2dNamedProperty (const a2dPropertyId *id)
 Constructor giving an id.
 
 a2dNamedProperty (const a2dNamedProperty &other)
 Copy constructor.
 
a2dNamedPropertyClone (a2dObject::CloneOptions options, a2dRefMap *refs=NULL) const
 Virtual copy constructor.
 
virtual ~a2dNamedProperty ()
 Destructor.
 
void SetCheck (bool check)
 general flag use at will. More...
 
bool GetCheck () const
 general flag use at will.
 
void SetToObject (a2dObject *obj, a2dPropertyId::SetFlags setflags=a2dPropertyId::set_none)
 Set this property to an object. More...
 
void SetToObjectClone (a2dObject *obj, a2dPropertyId::SetFlags setflags=a2dPropertyId::set_none) const
 Set this property to an object and clone it if neccessary. More...
 
const a2dPropertyIdGetId () const
 Get the a2dPropertyId object identifying this property.
 
virtual const a2dPropertyIdCreateId (a2dObject *parent, const wxString &name)
 creates an a2dPropertyId for this property, if it is not available.
 
wxString GetName () const
 Get the name of the a2dPropertyId object.
 
virtual wxString GetString () const
 when a2dStringProperty, return its value else assert
 
virtual double GetDouble () const
 when a2dDoubleProperty, return its value else assert
 
virtual float GetFloat () const
 when a2dFloatProperty, return its value else assert
 
virtual bool GetBool () const
 when a2dBoolProperty, return its value else assert
 
virtual wxInt16 GetInt16 () const
 when a2dInt16Property, return its value else assert
 
virtual wxUint16 GetUint16 () const
 when a2dUint16Property, return its value else assert
 
virtual wxInt32 GetInt32 () const
 when a2dInt32Property, return its value else assert
 
virtual wxUint32 GetUint32 () const
 when a2dUint32Property, return its value else assert
 
virtual void * GetVoidPtr () const
 when a2dVoidPtrProperty, return its value else assert
 
virtual wxString StringRepresentation () const
 
virtual wxString StringValueRepresentation () const
 
double ParseDouble (unsigned int &position)
 parse a double from the value string
 
void SkipCommaSpaces (unsigned int &position)
 parse comma, whitespace and skip it form teh value string
 
void SkipSpaces (unsigned int &position)
 parse whitespace and skip it form teh value string
 
void Walker (wxObject *parent, a2dWalkerIOHandler &handler)
 This is used to recursively walk through an object tree.
 
virtual void Save (wxObject *parent, a2dIOHandlerXmlSerOut &out, a2dObjectList *towrite)
 
virtual void Load (wxObject *parent, a2dIOHandlerXmlSerIn &parser)
 

Protected Member Functions

virtual a2dNamedPropertyDoClone (a2dObject::CloneOptions options, a2dRefMap *refs) const
 
void DoWalker (wxObject *parent, a2dWalkerIOHandler &handler)
 
void DoRender (a2dIterC &ic, a2dAffineMatrix *cworld, OVERLAP clipparent, int layer, a2dCanvasObjectFlagsMask mask)
 
virtual void DoSave (wxObject *parent, a2dIOHandlerXmlSerOut &out, a2dXmlSer_flag xmlparts, a2dObjectList *towrite)
 
virtual void DoLoad (wxObject *parent, a2dIOHandlerXmlSerIn &parser, a2dXmlSer_flag xmlparts)
 

Protected Attributes

a2dSmrtPtr< a2dPolygonLm_clip
 
bool m_visible
 see SetVisible()
 
bool m_render
 in case of a grahics application, should this property be rendered.
 
- Protected Attributes inherited from a2dNamedProperty
const a2dPropertyIdm_id
 The property id object identifying this property.
 

Detailed Description

Clipping Path property that can be added to a2dCanvasObject's.

Used during rendering to set a clipping path on a a2dCanvasObject. Everything outside the area defined by the clipping polygon is not drawn.

Remarks
Currently only clipping object of type a2dPolygonL is supported.
the clipping object itself can also be rendered by adding it to the children of the object being clipped. Like any Object it has to be set visible to see it.

Definition at line 322 of file canprop.h.

Member Function Documentation

void a2dClipPathProperty::SetCanRender ( bool  render)
inline

if object can be rendered or not.

some properties have a reference to a a2dCanvasObject, but only to store it, not to render it as part of the object.

Definition at line 358 of file canprop.h.

virtual void a2dClipPathProperty::SetVisible ( bool  visible)
inlinevirtual

the object is visible or not.

If a object is visible and it has a a2dObject internal, that object will rendered. A wxDocviewVisibleProperty uses this flag to make a object visible or not.

Definition at line 350 of file canprop.h.


The documentation for this class was generated from the following files:
a2dClipPathProperty Class Reference -- Sun Oct 12 2014 17:04:31 -- Sun Oct 12 2014 -- 1.8.5 -- wxArt2D -- . -- Main Page Reference Documentation