diff --git a/src/sp-skeleton.cpp b/src/sp-skeleton.cpp
index ee0c9626b9623695732aea3987f84ce584e0730c..42fc5289f7e70bf6d9cc5e0f5b7de88b40a0ff1c 100644 (file)
--- a/src/sp-skeleton.cpp
+++ b/src/sp-skeleton.cpp
-#define __SP_SKELETON_CPP__
-
/** \file
* SVG <skeleton> implementation, used as an example for a base starting class
* when implementing new sp-objects.
/*
* Authors:
* Kees Cook <kees@outflux.net>
+ * Abhishek Sharma
*
* Copyright (C) 2004 Kees Cook
*
static void sp_skeleton_release(SPObject *object);
static void sp_skeleton_set(SPObject *object, unsigned int key, gchar const *value);
static void sp_skeleton_update(SPObject *object, SPCtx *ctx, guint flags);
-static Inkscape::XML::Node *sp_skeleton_write(SPObject *object, Inkscape::XML::Node *repr, guint flags);
+static Inkscape::XML::Node *sp_skeleton_write(SPObject *object, Inkscape::XML::Document *doc, Inkscape::XML::Node *repr, guint flags);
static SPObjectClass *skeleton_parent_class;
@@ -110,18 +109,18 @@ sp_skeleton_build(SPObject *object, SPDocument *document, Inkscape::XML::Node *r
/*
Pay attention to certain settings here
- sp_object_read_attr(object, "xlink:href");
- sp_object_read_attr(object, "attributeName");
- sp_object_read_attr(object, "attributeType");
- sp_object_read_attr(object, "begin");
- sp_object_read_attr(object, "dur");
- sp_object_read_attr(object, "end");
- sp_object_read_attr(object, "min");
- sp_object_read_attr(object, "max");
- sp_object_read_attr(object, "restart");
- sp_object_read_attr(object, "repeatCount");
- sp_object_read_attr(object, "repeatDur");
- sp_object_read_attr(object, "fill");
+ object->readAttr( "xlink:href" );
+ object->readAttr( "attributeName" );
+ object->readAttr( "attributeType" );
+ object->readAttr( "begin" );
+ object->readAttr( "dur" );
+ object->readAttr( "end" );
+ object->readAttr( "min" );
+ object->readAttr( "max" );
+ object->readAttr( "restart" );
+ object->readAttr( "repeatCount" );
+ object->readAttr( "repeatDur" );
+ object->readAttr( "fill" );
*/
}
* Writes its settings to an incoming repr object, if any.
*/
static Inkscape::XML::Node *
-sp_skeleton_write(SPObject *object, Inkscape::XML::Node *repr, guint flags)
+sp_skeleton_write(SPObject *object, Inkscape::XML::Document *doc, Inkscape::XML::Node *repr, guint flags)
{
debug("0x%p",object);
//SPSkeleton *skeleton = SP_SKELETON(object);
// is this sane?
repr->mergeFrom(SP_OBJECT_REPR(object), "id");
} else {
- repr = SP_OBJECT_REPR(object)->duplicate(NULL); // FIXME
+ repr = SP_OBJECT_REPR(object)->duplicate(doc);
}
}
if (((SPObjectClass *) skeleton_parent_class)->write) {
- ((SPObjectClass *) skeleton_parent_class)->write(object, repr, flags);
+ ((SPObjectClass *) skeleton_parent_class)->write(object, doc, repr, flags);
}
return repr;
fill-column:99
End:
*/
-// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=99 :
+// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:fileencoding=utf-8:textwidth=99 :