使用宏处理诗篇缩进
\def\par{\ifvmode\noindent\else\endgraf\fi}
\obeylines
由大卫·卡莱尔提供这里我遇到了下一个问题,即诗句无法用一行写完。
我尝试在那里添加额外的缩进,\hangindent
但没有成功。
以下是一些 MWE:
\documentclass[12pt,a4paper]{article}
\usepackage[
left=4cm,
right=4cm,
showframe]{geometry}
\begin{document}
\begingroup
\setlength{\parskip}{0pt}
\def\par{\ifvmode\noindent\else\endgraf\fi}
\obeylines
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor
\endgroup
\end{document}
答案1
像这样吗?
\documentclass[12pt,a4paper]{article}
\usepackage[
left=4cm,
right=4cm,
showframe]{geometry}
\begin{document}
\begingroup
\setlength{\parskip}{0pt}
\def\par{\ifvmode\hangindent40pt\noindent\else\endgraf\hangindent40pt\fi}
\obeylines
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor
Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor
\endgroup
\end{document}
答案2
更新:使用scripture
包部分受到这个问题的启发。
这个答案有点多余,因为 David Carlisle 已经给出了一个漂亮的答案。但我对它如何帮助我排版圣经引文印象深刻,我想提供一个更完整的示例,说明如何使用这种方法排版圣经诗歌。它比我以前围绕环境所做的努力要好得多list
。欢迎提出任何改进建议。
\documentclass[twocolumn]{article}
\usepackage[b5paper,margin=2cm]{geometry}
\pagestyle{empty}
\usepackage{scripture}
\renewcommand*{\thefootnote}{\emph{\alph{footnote}}}
\begin{document}
\section*{Job}
\subsubsection*{Elihu}
\begin{scripture}
\ch{32}So these three men stopped answering Job, because he was righteous in
his own eyes. \vs{2}But Elihu son of Barakel the Buzite, of the family of
Ram, became very angry with Job for justifying himself rather than God.
\vs{3}He was also angry with the three friends, because they had found no
way to refute Job, and yet had condemned him.\footnote{\emph{3} Masoretic
Text; an ancient Hebrew scribal tradition \emph{Job, and so had condemned
God}} \vs{4}Now Elihu had waited before speaking to Job because they were
older than he. \vs{5}But when he saw that the three men had nothing more to
say, his anger was aroused.
\vs{6}So Elihu son of Barakel the Buzite said:
\begin{poetry}
``I am young in years,
and you are old;
that is why I was fearful,
not daring to tell you what I know.
\vs{7}I thought, `Age should speak;
advanced years should teach wisdom.'
\vs{8}But it is the spirit\footnote{\emph{8} Or \emph{Spirit}; also in verse 18} in a person,
the breath of the Almighty, that gives them understanding.
\vs{9}It is not only the old\footnote{\emph{9} Or \emph{many}; or \emph{great}} who are wise,
not only the aged who understand what is right.
\extraskip
\vs{10}``Therefore I say: Listen to me;
I too will tell you what I know.
\vs{11}I waited while you spoke,
I listened to your reasoning;
while you were searching for words,
\vs{12}I gave you my full attention.
But not one of you has proved Job wrong;
none of you has answered his arguments.
\vs{13}Do not say, `We have found wisdom;
let God, not a man, refute him.'
\vs{14}But Job has not marshaled his words against me,
and I will not answer him with your arguments.
\end{poetry}
\end{scripture}
\newpage
\section*{Psalms}
\subsubsection*{\centering Psalm 63\footnote{In Hebrew texts 63:1--11 is
numbered 63:2--12.}}
\begin{center}
\emph{A psalm of David. When he was in the Desert of Judah.}
\end{center}
\begin{scripture}
\begin{poetry}
\vs{1}You, God, are my God,
earnestly I seek you;
I thirst for you,
my whole being longs for you,
in a dry and parched land
where there is no water.
\extraskip
\vs{2}I have seen you in the sanctuary
and beheld your power and your glory.
\vs{3}Because your love is better than life,
my lips will glorify you.
\vs{4}I will praise you as long as I live,
and in your name I will lift up my hands.
\vs{5}I will be fully satisfied as with the richest of foods;
with singing lips my mouth will praise you.
\extraskip
\vs{6}On my bed I remember you;
I think of you through the watches of the night.
\vs{7}Because you are my help,
I sing in the shadow of your wings.
\vs{8}I cling to you;
your right hand upholds me.
\extraskip
\vs{9}Those who want to kill me will be destroyed;
they will go down to the depths of the earth.
\vs{10}They will be given over to the sword
and become food for jackals.
\extraskip
\vs{11}But the king will rejoice in God;
all who swear by God will glory in him,
while the mouths of liars will be silenced.
\end{poetry}
\end{scripture}
\end{document}