Version 1, last updated by Thinker Li at January 27, 2011 07:26 UTC

The authoring tool is an extension of Inkscape. It is wrote in Python, but Inkscape is wrote in C/C++. We provide a binding for Python that Python code can access internal data and API of Inkscape. The binding is implemented with C/C++ and Cython. Following image is the relationship of modules.

scribboo_n_pybind_modules

Inkscape Core is origin code of Inkscape with some patch. Pybind module is responsible for loading pyink.py and pybInkscape modules. pybink.py is the module implemented by the extension, Scribboo. pybInkscape provides some Inkscape API binding for pyink.py (Python). The patch of Inkscape Core hooks on some control flow of Inkscape. It would call pybind, and pybind delivers hook calls to handlers implemented by pyink.py in turn. With hooks and API binding, pyink.py can extend functions of Inkscape with Python code. That is how we implement authoring tool.