Creating a new SPObject

From Inkscape Wiki
Revision as of 22:44, 14 May 2007 by Johanengelen (talk | contribs)
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Copy sp-skeleton.cpp and sp-skeleton.h to your files, and rename everything from /skeleton/i to your name.

Add your object name to the list in sp-object-repr.cpp's repr_name_entries, and add the new .h file to the include list at the top. This will let your new SPObject have it's functions get called when a Repr appears in the tree.

Note: it must be added to repr_name_entries NOT sodipodi_name_entries.