
私が取り組んでいるプロジェクトから次のような抜粋があります。2 番目の段落の最初の行は、右側にぴったりと収まらず、右余白を超えて伸びています。
他の回答では、この問題を解決するためにハイフンを使用することを提案していますが、これは 1 音節の単語なのでハイフンを使用することはできません。この問題を解決するためにできることはありますか?
\documentclass[12pt]{book}
\usepackage[paperwidth=5.5in,
paperheight=8.5in,
inner=0.25in,
outer=0.5in,
bindingoffset=0.25in
]{geometry}
\usepackage{fontspec}
\setmainfont[Numbers=OldStyle]{Linux Libertine O}
\begin{document}
Now the merchant-farmer understood what all this meant, because he had overheard the talk between the Bull and the Ass, so quoth he, ``Take that rascal donkey, and set the yoke on his neck, and bind him to the plough and make him do Bull’s work.''
Thereupon the ploughman took the Ass, and worked him through the livelong day at the Bull’s task; and, when he failed for weakness, he made him eat stick till his ribs were sore and his sides were sunken and his neck was flayed by the yoke; and when he came home in the evening he could hardly drag his limbs along, either
\end{document}
答え1
行幅に対して比較的大きいフォントを使用する場合、\sloppy
段落に使用できるオプションの 1 つは次のとおりです。
...
{\sloppy
Thereupon the ploughman took the Ass, and worked him through the livelong day at the Bull’s task; and, when he failed for weakness, he made him eat stick till his ribs were sore and his sides were sunken and his neck was flayed by the yoke; and when he came home in the evening he could hardly drag his limbs along, either
}
% notice the white line above, \sloppy is applied when \par is found.
...
実際のところ、線はちょっと雑です、はい...
microtype
(\usepackage{microtype}
プリアンブルに追加)を使用する場合、まだ overfull 行が残りますが、次のようになります。
Overfull \hbox (1.02644pt too wide) in paragraph at lines 16--17
それはおそらく許容できるでしょう。
最後に、段落の先頭のインデントを減らすことができます。たとえば、\parindent=14pt
microtype を使用すると、オーバーフルの行が修正されます。
%! TeX program = lualatex
\documentclass[12pt]{book}
\usepackage[paperwidth=5.5in,
paperheight=8.5in,
inner=0.25in,
outer=0.5in,
bindingoffset=0.25in
]{geometry}
\usepackage{fontspec}
\usepackage{microtype}
\parindent=14pt
\setmainfont[Numbers=OldStyle]{Linux Libertine O}
\begin{document}
Now the merchant-farmer understood what all this meant, because he had overheard the talk between the Bull and the Ass, so quoth he, ``Take that rascal donkey, and set the yoke on his neck, and bind him to the plough and make him do Bull’s work.''
Thereupon the ploughman took the Ass, and worked him through the livelong day at the Bull’s task; and, when he failed for weakness, he made him eat stick till his ribs were sore and his sides were sunken and his neck was flayed by the yoke; and when he came home in the evening he could hardly drag his limbs along, either
\end{document}