
前述したように(文末脚注をカスタマイズする)、のドキュメント脚注パッケージでは、文末脚注の外観を変更およびカスタマイズする方法についてはあまり説明されていません。そのため、コミュニティに助けを求めています。
文末脚注は次のようになります。
- 文末脚注マーカーは左余白に配置する必要があります。
- 文末脚注のテキストは、文末脚注全体にわたってインデントする必要があります (つまり、各文末脚注の最初の行だけではありません)。
\baselineskip
各音符の間には1 行のスペース (つまり) が入ります。- テキストの位置合わせなし (つまり
\raggedright
)。 - 文末脚注のテキストのサイズを設定できるようにしたいと思います (例
\normalsize
)。
私はから得るゴンサロの答え\enoteformat
これら全てまたは一部を達成するために再定義することはできるが、これで遊んでも何の達成にも至っていない:(
MWE:
\documentclass{article}
\usepackage{endnotes,lipsum}
%\renewcommand\enoteformat{} % perhaps doing something here would do the trick?
\begin{document}
\endnote{\lipsum[1]}\endnote{\lipsum[2]}
\theendnotes
\end{document}
答え1
の標準的な定義\enoteformat
は
\def\enoteformat{\rightskip\z@ \leftskip\z@ \parindent=1.8em
\leavevmode\llap{\makeenmark}}
これをモデルとして、次のようなことが考えられます。
\documentclass{article}
\usepackage{endnotes}
\usepackage{lipsum}
\renewcommand{\enotesize}{\normalsize}
\renewcommand\enoteformat{%
\raggedright
\leftskip=1.8em
\makebox[0pt][r]{\theenmark. \rule{0pt}{\dimexpr\ht\strutbox+\baselineskip}}%
}
\begin{document}
\endnote{\lipsum[1]}\endnote{\lipsum[2]}
\theendnotes
\end{document}
同じですが、enotez
パッケージを使用すると、おそらくより良く、確実に簡単になります。
\documentclass{article}
\usepackage{enotez}
\usepackage{lipsum}
\DeclareInstance{enotez-list}{sverre}{paragraph}
{
heading=\section*{#1},
notes-sep=\baselineskip,
format=\normalsize\normalfont\raggedright\leftskip1.8em,
number=\makebox[0pt][r]{#1.\ }\ignorespaces,
}
\begin{document}
\endnote{\lipsum[1]}\endnote{\lipsum[2]}
\printendnotes[sverre]
\end{document}
インデントの幅を小文字のインデントと左端の数字と同じにしたい場合は、次のようにします。
\documentclass{article}
\usepackage{showframe} % just for the example
\usepackage{enotez}
\usepackage{lipsum}
\newlength{\normalparindent}
\AtBeginDocument{\setlength{\normalparindent}{\parindent}}
\DeclareInstance{enotez-list}{sverre}{paragraph}
{
heading=\section*{#1},
notes-sep=\baselineskip,
format=\normalsize\normalfont\raggedright\leftskip\normalparindent,
number=\makebox[0pt][r]{\makebox[\normalparindent][l]{#1.}}\ignorespaces,
}
\begin{document}
Something\endnote{\lipsum[1]} to show the parindent\endnote{\lipsum[2]}
\printendnotes[sverre]
\end{document}
showframe
仕様が尊重されていることを確認するために追加しました
ノート
パラメータは\leftskip
、グローバル左マージンからテキストの実際の左マージンまでの距離です。コマンドは\raggedright
これをゼロに設定するので、後でこれを上書きし、\rightskip
伸縮可能なスペースに設定します。これもゼロに設定されるため、値を記憶するように\parindent
定義しました。不揃いさを減らすために、(まれな)ハイフネーションを可能にするパッケージも試してみるとよいでしょう。ダブルメイクボックストリックを使用して、コンテンツが左に寄った幅ゼロのボックスを設定します。このボックスには、幅広のボックスが含まれており、コンテンツは左に寄っています。\normalparindent
\RaggedRight
ragged2e
\normalparindent