我赞同 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 显示原文