GSoC 2012 Scribus XML File Format

From Scribus Wiki
Revision as of 13:32, 6 April 2012 by ProKrammer (talk | contribs) (Created page with "'''Scribus XML File Format''' '''Abstract :''' Currently Scribus uses a variant of homebrewed XML. Although there exists some documentation, it's usually outdated and of li...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Scribus XML File Format

Abstract :

Currently Scribus uses a variant of homebrewed XML. Although there exists some documentation, it's usually outdated and of limited use. So, a new file format for Scribus can be introduced using the relax NG Compact specifications. This is advantageous because it relax Ng is well documented, and is readable unlike the present xml.

Problem Description :

The scope of the project is to introduce a modular and well defined file format for Scribus which could replace the present .sla files in the future.

1) Scribus IO Output with Relax NG specifications. Makes xml from the document. 2) Scribus Builder Class. Contains methods for creating page items. 3) Using the Scribus Builder to implement the Scribus IO Input. Makes scribus document from XML.

Implementation Details :

Implement the interface class Scribus IO { void xmlOut(QAbstractXmlReceiver r) const; void xmlIn(QXmlStreamReader r, ScribusBuilder b); } for all relevant scribus model classes.

xmlOut writes xml from the given scribus object, and it follows the relaxNG compact specifications.

xmlOut will be implemented using qxmlserializer ( sub class of Qxmlabstractreciever ), and not qxmlstreamwriter because it allows filtering the output with XQuery, so that it can be converted to older file formats.

xmlIn takes the xml code from the file using the QXmlStreamReader and using the ScribusBuilder ( how to make scribus page items ) and data from the xml to parse the Scribus object.

xmlIn will be a recursive descent parser, since this type of parsing is fast, and modular.

ScribusBuilder class : Contains methods to create page items, and will help the xmlIn to make the Scribus Document. The code for this is spread in scribus code base in various scribus1XYformat.cpp and other source files.

Using RelaxNG tools like Jing-Trang to check the validity of the xml generated from xmlOut.

Timeline :

April : Researching the RelaxNG code, and the present implementation of scribus xml.

Last week : Exams.

May : Check through the Scribus source code, for all the implementation of scribus1xyformat.cpp and solve relevant bugs.

May 21 : GSoC official start date.

May 21 - June 10 : Implementation of xmlOut.

June 11 - July 10 : Implementation of ScribusBuilder.

July 11 - July 25 : Using the above ScribusBuilder implementation write the xmlIn

Rest of the time for bugs and checking the functionality of the code.

After GSoC :

I would like to continue contributing to Scribus even after GSoC. I will continue working with the Scribus team, fixing bugs, and also on some of the specific projects i am interested in.

The implementation of the Scribus IO can be automated. I would continue this after GSoC.

1) Speeding up Scribus

   Using Multithreading.

2) Undo Text Feature

3) maybe ( Depends on the difficulty level ).

Biography :

   I am Parthasarathy, second year Undergraduate Student in Computer Science from Hyderabad, India.

I study at Indian Institute of Technology Madras, one of the most prestigious institutions in the Engineering field in India.

I have a good knowledge and experience in both C++ , and Qt. I have started my Free Software contribution with KDE. I have worked with Digikam ( Photo Management Tool ) and have submitted patches for them.  :: KIOexport patch  :: mediawiki export patch

I have submitted bug fixes for Scribus : 1) 2) Yet to be updated :)

I have also contributed towards Amarok ( Media Player ).

Contact Information :

Student : Parthasarathy G Email ID : Freenode irc nick : proKrammer Location : Hyderabad, India ( UTC + 530 )