Preventing single word lines

Previous topic - Next topic

Ewac

Hello,
I've been trying to find a setting that would allow me to tell scribus not to create lines with single words. I have text that has justified alignment and hyphenation as settings. I have been going through everything manually to check that at the end of the paragraphs there isn't just one single word or even hyphenated word part and have adjusted hyphenation and line breaks manually.

Is there an automated setting for this that I am not aware of or is it just something that has to be done manually?

rocking

There are orphan line settings, but I am unaware of any similar software that will limit a line to a single word.   I don't even know what you would want Scribus to do at that point?  Should it delete characters or words so it fits without have an orphan word?  Or should it add words so the last one is not so lonely?

I think what you are doing (manual review) is really the only way to accomplish your goal.

Nermander

Yes, I was wondering the same, what would you expect Scribus to do if there is a final line with just one word?

I guess once you know that, it would be possible to write a script to do it.

elbitjusticiero

In a word processor, if you want to achieve this, you'd hit Shift+Enter instead of Enter in a justified paragraph, and the last line will stretch.

Whether this looks good or not depends heavily on how many words you have in that line.

Also, for single word lines, I wouldn't expect this to work.

Nermander

Scribus already has the option to margin adjust the last line, but that will not work if there is just one word there, needs two words.

AdmFubar

            x              (x)                    Quick and dirty solution: Adjust the font size a bit, try shrinking the font in the paragraph by half a point or one point if needed. Most readers wont notice the size difference unless they really are paying attention.
Using Scribus1.6.1, 1.7.0 openSUSE 15.6
Advanced hobbyist

amair

Hi,

sometimes there could be only some characters on the last line if hyphenation is active. In that case I play with "Text Properties / Advanced Settings", namely "Word Tracking" and "Glyph Extension".

Maybe the OP wants Scribus to also consider the number of characters on the last line while calculating the "Word Tracking" and "Glyph Extension" values for the paragraph lines.
Might be a cool feature, but I think one has always optimize manually.

Best regards,
Andreas

Ewac

Thanks everyone for the replies!
What I have been doing manually and what I would wish Scribus would do, would be to adjust hyphenation, word tracking and gylph extension in such a way that the last line consists of either a word with a certain minimum amount of characters or two words, but avoiding a short single word or hyphenated word part.
From what I understand there is no feature like that and manual adjustment is the way to go.

Lynn

Obviously too late to help on the original problem, but I found this post while working on a script to handle runts and figured I'd reply here in case google leads anyone else to this post.

Various typography advice books advise not allowing short word "stub" or "runt" endings to paragraphs. It's mentioned on the widow/orphan wikipedia page and in Bringhurst's Elements of Typographic Style: "2.4.2: Avoid leaving the stub-end of a hyphenated word, or any word shorter than four letters, as the last line of a paragraph."

I read a decent article that recommended the minimum length word be based on the indentation width used in the work, aiming for at least twice the width of the indent. That also seems a reasonable heuristic; Bringhurst favors small indents and his advice is based on that.

The easiest and most obvious way to prevent runts is to swap the space prior to the short word with a non-breaking space. I've always done that manually; sometimes pulling the runt up to the previous line will squash the text in a way that's more annoying than the runt would be. But if anyone wants to automate this, I've written a draft script that seems to do the trick:
https://github.com/notwhelmedyet/ScribusTypesetting/blob/main/ExperimentalScripts/runts.py

It won't catch sequences of very short words together, theoretically you could add a loop to check the next rightmost space. Regex would also be a more efficient alternative.