在诗歌环境中完全对齐线条

在诗歌环境中完全对齐线条

我正在排版一些诗歌。作者希望诗行完全对齐,即使这样会留下一些奇怪的空白。有什么想法可以做到这一点吗?

\documentclass[11pt, openany]{memoir}

\begin{document}

\poemtitle*{Fluid}
\settowidth{\versewidth}{So many years of tiny pills, then suddenly}

\begin{verse}[\versewidth]
Urinalysis easily read by eye. Endocrine\\
placeholder contraceptive. Medicated\\
racehorses often suffer catastrophic\\
breakdowns launching petite cisgendered\\
jockeys. Relating to, or denoting glands\\
that secrete hormones directly into the\\
blood. Our better selves test-strips for\\
alcohol levels in breast milk. To pass.\\
So many years of tiny pills, then suddenly\\
a plus sign soaked in piss. Their second\\
puberty and menopause at once. The beard\\
syrup so viscous in the needle.\\
\end{verse}

\end{document}

答案1

这就是你想要的吗?

请注意,使用比例字体的最长行不是等宽字体的最长行。

演示

\documentclass[11pt, openany]{memoir}

\begin{document}

\poemtitle*{Fluid} 
\settowidth{\versewidth}{puberty and menopause at once. The beard}%
\hfil\begin{minipage}{\versewidth}
\let\\=\linebreak
\sloppy 
Urinalysis easily read by eye. Endocrine\\
placeholder contraceptive. Medicated\\
racehorses often suffer catastrophic\\
breakdowns launching petite cisgendered\\
jockeys. Relating to, or denoting glands\\
that secrete hormones directly into the\\
blood. Our better selves test-strips for\\
alcohol levels in breast milk. To pass.\\
So many years of tiny pills, then suddenly\\
a plus sign soaked in piss. Their second\\
puberty and menopause at once. The beard\\
syrup so viscous in the needle.\\
\end{minipage}

\end{document}

这个环境解决了确定最长线的问题。

\documentclass[11pt, openany]{memoir}
\usepackage{environ}

\NewEnviron{justverse}{\sbox0{\begin{tabular}{@{}l@{}}\BODY\end{tabular}}%
  \parindent=0pt
  \par
  \leftskip=\dimexpr 0.5\columnwidth-0.5\wd0\relax
  \rightskip=\leftskip
  \let\\=\linebreak
  \sloppy\BODY
\par}

\begin{document}

\poemtitle*{Fluid} 
\begin{justverse}
Urinalysis easily read by eye. Endocrine\\
placeholder contraceptive. Medicated\\
racehorses often suffer catastrophic\\
breakdowns launching petite cisgendered\\
jockeys. Relating to, or denoting glands\\
that secrete hormones directly into the\\
blood. Our better selves test-strips for\\
alcohol levels in breast milk. To pass.\\
So many years of tiny pills, then suddenly\\
a plus sign soaked in piss. Their second\\
puberty and menopause at once. The beard\\
syrup so viscous in the needle.\\
\end{justverse}

\end{document}

答案2

一个带有软件包的解决方案tabulary。无需确定最长的行(只要行的长度不超过文本宽度)。我还添加了microtype一些极端选项来缓解“奇怪的空格”(根据您对文本拉伸和收缩、奇怪的空格和空格河的容忍度进行相应的更改)。

姆韦

\documentclass{memoir}
\usepackage{tabulary}
\usepackage[stretch=120, shrink=120]{microtype}
\begin{document}
\poemtitle*{Tabulary poem}
\centering
\begin{tabulary}{\textwidth}{>{\parfillskip=0pt}J}
Urinalysis easily read by eye. Endocrine\\
placeholder contraceptive. Medicated\\
racehorses often suffer catastrophic\\
breakdowns launching petite cisgendered\\
jockeys. Relating to, or denoting glands\\
that secrete hormones directly into the\\
blood. Our better selves test-strips for\\
alcohol levels in breast milk. To pass.\\
So many years of tiny pills, then suddenly\\
a plus sign soaked in piss. Their second\\
puberty and menopause at once. The beard\\
syrup so viscous in the needle.\\
\end{tabulary}
\end{document}

顺便说一句,这对于一首诗来说,是一种非常奇怪的格式。

答案3

一个非常简单的方法是使用\parfillskip。例如,

\documentclass[11pt, openany]{memoir}

\begin{document}

\poemtitle*{Fluid}
\settowidth{\versewidth}{So many years of tiny pills, then suddenly}

\begin{verse}[\versewidth]
% here i'm just changing as little as possible (and keeping it in a group)
\let\\=\par
\setlength{\parskip}{0pt}
\setlength{\parfillskip}{0pt}
\frenchspacing % helps with punctuation when things are so widely spaced out

Urinalysis easily read by eye. Endocrine\\
placeholder contraceptive. Medicated\\
racehorses often suffer catastrophic\\
breakdowns launching petite cisgendered\\
jockeys. Relating to, or denoting glands\\
that secrete hormones directly into the\\
blood. Our better selves test-strips for\\
alcohol levels in breast milk. To pass.\\
So many years of tiny pills, then suddenly\\
a plus sign soaked in piss. Their second\\
puberty and menopause at once. The beard\\
syrup so viscous in the needle.\\
\end{verse}

\end{document}

如果我要对多首诗这样做,我会为它创建一个环境......

答案4

以下是其中一种方法:

![![在此处输入图片描述

\documentclass[11pt, openany]{memoir}
\usepackage{changepage}
\begin{document}

\poemtitle*{Fluid}


\let\V\hfill

 \begin{adjustwidth}{1in}{1in}
\noindent Urinalysis \V easily \V  read \V by \V  eye. \V Endocrine\\
 placeholder \V  contraceptive. \V  Medicated\\
racehorses \V often \V suffer \V catastrophic\\
breakdowns \V launching \V petite \V cisgendered\\
jockeys.\V Relating \V to, \V or \V denoting \V glands\\
that \V  secrete \V  hormones \V  directly \V  into \V  the\\
blood. \V  Our \V  better \V  selves \V  test-strips \V  for\\
alcohol \V  levels \V  in \V  breast \V  milk. \V  To \V pass.\\
So \V  many \V  years \V  of \V  tiny \V  pills, \V  then \V  suddenly\\
a \V  plus \V  sign \V  soaked \V  in \V piss. \V  Their \V  second\\
puberty \V  and \V  menopause \V  at \V  once. \V  The \V  beard\\
syrup \V  so \V  viscous \V  in \V  the \V  needle.\\

\end{adjustwidth}

\end{document}

相关内容