wxArt2D
canprop.h
Go to the documentation of this file.
1 /*! \file wx/canvas/canprop.h
2  \brief properties specific for a2dCanvasOject
3  \author Klaas Holwerda
4 
5  Copyright: 2001-2004 (c) Klaas Holwerda
6 
7  Licence: wxWidgets Licence
8 
9  RCS-ID: $Id: canprop.h,v 1.20 2008/10/21 21:48:30 titato Exp $
10 */
11 
12 #ifndef __WXCANPROP_H__
13 #define __WXCANPROP_H__
14 
15 #ifndef WX_PRECOMP
16 #include "wx/wx.h"
17 #endif
18 
19 #include "wx/canvas/candefs.h"
20 #include "wx/canvas/layerinf.h"
21 #include "wx/canvas/canobj.h"
22 #include "wx/canvas/canprim.h"
23 #include "wx/canvas/cantext.h"
24 #include "wx/canvas/polygon.h"
25 
26 class A2DCANVASDLLEXP a2dDrawingPart;
27 
28 //!Invisible Style property that can be added to Canvas Objects.
29 /*!
30  Rendering is not done on this object.
31  All style like object like a2dStroke and a2dFill
32  are added to a2dCanvasObjects with this property.
33 
34  Fill Colour being the foreground color if filling with a monochrome bitmap
35  and fill style is a2dFILL_STIPPLE_MASK_OPAQUE.
36  Or in case of gradient filling the beginning colour for the fill
37 
38  You get transparent bitmap filling when bitmap fill is monochrome and fill style is
39  a2dFILL_STIPPLE_MASK_OPAQUE_TRANSPARENT.
40  The fill colour will be used for non Transparent parts in the fill bitmap,
41  while other parts will be transparent.
42 
43  colour2 being the background color if filling with a monochrome bitmap
44  and fill style is a2dFILL_STIPPLE_MASK_OPAQUE.
45  Or in case of gradient filling the ending colour for the fill.
46 
47  \remark Fill Second color, used for Text, transparent filling and gradient filling.
48 
49  \remark style is inhereted from parent object.
50 
51  \remark an object may have style but is free to use it or not.
52 
53  \ingroup property style
54 */
55 class A2DCANVASDLLEXP a2dStyleProperty: public a2dNamedProperty
56 {
57 public:
58 
60 
61  a2dStyleProperty( const a2dPropertyId* id );
62 
63  a2dStyleProperty( const a2dStyleProperty& other );
64 
65  virtual ~a2dStyleProperty();
66 
68 
69  virtual void Assign( const a2dNamedProperty& other );
70 
71  //!if IsNoStroke() and IsNoFill() return true
72  bool AllNo();
73 
74  //!Set a fill for the object which will be used instead of the layer fill
75  //! returns a2dNullFILL set if no fill is used in which case the layer fill is used for filling
76  inline const a2dFill& GetFill() const { return m_fill; }
77 
78  //!Set a stroke for the object which will be used instead of the layer stroke
79  //! returns a2dBLACK_STROKE with IsNoStroke() set, if no stroke is used in which case the layer fill is used for stroking
80  inline const a2dStroke& GetStroke() const { return m_stroke; }
81 
82  //!Set a fill for the object which will be used instead of the layer fill
83  /*!
84  The fill is for filling the a2dCanvasObject.
85  Use IsNoFill() to remove the fill from a a2dCanvasObject.
86  Use a2dTRANSPARENT_FILL to not fill the object.
87  \remark m_flags.m_filled flag overrules the fill to fill TRANSPARENT
88  */
89  void SetFill( const a2dFill& fill );
90 
91  //!Set a fill color for the object which will be used instead of the layer fill
92  /*!
93  \param fillcolor color to fill a2dCanvasObject with
94  \param style style for one colour fill
95  \remark creates a a2dOneColourFill internal
96  \sa a2dOneColourFill
97  */
98  void SetFill( const wxColour& fillcolor, a2dFillStyle style = a2dFILL_SOLID );
99 
100  //!Set a fill color for the object which will be used instead of the layer fill
101  /*!
102  \param fillcolor color to fill a2dCanvasObject with
103  \param fillcolor2 color to fill a2dCanvasObject with
104  \param style style for one colour fill
105  \remark creates a a2dTwoColourFill internal
106  \sa a2dTwoColourFill
107  */
108  void SetFill( const wxColour& fillcolor, const wxColour& fillcolor2, a2dFillStyle style = a2dFILL_SOLID );
109 
110  //!Set a stroke for the object which will be used instead of the layer stroke
111  void SetStroke( const wxColour& strokecolor, float width = 0, a2dStrokeStyle style = a2dSTROKE_SOLID );
112 
113  //!Set a stroke for the object which will be used instead of the layer stroke
114  void SetStroke( const wxColour& strokecolor, int width , a2dStrokeStyle style = a2dSTROKE_SOLID );
115 
116  /*!
117  The stroke is for drawing outlines of the a2dCanvasObject.
118  Use NoStroke() to remove the stroke from a a2dCanvasObject.
119  Use a2dTRANSPARENT_STROKE to not fill the object.
120  */
121  void SetStroke( const a2dStroke& stroke );
122 
123  wxString StringRepresentation() const;
124  wxString StringValueRepresentation() const;
125 
126  DECLARE_DYNAMIC_CLASS( a2dStyleProperty )
127 
128 protected:
129 
130 #if wxART2D_USE_CVGIO
131  virtual void DoSave( wxObject* parent, a2dIOHandlerXmlSerOut& out, a2dXmlSer_flag xmlparts , a2dObjectList* towrite );
132  virtual void DoLoad( wxObject* parent, a2dIOHandlerXmlSerIn& parser, a2dXmlSer_flag xmlparts );
133 #endif //wxART2D_USE_CVGIO
134 
135  //!stroke used for outline of object.
136  //! a2dNullSTROKE when no stroke
138 
139  //!fill used for filling of object.
140  //!If m_filled object is false the object will not be filled.
141  //! a2dNullFILL when no fill
143 
144 private:
145 
146  virtual a2dNamedProperty* DoClone( a2dObject::CloneOptions options, a2dRefMap* refs ) const { return new a2dStyleProperty( *this ); }
147 };
148 
149 //! Creates a shadow behind a a2dCanvasObject when added as property.
150 /*! When this property is added to a a2dCanvasObject, that object is rendered
151 twice. The first time as a shadow behind the real shape.
152 Angle and Depth can be set for the Shadow.
153 The Shadow its style (colour etc.) is the style of the baseclass a2dStyleProperty.
154 
155  \ingroup property style
156 */
157 class A2DCANVASDLLEXP a2dShadowStyleProperty: public a2dStyleProperty
158 {
159 public:
160 
162 
163  a2dShadowStyleProperty( const a2dPropertyIdCanvasShadowStyle* id, double depth, double angle = 30 );
164 
166 
167  virtual ~a2dShadowStyleProperty();
168 
169  a2dNamedProperty* Clone( a2dObject::CloneOptions options ) const;
170 
171  double GetExtrudeDepth() const { return m_depth; }
172 
173  double GetExtrudeAngle() const { return m_angle3d; }
174 
175  void SetExtrudeDepth( double depth ) { m_depth = depth; }
176  void SetExtrudeAngle( double angle3d ) { m_angle3d = wxDegToRad( angle3d ); }
177 
178  DECLARE_DYNAMIC_CLASS( a2dShadowStyleProperty )
179 
180 protected:
181 
182 #if wxART2D_USE_CVGIO
183  virtual void DoSave( wxObject* parent, a2dIOHandlerXmlSerOut& out, a2dXmlSer_flag xmlparts , a2dObjectList* towrite );
184  virtual void DoLoad( wxObject* parent, a2dIOHandlerXmlSerIn& parser, a2dXmlSer_flag xmlparts );
185 #endif //wxART2D_USE_CVGIO
186 
187  double m_depth;
188  double m_angle3d;
189 
190 private:
191 
192  virtual a2dNamedProperty* DoClone( a2dObject::CloneOptions options, a2dRefMap* refs ) const { return new a2dShadowStyleProperty( *this ); }
193 
194 };
195 
196 //! property to hold a a2dCanvasObject pointer type variable to be associated with a canvasobject
197 /*!
198 
199  \ingroup property
200 
201 */
202 class A2DCANVASDLLEXP a2dCanvasObjectPtrProperty: public a2dNamedProperty
203 {
204 public:
205 
207 
208  a2dCanvasObjectPtrProperty( const a2dPropertyIdCanvasObject* id, a2dCanvasObject* object, bool visible = false, bool render = false );
209 
211 
212  virtual ~a2dCanvasObjectPtrProperty();
213 
214  virtual void Assign( const a2dNamedProperty& other );
215 
216  //! to set the a2dCanvasObject*
217  void SetObject( wxObject* object );
218 
219  inline a2dCanvasObject* GetCanvasObject() const { return m_object; }
220 
221  //! to get the a2dCanvasObject*
222  virtual a2dObject* GetRefObject() const { return m_object; }
223  virtual a2dObject* GetRefObjectNA() const { return m_object; }
224 
225  DECLARE_DYNAMIC_CLASS( a2dCanvasObjectPtrProperty )
226 
227  //! the object is visible or not.
228  /*! If a object is visible and it has a a2dObject internal,
229  that object will rendered.
230  A wxDocviewVisibleProperty uses this flag to make a object visible or not.
231  */
232  virtual void SetVisible( bool visible ) { m_visible = visible; }
233  //! return true if the object is visible.
234  virtual bool GetVisible() const { return m_visible; }
235 
236  //! if object can be rendered or not.
237  /*! some properties have a reference to a a2dCanvasObject, but only to store it,
238  not to render it as part of the object.
239  */
240  void SetCanRender( bool render ) { m_render = render; }
241  //! return true if the object can be rendered.
242  bool GetCanRender() const { return m_render; }
243 
244  //! is set true, the object within this property will be rendered before its parent a2dCanvasObject
245  /*!
246  \param prerender if true render m_object before its parent a2dCanvasObject, default false.
247  */
248  void SetPreRender( bool prerender ) { m_prerender = prerender; }
249 
250  //! returns the current prerender setting.
251  bool GetPreRender() const { return m_prerender; }
252 
253  //! is set true, the object will only be rendered, if the owning object is selected
254  /*!
255  \param selectedonly if true, the object will only be rendered, if the owning object is selected
256  */
257  void SetSelectedOnly( bool selectedonly ) { m_selectedonly = selectedonly; }
258 
259  //! returns the current only selected setting.
260  bool GetSelectedOnly() const { return m_selectedonly; }
261 
262  //! Get property value
263  a2dCanvasObject* GetValue() const { return m_object; }
264 
265  //! Set property value
266  void SetValue( a2dCanvasObject* newvalue ) { m_object = newvalue; }
267 
268  a2dCanvasObjectPtr* GetValuePtr() { return &m_object; }
269 
270  a2dCanvasObjectPtr& GetValueRef() { return m_object; }
271 
272  const a2dCanvasObjectPtr* GetValuePtr() const { return &m_object; }
273 
274  const a2dCanvasObjectPtr& GetValueRef() const { return m_object; }
275 
276  //! Construct a new property object from a string
277  //! If this is not appropriate, this may return NULL
278  static a2dCanvasObjectPtrProperty* CreatePropertyFromString( const a2dPropertyIdCanvasObject* id, const wxString& value );
279 
280 protected:
281 
282  virtual a2dNamedProperty* DoClone( a2dObject::CloneOptions options, a2dRefMap* refs ) const;
283  void DoWalker( wxObject* parent, a2dWalkerIOHandler& handler );
284 
285 #if wxART2D_USE_CVGIO
286  virtual void DoSave( wxObject* parent, a2dIOHandlerXmlSerOut& out, a2dXmlSer_flag xmlparts , a2dObjectList* towrite );
287  virtual void DoLoad( wxObject* parent, a2dIOHandlerXmlSerIn& parser, a2dXmlSer_flag xmlparts );
288 #endif //wxART2D_USE_CVGIO
289 
290  //! \see SetPreRender()
292  //! \see SetSelectedOnly()
294  //! see SetVisible()
295  bool m_visible;
296  //! in case of a grahics application, should this property be rendered.
297  bool m_render;
298 
299  //! when loading a document, this is used to resolve references to objects
300  wxUint32 m_resolveid;
301 
302  //! object held by this property.
304 };
305 
306 #if defined(WXART2D_USINGDLL)
307 template class A2DCANVASDLLEXP a2dPropertyIdProp<class a2dClipPathProperty>;
308 #endif
309 typedef a2dPropertyIdProp<class a2dClipPathProperty> a2dPropertyIdCanvasClipPath;
310 
311 //!Clipping Path property that can be added to a2dCanvasObject's.
312 /*!Used during rendering to set a clipping path on a a2dCanvasObject.
313  Everything outside the area defined by the clipping polygon is not drawn.
314 
315  \remark Currently only clipping object of type a2dPolygonL is supported.
316 
317  \remark the clipping object itself can also be rendered by adding it to the children of
318  the object being clipped. Like any Object it has to be set visible to see it.
319 
320  \ingroup property style
321 */
322 class A2DCANVASDLLEXP a2dClipPathProperty: public a2dNamedProperty
323 {
324 public:
325 
327 
328  a2dClipPathProperty( const a2dPropertyIdCanvasClipPath* id, a2dPolygonL* clip );
329 
331 
332  virtual ~a2dClipPathProperty();
333 
334  void Assign( const a2dNamedProperty& other );
335 
336  //! return a2dPolygonL that is used for clipping
337  virtual a2dPolygonL* GetClipObject() const { return m_clip; }
338 
339  //! set object to use for clipping
340  void SetCanvasObject( a2dPolygonL* clip );
341 
342  void PushClip( a2dDrawingPart* drawer, a2dBooleanClip clipoperation = a2dCLIP_AND );
343  void PopClip( a2dDrawingPart* drawer );
344 
345  //! the object is visible or not.
346  /*! If a object is visible and it has a a2dObject internal,
347  that object will rendered.
348  A wxDocviewVisibleProperty uses this flag to make a object visible or not.
349  */
350  virtual void SetVisible( bool visible ) { m_visible = visible; }
351  //! return true if the object is visible.
352  virtual bool GetVisible() const { return m_visible; }
353 
354  //! if object can be rendered or not.
355  /*! some properties have a reference to a a2dCanvasObject, but only to store it,
356  not to render it as part of the object.
357  */
358  void SetCanRender( bool render ) { m_render = render; }
359  //! return true if the object can be rendered.
360  bool GetCanRender() const { return m_render; }
361 
362  DECLARE_DYNAMIC_CLASS( a2dClipPathProperty )
363 
364  virtual a2dObject* GetRefObject() const;
365  virtual a2dObject* GetRefObjectNA() const;
366 
367 protected:
368 
369  virtual a2dNamedProperty* DoClone( a2dObject::CloneOptions options, a2dRefMap* refs ) const;
370  void DoWalker( wxObject* parent, a2dWalkerIOHandler& handler );
371 
372  void DoRender( a2dIterC& ic, a2dAffineMatrix* cworld, OVERLAP clipparent, int layer , a2dCanvasObjectFlagsMask mask );
373 
374 #if wxART2D_USE_CVGIO
375  virtual void DoSave( wxObject* parent, a2dIOHandlerXmlSerOut& out, a2dXmlSer_flag xmlparts , a2dObjectList* towrite );
376  virtual void DoLoad( wxObject* parent, a2dIOHandlerXmlSerIn& parser, a2dXmlSer_flag xmlparts );
377 #endif //wxART2D_USE_CVGIO
378 
380  //! see SetVisible()
381  bool m_visible;
382  //! in case of a grahics application, should this property be rendered.
383  bool m_render;
384 };
385 
386 //!(In)Visible property that can be added to Canvas Objects.
387 /*!
388  This a2dCanvasObject makes it possible to display and edit properties, which are normally
389  not visible as part of a a2dCanvasObject its propertylist.
390  It has a a2dPropertyId member which points to a unique propertyID in a a2dCanvasObject.
391  Normally this object is added as a child to the same a2dCanvasObject which contains the property.
392 
393  Rendering is done using a2dText object internal, and the text is taken from the property as
394  its GetName() + " = " + StringValueRepresentation();
395 */
396 class A2DCANVASDLLEXP a2dVisibleProperty: public a2dText
397 {
398  DECLARE_EVENT_TABLE()
399 
400 public:
401 
402  //! constructor
404 
405  //! constructor copy
406  a2dVisibleProperty( const a2dVisibleProperty& other, CloneOptions options, a2dRefMap* refs );
407 
408  //! constructor to set prop at x,y and angle
409  a2dVisibleProperty( a2dCanvasObject* parent, const a2dPropertyId* property, double x, double y, double angle = 0 );
410 
411  //! constructor to set font and visibility also.
412  a2dVisibleProperty( a2dCanvasObject* parent, const a2dPropertyId* property, double x, double y, bool visible = true,
413  const a2dFont& font = *a2dDEFAULT_CANVASFONT, double angle = 0 );
414 
415  virtual ~a2dVisibleProperty();
416 
417  //! Show both name and value of the property or just the value.
418  void ShowName( bool show = false );
419 
420  //! to set the parent where the m_propId is searched for.
421  void SetParent( a2dCanvasObject* parent );
422 
423  //! to get the parent where the m_propId is searched for.
424  inline a2dCanvasObject* GetParent( void ) const { return m_parent; }
425 
426  //! get the id of the property displayed by this object
427  inline const a2dPropertyId* GetPropId() { return m_propId; }
428 
429 #if wxART2D_USE_CVGIO
430  virtual void DoSave( wxObject* parent, a2dIOHandlerXmlSerOut& out, a2dXmlSer_flag xmlparts , a2dObjectList* towrite );
431 
432  virtual void DoLoad( wxObject* parent, a2dIOHandlerXmlSerIn& parser, a2dXmlSer_flag xmlparts );
433 #endif //wxART2D_USE_CVGIO
434 
435  void OnChar( wxKeyEvent& event );
436 
437  void OnMouseEvent( a2dCanvasObjectMouseEvent& event );
438 
439  void OnPropertyChanged( a2dComEvent& event );
440 
441  DECLARE_DYNAMIC_CLASS( a2dVisibleProperty );
442 
443 protected:
444 
445  virtual a2dObject* DoClone( CloneOptions options, a2dRefMap* refs ) const;
446 
447  void DoEndEdit();
448 
449  virtual bool DoUpdate( UpdateMode mode, const a2dBoundingBox& childbox, const a2dBoundingBox& clipbox, const a2dBoundingBox& propbox );
450 
451  //! object which contains m_propId
453 
454  //! the property id for which the value needs to be displayed.
456 
457  //! Indicates if both name and value of the property are visible, or just the value.
459 
460 private:
461  //!this is a not implemented copy constructor that avoids automatic creation of one
462  a2dVisibleProperty( const a2dVisibleProperty& other );
463 };
464 
465 
466 //! property to hold a a2dBoundingBox type variable to be associated with a canvasobject
467 /*!
468  \ingroup property
469 */
470 class A2DCANVASDLLEXP a2dBoudingBoxProperty: public a2dNamedProperty
471 {
472 public:
473 
475 
477 
478  a2dBoudingBoxProperty( const a2dPropertyIdBoundingBox* id, const wxString& value );
479 
481 
482  virtual void Assign( const a2dNamedProperty& other );
483 
484  virtual ~a2dBoudingBoxProperty();
485 
486  //! Construct a new property object from a string
487  //! If this is not appropriate, this may return NULL
488  static a2dBoudingBoxProperty* CreatePropertyFromString( const a2dPropertyIdBoundingBox* id, const wxString& value );
489 
490  void SetValue( const a2dBoundingBox& value );
491 
492  a2dBoundingBox& GetValue() { return m_value; }
493 
494  a2dBoundingBox* GetValuePtr() { return &m_value; }
495 
496  const a2dBoundingBox& GetValue() const { return m_value; }
497 
498  const a2dBoundingBox* GetValuePtr() const { return &m_value; }
499 
500  virtual wxString StringRepresentation() const;
501 
502  virtual wxString StringValueRepresentation() const;
503 
504 #if wxART2D_USE_CVGIO
505  virtual void DoSave( wxObject* parent, a2dIOHandlerXmlSerOut& out, a2dXmlSer_flag xmlparts , a2dObjectList* towrite );
506  virtual void DoLoad( wxObject* parent, a2dIOHandlerXmlSerIn& parser, a2dXmlSer_flag xmlparts );
507 #endif //wxART2D_USE_CVGIO
508 
509  DECLARE_DYNAMIC_CLASS( a2dBoudingBoxProperty )
510 
511 protected:
512 
513  a2dBoundingBox m_value;
514 
515 private:
516  virtual a2dNamedProperty* DoClone( a2dObject::CloneOptions options, a2dRefMap* refs ) const;
517 };
518 
519 //! Generate new tag for grouping
520 A2DCANVASDLLEXP a2dTag a2dNewTag();
521 
522 //! property to hold a byte integer type vector to be associated with a a2dObject
523 /*!
524  \ingroup property
525 */
526 class A2DCANVASDLLEXP a2dTagVecProperty: public a2dNamedProperty
527 {
528 public:
529 
531 
532  a2dTagVecProperty( const a2dPropertyIdTagVec* id, a2dTagVec value );
533 
534  a2dTagVecProperty( const a2dTagVecProperty& other );
535 
536  virtual void Assign( const a2dNamedProperty& other );
537 
538  virtual ~a2dTagVecProperty();
539 
540  //! Construct a new property object from a string
541  //! If this is not appropriate, this may return NULL
542  static a2dTagVecProperty* CreatePropertyFromString( const a2dPropertyIdTagVec* id, const wxString& value );
543 
544  void SetValue( a2dTagVec value );
545 
546  a2dTagVec GetValue() const { return m_value; }
547 
548  a2dTagVec* GetValuePtr() { return &m_value; }
549 
550  a2dTagVec& GetValueRef() { return m_value; }
551 
552  virtual wxString StringRepresentation() const;
553 
554  virtual wxString StringValueRepresentation() const;
555 
556  void PushTag( a2dTag tag );
557 
558  a2dTag PopTag();
559 
560  a2dTag Last() const;
561 
562 #if wxART2D_USE_CVGIO
563  virtual void DoSave( wxObject* parent, a2dIOHandlerXmlSerOut& out, a2dXmlSer_flag xmlparts , a2dObjectList* towrite );
564  virtual void DoLoad( wxObject* parent, a2dIOHandlerXmlSerIn& parser, a2dXmlSer_flag xmlparts );
565 #endif //wxART2D_USE_CVGIO
566 
567  DECLARE_DYNAMIC_CLASS( a2dTagVecProperty )
568 
569 protected:
570 
571  a2dTagVec m_value;
572 
573 private:
574  virtual a2dNamedProperty* DoClone( a2dObject::CloneOptions options, a2dRefMap* refs ) const;
575 };
576 
577 
578 #endif
579 
580 
Display Part of a a2dDrawing, in which a2dCanvasObjects are shown.
Definition: drawer.h:470
virtual void Assign(const a2dNamedProperty &other)=0
Virtual assignment operator.
a2dText derived from a2dCanvasObject, holds multiline text
(In) Visible property that can be added to Docview Objects.
Definition: gen.h:1785
a2dCanvasObject * m_parent
object which contains m_propId
Definition: canprop.h:452
all basic primitives derived from a2dCanvasObject
Base class for all types of strokes, understood by a2dDrawer2D classes.
Definition: stylebase.h:378
mouse event sent from a2dCanvasObject to itself
Definition: canglob.h:223
class to map references to objects stored in XML, in order to make the connection later on...
Definition: gen.h:3462
Creates a shadow behind a a2dCanvasObject when added as property.
Definition: canprop.h:157
void SetSelectedOnly(bool selectedonly)
is set true, the object will only be rendered, if the owning object is selected
Definition: canprop.h:257
void SetValue(a2dCanvasObject *newvalue)
Set property value.
Definition: canprop.h:266
polygon defined with list of points.
Definition: polygon.h:45
Ref Counted base object.
Definition: gen.h:1045
virtual wxString StringRepresentation() const
Definition: gen.h:1901
double wxDegToRad(double deg)
conversion from degrees to radians
Definition: artglob.cpp:30
This template class is for property ids meant for properties that do not encapsulate another type...
Definition: id.h:397
bool GetCanRender() const
return true if the object can be rendered.
Definition: canprop.h:242
a2dStroke m_stroke
Definition: canprop.h:137
Defines a font to be set to a2dDrawer2D or stored in a2dCanvsObject etc.
Definition: stylebase.h:779
Input and output handler for the XmlSer format.
Definition: genxmlpars.h:819
OVERLAP
Result of a a2dBoundingBox intersection or hittest.
Definition: bbox.h:24
virtual a2dObject * GetRefObject() const
to get the a2dCanvasObject*
Definition: canprop.h:222
const a2dPropertyId * m_propId
the property id for which the value needs to be displayed.
Definition: canprop.h:455
The base class for all drawable objects in a a2dCanvasDocument.
wxUint32 m_resolveid
when loading a document, this is used to resolve references to objects
Definition: canprop.h:300
a2dCanvasObject is the base class for Canvas Objects.
Definition: canobj.h:371
property to hold a byte integer type vector to be associated with a a2dObject
Definition: canprop.h:526
defenitions an no more
a2dCanvasObject * GetParent(void) const
to get the parent where the m_propId is searched for.
Definition: canprop.h:424
a2dCanvasObjectPtr m_object
object held by this property.
Definition: canprop.h:303
bool GetPreRender() const
returns the current prerender setting.
Definition: canprop.h:251
wxUint64 a2dCanvasObjectFlagsMask
mask flags for a2dCanvasObject
Definition: candefs.h:152
Io handler to iterate through a a2dDocument.
Definition: gen.h:3911
a2dFillStyle
Filling styles for a2dFill.
Definition: stylebase.h:91
a2dText is an abstract base class.
Definition: cantext.h:93
void SetPreRender(bool prerender)
is set true, the object within this property will be rendered before its parent a2dCanvasObject ...
Definition: canprop.h:248
bool m_render
in case of a grahics application, should this property be rendered.
Definition: canprop.h:383
bool GetSelectedOnly() const
returns the current only selected setting.
Definition: canprop.h:260
layer settings for a a2dCanvasDocument Holds layers settings classes
(In)Visible property that can be added to Canvas Objects.
Definition: canprop.h:396
a2dTag a2dNewTag()
Generate new tag for grouping.
Definition: canprop.cpp:849
virtual a2dPolygonL * GetClipObject() const
return a2dPolygonL that is used for clipping
Definition: canprop.h:337
a2dNamedProperty * Clone(a2dObject::CloneOptions options, a2dRefMap *refs=NULL) const
Virtual copy constructor.
Definition: gen.cpp:1820
const a2dFill & GetFill() const
Definition: canprop.h:76
Input and output handler for the XmlSer format.
Definition: genxmlpars.h:862
Invisible Style property that can be added to Canvas Objects.
Definition: canprop.h:55
bool m_showname
Indicates if both name and value of the property are visible, or just the value.
Definition: canprop.h:458
bool m_visible
see SetVisible()
Definition: canprop.h:381
bool m_visible
see SetVisible()
Definition: canprop.h:295
a2dFill m_fill
Definition: canprop.h:142
A 2x3 affine matrix class for 2D transformations.
Definition: afmatrix.h:53
const a2dPropertyId * GetPropId()
get the id of the property displayed by this object
Definition: canprop.h:427
void SetCanRender(bool render)
if object can be rendered or not.
Definition: canprop.h:358
while iterating a a2dCanvasDocument, this holds the context.
Definition: canobj.h:3212
bool m_render
in case of a grahics application, should this property be rendered.
Definition: canprop.h:297
a2dBooleanClip
Used for defining how a ClippingRegion defined as a polygon is combined with.
Definition: drawer2d.h:54
const a2dFont * a2dDEFAULT_CANVASFONT
global a2dFont stock object for default font
Clipping Path property that can be added to a2dCanvasObject&#39;s.
Definition: canprop.h:322
void SetCanRender(bool render)
if object can be rendered or not.
Definition: canprop.h:240
virtual a2dObject * GetRefObjectNA() const
when a2dProperty, return its value else return NULL
Definition: canprop.h:223
virtual bool GetVisible() const
return true if the object is visible.
Definition: canprop.h:234
This is the base class for all kinds of property id&#39;s for a2dObject.
Definition: id.h:154
property to hold a a2dCanvasObject pointer type variable to be associated with a canvasobject ...
Definition: canprop.h:202
const a2dStroke & GetStroke() const
Definition: canprop.h:80
see a2dComEvent
Definition: gen.h:371
virtual wxString StringValueRepresentation() const
Definition: gen.h:1905
The a2dBoundingBox class stores one a2dBoundingBox of a a2dCanvasObject.
Definition: bbox.h:39
virtual bool GetVisible() const
return true if the object is visible.
Definition: canprop.h:352
all polygon and polyline a2dCanvasObject are here.
This template class is for property ids with a known data type.
Definition: id.h:477
property to hold a a2dBoundingBox type variable to be associated with a canvasobject ...
Definition: canprop.h:470
a2dStrokeStyle
stroke styles for a2dStroke
Definition: stylebase.h:298
list of a2dObject&#39;s
Definition: gen.h:3157
virtual void SetVisible(bool visible)
the object is visible or not.
Definition: canprop.h:350
CloneOptions
options for cloning
Definition: gen.h:1200
bool GetCanRender() const
return true if the object can be rendered.
Definition: canprop.h:360
a2dCanvasObject * GetValue() const
Get property value.
Definition: canprop.h:263
canprop.h Source File -- Sun Oct 12 2014 17:04:14 -- Sun Oct 12 2014 -- 1.8.5 -- wxArt2D -- . -- Main Page Reference Documentation