Automatic Text Frames

Previous topic - Next topic

joesber

When opening a new document there is the option of selecting "automatic text frames", which works good enough and sets text frames correctly inside the margins.

But for some reason I don't find the possibility of doing that once the document ist already opened. Do I am blind and the tool is right in front of my eyes? Or isn't it possible to create automatically text frames in an already created document??

Probably it is a silly question and I'm just unable to see where to click... Hope that's the case!


AdmFubar

Goto the page menu, Page/Insert you can add more pages and text frames will be added as specified on the page setup when you initially created your document
Using Scribus 1.6.1, openSUSE 15.5
Advanced hobbyist

joesber

"[...] text frames will be added as specified on the page setup when you initially created your document"

My question is how to do it when the document is already created (but the box for "automatic text frames" was not selected).

utnik

this might be possible in some future versions, but with current scribus versions it isn't.

utnik

digirew

Unless im misunderstanding something, if all your after is placing a text frame onto a page (full size of page/margins etc), this can be easily achieved by creating a script via. the scripter api (https://impagina.org/scribus-scripter-api/). This way all you have to do is run the script from the scripter menu and it will do all the work for you.

joesber

Hi digirew! I've never used the scripter-api. Could you detail a bit more how it works?

To be the most concrete: what I'm searching is a way to create linked text frames which automatically fullfil the area within the margins.

Even if, at the welcome window of Scribus, I do select "automatic text frames", I may change the margins of the document, but the automatic text frames won't adjust to them. Is it possible to do that with the scripter?

Thank you!

digirew

joesber,

With the Scripter API, you can write python scripts to control functionality in Scribus without manually using the interface etc. (It does require some knowledge of writing code.).

here is a useful page with more info and various sample scripts: https://wiki.scribus.net/canvas/Category:Scripts


While I have never used linked text frames with the scripter api, I can see that these functions appear to be available to do so. (https://impagina.org/scribus-scripter-api/text-frame/#linktextframes).

The idea is you would have a script that would determine the size/margins, and then create your text frames, and then link them up.


Im assuming you are you using multi column documents?

joesber

#7
Hi Digirew,
Unfortunately my knowledge on writing code (besides some tiny thing with html) is equal to zero. But I've checked the links from your comments, and the Scripter API seems a powerfull tool for python-empowered folks. It even wakes my curiosity on learning some code!

Actually what I'm doing is very simple and can be achieved just by opening a new document with the new margins and the automatic text frames option clicked, but it would be more elegant if woudn't have to start a new document each time.

There is only one column.


As you can see in this first picture, the text does not exactly start either at the top nor at the bottom (red lines).



By working around with the baseline grid offset and lowering the margins (increasing the top and bottom of the text frame), it is possible to get very close to the real/visual margins which at first I designed:



But then, after changing the margins, the new automatic text frame on the following pages wont readjust to the new margins. The solution is to open a new document and set the final margins there...
But it would be nicer to do it within the same document. Besides, there may be cases where a document would be wished to have automatic text frames with different sizes (of course you can do that manually, but damm, there are already too much things which are to be done manually on Scribus!).

If automatic text frames would automatically readjust following the master pages, that would be awesome, wouldn't it?



digirew

joesber,

If you have the one text frame per page (that was generated from the automatic text frame when creating the new document). and then you change your document margins, you should be able to create a python script via. Scripter API to achieve what you are after, and have all the automatic text frames resize to the new page margins.

I went through the API commands (https://impagina.org/scribus-scripter-api/), and all the commands that would be needed appear to be available, you just need a script written!