页边距中的段落编号 + 行号(使用 reledmac)

页边距中的段落编号 + 行号(使用 reledmac)

我希望将段落编号放在右边距(最好后面没有句号;并且不缩进文本)同时,我希望从每个段落的开头开始进行行号。

我有两个 MWE。在第一个示例中,数字是正确的,但我不喜欢布局(如上所述:缩进、句号、位置)。在第二个示例中,段落编号位于正确的位置,但我无法摆脱缩进和句号,并且行号不是从第 2 段的开头开始,而是贯穿始终。

我将非常感激任何想法!

微波能量吸收 1

\documentclass{scrbook}

\usepackage{reledmac}

\begin{document}
    
\chapter{Chapter}
\section{Section}
\subsection{Subsection}
\lineation{pstart}

\numberpstarttrue
\beginnumbering
\autopar Paragraph of text. Paragraph of text.Paragraph of 
text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of text.
text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of text.

\autopar Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of text.
text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of text.

\endnumbering

\end{document}

MWE 1编译: 微波能量吸收 1

微波辐射计 2

\documentclass{scrbook}

\usepackage{reledmac}
\newcommand{\mpstart}{\pstart \ledsidenote{\thepstart}}

\begin{document}
    
\chapter{Chapter}
\section{Section}
\subsection{Subsection}
\lineation{mpstart} % not working!

\beginnumbering
\mpstart Paragraph of text. Paragraph of text.Paragraph of 
text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of text.
text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.\pend

\mpstart Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of text.
text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.\pend

\endnumbering

\end{document}

MWE 2 编译: 在此处输入图片描述

答案1

我觉得你的第一个例子更有希望。这种方法比第二个例子中的\numberpstarttrue“黑客攻击”采用新类型的论点更自然\lineation{}。所以让我们从那里开始。

  1. 文献,第 148-9 页显示了reledmac调用时执行的操作\numberpstarttrue:它会\thepstart在段落开头打印。
    反过来,下面是确定如何该计数器显示:
\renewcommand{\thepstart}{{\bfseries\@arabic\c@pstart}. }

您可以将其复制\renewcommand到您的序言中并进行修改以满足您的需要(参见下面的示例)。

  1. 要取消所有段落缩进,你可以写 \setlength\parindent{0pt}在你的序言中(这在 (La)TeX 中是普遍适用的)。

[另一个建议:您不必\autopar在每个新段落中重复,事实上,这样做的目的是让您免去\pend \pstart在每个新段落中打字的麻烦。只需在之后使用一次,\beginnumbering就可以了。]

在此处输入图片描述

\documentclass{scrbook}

\setlength\parindent{0pt}

\usepackage{reledmac}

\numberpstarttrue
\lineation{pstart}

\makeatletter
\renewcommand{\thepstart}{\ledsidenote{\bfseries\@arabic\c@pstart}}
\makeatother

\begin{document}
    
\chapter{Chapter}
\section{Section}
\subsection{Subsection}

\beginnumbering
\autopar 
Paragraph of text. Paragraph of text.Paragraph of 
text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of text.
text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of text.

Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of text.
text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of 
text.Paragraph of text.Paragraph of text.Paragraph of text.Paragraph of text.

\endnumbering
\end{document}

相关内容