[scribus] Scientific Document language "WiScri" -> Bunch of bugs/proposals

Gregory Pittman gpittman at iglou.com
Fri Jul 7 17:51:05 UTC 2017

On 07/07/2017 12:37 PM, Jonas Bechtel wrote:
> Dear Scribus team,
> on monday I have submitted my study thesis. This thesis was written in scribus, but for the chapter numbering, page numbering and limited conditionals, I implemented an own language in python and called it WiScri (for scientific Scribus = wissenschaftliches Scribus in german). It ended up in following kind of statements:
> ##SET(varname 5)##IF(##GET(varname)==5 5: korrekt ++ELSE 5: nicht korrekt)
> (Because I'm confused with all this LaTeX stuff and I don't have Word on Linux which has limited "field" functionality and OpenOffice/LibreOffice seem to have even less "field" functionality)
> But not everything was fine; there were some barriers which could be teared down. I do list them here, please tell me which points are to be handled in which way (bugtracker, ...)
> I'm using Scribus 1.4.6
> The barriers were:
1> * The printer pre-tests warns for objects which are marked as "Do not
2> * All images are being treated equal concerning the compression
method / level
3> * All images are reencoded, even if already in target format.
4> * [png images could be used with no reencoding in pdf files, they
seem simply to be split in some special way]
5> * Display and modify the source link for embedded image/eps files.
(To correct links like
../../../../../home/user/subdir/subsub/mydoc/pic1.jpg - I have done this
in the document .sla source)
6> * You cannot modify pdf links (except changing the document .sla source)
7> * The internal utf-8-representation doesn't match the output
bytestream for scribus.getAllText() - I had to escape all 2-Byte/3-Byte
chars before main WiScri processing and reescape them back after WiScri
8> * [When copying objects the new object get's a localized name which
only can be guessed - OK, that seems to be better in the recent version]
9> * After copying an object this object reports wrong font names when
they are programmatically questioned. To circumvent this you have to
insert some text and delete it in the same line as the questioned text
before questioning.
10> * Whilst executing my scripts, scribus excessively puts itself into
the foreground and uses the clipboard
11> * Whilst executing my scripts, scribus doesn't let other programs
use the clipboard (script execution breaks)
12> * After using the Python PDFWriter object, the Python execution ends
with errors when performing simple string operations which work
perfectly before. Sometimes you can circumvent this by deinitializing
it: p = scribus.PDFfile(); ... p.save(); p = [];
13> * pdf export checks 2 times the page numbers if invoked by python.
Especially stupid is the routine which _sorts_ the page numbers without
any technical need for it. I had to "hack" the binary (as I didn't want
to recompile it on my rather old system) in order to switch off page
number sorting. [happens directly in the setter for p.pages = ...]
14> * Position of pieces of text - It would be pretty nice to know the
final position for the words inside text objects (so-to-speak to know
where the sub-chapter heading is located, when knowing it is char 456 -
481 of the text object)
15> * There's no handy tool to relink text frames - you don't really see
what you are doing.
> If you want to have a look at the file, feel invited to visit http://jbechtel.de/site/Tools/Zellortung where you find the actual pdf and the compressed project directory.
> Most likely, your document build won't work for the first time - don't hesitate do ask me questions on the code I've written and how to bring it to life :-)
> So again: this is a big list, please tell me how to dispatch it's items.

Hi Jonas,

Not sure I understand many of these items. I've numbered them so I can
refer to certain ones.
First of all, it's interesting to me that you are making such an effort
for a thesis. I wonder if you've gotten hung up in the layout a bit too
much. You've certainly made this very complicated -- more than
necessary, perhaps?

1 - the pre-tests are supposed to warn about this. It's just a warning.
When something is marked as do not print, it won't show up in the PDF
2 - that's the way things are. Don't know of anything to do about it.
5 - you might try using Collect for Output (saving your SLA file and
images in its own directory) and see if that helps the links. It seemed
to in an experiment I just tried. The most important thing is that
Scribus finds the images.
6 - that's the way it should be, I think.
9 - font names are tricky, since according to your Preferences every
frame has a default font, which you may not have actually used for any
of the text in the frame. So generically, I think querying a frame for
its font is rather nonsensical.
13 - I think you could have used Scribus's internal page numbering scheme.
14 - this may be trickier than you think. In addition to all the
characters you see, there are numerous nonprinting and control
characters contained inside a text frame. This is something I had to
deal with when making Autoquote.py.
15 - when you click the Link Text Frames or Unlink Text Frames icon, you
should see arrows appear indicating currently linked frames. No arrow,
no link.


More information about the scribus mailing list