我附議 Mark 的建議:將最大參差空間(maximum ragged space)推到 0.5 或更高。它會嘗試更多的換行解決方案,但它仍會嘗試將文字填入盡可能少的行數,這樣做也會允許段落最後一行有更多空間。
目前的程式碼允許段落最後一行包含額外的「參差」(raggedness)空間,而且它非常不喜歡接近該參差度的極限。正如你所見,如果不允許「參差度」明顯,你就是在要求它將文字兩端對齊。實際上,你是在要求它完全兩端對齊文字,包括最後一行。
如果你在 ptxprint-mods.tex 檔案中輸入 \tracing{j},你的日誌將包含大量額外資訊,而與此問題相關的有趣行看起來會像這樣:
s@tsideskips p (p). 0.0pt/0.0pt, pf=0.0pt plus 1.0fil
s@tsideskips s1 (s1). 0.0pt plus 158.52597pt/0.0pt plus 158.52597pt, pf=0.0pt
前兩項是左/右允許的縮排加參差度。
最後一項是 \parfillskip,它是段落最後一行允許的空間量度的指標(對於 p 可達無限,對於置中的 s1 則沒有額外空間)。(也許這有點嚴苛??它基本上說它不應該在意最後一行是否最長)
s@tsideskips q2 (q2). 21.68065pt/0.0pt plus 79.26299pt, pf=0.0pt plus 79.26299p
t
對於右參差(ragged-right)的 q2,我看到參差度是 79.26pt,最後一行可以有額外的 79.26 點,因此它會非常不樂意允許最後一行超過 169.5 點的空格。
I’d echo Mark’s suggestion: push the maximum ragged space all the way to 0.5 or more. It’ll try more break solutions, but it’ll still try to fit the text into as few lines as it can, and doing that will also allow more space on the last line of the paragraph.
The code currently lets the last line of a paragraph include an extra ‘raggedness’ of space, and it really doesn’t like getting near the limit of that raggedness. As you saw, if you don’t allow the ‘raggedness’ to be noticeable, you’re asking it to justify the text. Actually, you’re asking it to fully justify the text, including the last line.
If you say \tracing{j} in your ptxprint-mods.tex file, then your log will include a lot of extra stuff, and the interesting lines for this question will be looking something like this:
s@tsideskips p (p). 0.0pt/0.0pt, pf=0.0pt plus 1.0fil
s@tsideskips s1 (s1). 0.0pt plus 158.52597pt/0.0pt plus 158.52597pt, pf=0.0pt
The first 2 are how much indent plus raggedness are allowed on left / right.
That last one is the \parfillskip and is a measure of how much space there is allowed to be on the last line of the paragraph (up to infinite for p, and no extra space for centered s1). (maybe that’s a bit harsh?? It basically says that it shouldn’t care if the last line is the longest)
s@tsideskips q2 (q2). 21.68065pt/0.0pt plus 79.26299pt, pf=0.0pt plus 79.26299p
t
For ragged-right q2, I’m seeing that the raggedness is 79.26pt, and the last line can have an extra 79.26 points, so it’ll be very unhappy at allowing more than 169.5 points of space on the final line.
機器翻譯自 English