diff options
| author | Markus Engel <markus.engel@tum.de> | 2012-08-17 23:27:53 +0000 |
|---|---|---|
| committer | Markus Engel <markus.engel@tum.de> | 2012-08-17 23:27:53 +0000 |
| commit | 16b19e18b4f9b416f0cc16f6b5b749bd38455b24 (patch) | |
| tree | 3c54084d38697b9e34414a837aeb2b190b0f3ea3 /src/sp-object.h | |
| parent | Fix for 168164 : Font sizes in points option (diff) | |
| download | inkscape-16b19e18b4f9b416f0cc16f6b5b749bd38455b24.tar.gz inkscape-16b19e18b4f9b416f0cc16f6b5b749bd38455b24.zip | |
Added "virtual pad" to SPObject.
(bzr r11608.1.1)
Diffstat (limited to 'src/sp-object.h')
| -rw-r--r-- | src/sp-object.h | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/src/sp-object.h b/src/sp-object.h index b08706b0b..9ff772870 100644 --- a/src/sp-object.h +++ b/src/sp-object.h @@ -176,6 +176,7 @@ SPObject *sp_object_href(SPObject *object, gpointer owner); */ SPObject *sp_object_hunref(SPObject *object, gpointer owner); +class CObject; /** * SPObject is an abstract base class of all of the document nodes at the @@ -203,6 +204,8 @@ public: ALWAYS_COLLECT }; + CObject* cobject; + unsigned int cloned : 1; unsigned int uflags : 8; unsigned int mflags : 8; @@ -909,6 +912,7 @@ public: friend class SPObjectClass; friend class SPObjectImpl; + friend class CObject; }; /// The SPObject vtable. @@ -948,6 +952,33 @@ private: }; +class CObject { +public: + CObject(SPObject* object); + virtual ~CObject(); + + virtual void onBuild(SPDocument* doc, Inkscape::XML::Node* repr); + virtual void onRelease(); + + virtual void onChildAdded(Inkscape::XML::Node* child, Inkscape::XML::Node* ref); + virtual void onRemoveChild(Inkscape::XML::Node* child); + + virtual void onOrderChanged(Inkscape::XML::Node* child, Inkscape::XML::Node* old_repr, Inkscape::XML::Node* new_repr); + + virtual void onSet(unsigned int key, const gchar* value); + + virtual void onReadContent(); + + virtual void onUpdate(SPCtx* ctx, unsigned int flags); + virtual void onModified(unsigned int flags); + + virtual Inkscape::XML::Node* onWrite(Inkscape::XML::Document* doc, Inkscape::XML::Node* repr, guint flags); + +protected: + SPObject* spobject; +}; + + /** * Compares height of objects in tree. * |
