[Scribus] .sla file parsing by Scribus

Gregory Pittman gpittman
Sun Feb 8 04:54:29 CET 2004


Still working on Scribus file generation/parsing with Perl...(I think I
can hear yawning in the distance)

There are XML::Parser, and XML::Writer modules which make each pretty
straightforward.

Some initial playing with Parser.pm shows that it doesn't like the
Ctrl-E used for newline in text in Scribus -- generating an 'invalid
token' error.

My little scribus.pl program uses XML::Writer, which has some options
for allowing a visually appealing output. Scribus seems to have a
problem with whitespace however.

There is a NEWLINES setting in Writer.pm which is OK with Scribus even
though it inserts the newline just before the end of the tag (see
output.sla). This one works with Scribus.

But when I use settings (DATA_MODE and DATA_INDENT) for indentation,
Scribus can't read the file (see output-indent.sla). This file is
visually more attractive and understandable and presumably would be
well-formed by XML standards. Even if I set the indent to 0, it still
won't be displayed by Scribus.

My point overall is that, even if hardly anyone else has any use for
Perl with Scribus, these are problems that relate to the well-formedness
of .sla files, and if the eventual aim is to have them be
XML-compatible, then they ought to survive various tests of
well-formedness, and as long as they survive those tests, then Scribus
ought to be able to read them.

Gregory Pittman



-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: output.sla
Url: http://nashi.altmuehlnet.de/pipermail/scribus/attachments/20040208/bc314838/attachment.ksh 
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: output-indent.sla
Url: http://nashi.altmuehlnet.de/pipermail/scribus/attachments/20040208/bc314838/attachment-0001.ksh 



More information about the scribus mailing list