maieul / ledmac

package reledmac for latex
http://www.ctan.org/tex-archive/macros/latex/contrib/reledmac
54 stars 28 forks source link

Long chapter and section title cause problem with line numbering #778

Closed mxordn closed 6 years ago

mxordn commented 6 years ago

Version of reledmac / reledpar (if that is a devellopement version, please precise the branch)

v2.26.12

Does the problem happens both in parallel typesetting and normal typesetting?

Only tested with paralell pages typesetting.

Description of the problem

A chapter oder section title which flows over more than one line causes strange behavior of the linenumbering printed on the left or right side. Although the apparatus numbering seems to be correct. One can find a first discussion of the problem here: https://tex.stackexchange.com/questions/446339/long-section-titles-with-reledpar

The comments Florian an Ulrike made there, were already helpful to unterstand the principle an having a workaround.

Minimal Working Example

\documentclass[11pt, pagesize=false]{scrbook}
\usepackage{fontspec}
\usepackage{blindtext}

\usepackage[papersize={17cm, 24cm}, left=2.4cm, right=1.8cm, top=3.5cm, bottom=2.4cm,dvips=false,pdftex=false,vtex=false]{geometry}

\usepackage{polyglossia}
    \setdefaultlanguage[spelling=new]{german}
    \setotherlanguage[variant=classic]{latin}

\setmainfont[Numbers=OldStyle]{TeX Gyre Pagella}

\usepackage{scrlayer-scrpage}

\usepackage[series={A}]{reledmac}
\usepackage{reledpar}
\Xarrangement[A]{paragraph}

\eledsectnotoc{R}
\eledsectmark{L}

\begin{document}

\begin{pages}
\begin{Leftside}
\selectlanguage{latin}
\beginnumbering
\pstart
\eledsection*{Long Title that goes faaaaar beyond one line with a lot of text going on and on}
\pend\pstart
\blindtext[1]
\pend\pstart
A paragraph
\pend\pstart
\blindtext[1]
\pend
\endnumbering
\end{Leftside}

\begin{Rightside}
\selectlanguage{ngerman}
\beginnumberingR
\pstart
\eledsection*{Ein langer Titel ohne Punkt und Komma und außerdem ganz viel Text}
\pend\pstart
\blindtext[1]
\pend\pstart
A \edtext{footnote}{\Afootnote{A remark.}}
\pend\pstart
\blindtext[1]
\pend
\endnumberingR
\end{Rightside}
\end{pages}
\Pages
\end{document}
adunning commented 6 years ago

I can confirm that this is a bug in reledmac core rather than reledpar; here is a more minimal example:

\documentclass{article}
\usepackage[series={},nocritical,noend,nofamiliar,noledgroup]{reledmac}
\linenummargin{inner}
\usepackage{blindtext}

\begin{document}

\beginnumbering
\pstart
\eledsection*{\blindtext}
\pend

\pstart
\blindtext
\pend

\endnumbering

\end{document}

The really odd thing is that a two-line heading is counted as only one line, but in the attached it seems to start counting again after seven lines.

screen shot 2018-10-06 at 01 20 27
adunning commented 6 years ago

Actually, this is a duplicate of #197.

maieul commented 6 years ago

yeah, and the problem is already explained on #197. I need time to solve it.