[scribus] playing with Scribus as XML with XSLT

Gregory Pittman gpittman at iglou.com
Tue Oct 29 11:35:51 UTC 2013

On 10/29/2013 01:12 AM, José Antonio Rocha wrote:
> 2013/10/29 Gregory Pittman <gpittman at iglou.com>
>> After delving into XSLT a bit, I decided to experiment with using it to
>> transform SLA files. Once you modify your SLA file a bit, by adding a line
>> and then changing the extension to .xml, you can then make an XSLT file to
>> process it for a browser.
>> Here is a wiki page where I give a small example of what you might do:
>> http://wiki.scribus.net/**canvas/Scribus_files_as_XML<http://wiki.scribus.net/canvas/Scribus_files_as_XML>
>> Greg
> Nice trick!
> Someone can build a ebook with that.
It looks to be even trickier than I thought, though. One of the issues
is that in the Scribus file format, PAGEOBJECTs simply get appended as
they are added. So you might have 50 pages, then if you add an object to
page 1 at the very end of your design, it will be the last PAGEOBJECT in
the file, with a reference to its proper page. Very hard to parse with XSLT.

So my thinking is that, odd as it seems, it may work better to generate
a new XML file from a Python script inside of Scribus. In a sense, it
would be this concept:


but "on steroids" with a more complex output. This would allow for a
less complex XSL stylesheet, since there could be purpose-built tags


More information about the scribus mailing list